ipmi: Initialize BMC device attributes

This avoids an oops at initialization time.

Signed-off-by: Corey Minyard <cminyard@mvista.com>
Cc: Sanjeev <singhsan@codeaurora.org>
This commit is contained in:
Corey Minyard 2014-11-06 20:11:40 -06:00
parent 80fad5b959
commit 3d9e5df527

View File

@ -2390,12 +2390,14 @@ static int create_bmc_files(struct bmc_device *bmc)
int err;
if (bmc->id.aux_firmware_revision_set) {
bmc->aux_firmware_rev_attr.attr.name = "aux_firmware_revision";
err = device_create_file(&bmc->pdev.dev,
&bmc->aux_firmware_rev_attr);
if (err)
goto out;
}
if (bmc->guid_set) {
bmc->guid_attr.attr.name = "guid";
err = device_create_file(&bmc->pdev.dev,
&bmc->guid_attr);
if (err)