ppc/pnv: check the return value of fdt_setprop()

Signed-off-by: Cédric Le Goater <clg@kaod.org>
[dwg: Correct typo in commit message]
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
master
Cédric Le Goater 2017-06-05 17:44:21 +02:00 committed by David Gibson
parent 0524951788
commit 7032d92ac8
1 changed files with 3 additions and 2 deletions

View File

@ -378,8 +378,9 @@ static void powernv_populate_ipmi_bt(ISADevice *d, void *fdt, int lpc_off)
_FDT(node);
g_free(name);
fdt_setprop(fdt, node, "reg", io_regs, sizeof(io_regs));
fdt_setprop(fdt, node, "compatible", compatible, sizeof(compatible));
_FDT((fdt_setprop(fdt, node, "reg", io_regs, sizeof(io_regs))));
_FDT((fdt_setprop(fdt, node, "compatible", compatible,
sizeof(compatible))));
/* Mark it as reserved to avoid Linux trying to claim it */
_FDT((fdt_setprop_string(fdt, node, "status", "reserved")));