Commit 7032d92a authored by Cédric Le Goater's avatar Cédric Le Goater Committed by David Gibson
Browse files

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



Signed-off-by: default avatarCédric Le Goater <clg@kaod.org>
[dwg: Correct typo in commit message]
Signed-off-by: default avatarDavid Gibson <david@gibson.dropbear.id.au>
parent 05249517
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -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")));