spapr: fix off-by-one error in spapr_ovec_populate_dt()

The last byte of the option vector was missing due to an off-by-one
error. Without this fix, client architecture support negotiation will
fail because the last byte of option vector 5, which contains the MMU
support, will be missed.

Signed-off-by: Sam Bobroff <sam.bobroff@au1.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
Sam Bobroff 2017-02-07 13:56:44 +11:00 committed by David Gibson
parent d4ccd87e68
commit fe93e3e6ec

View File

@ -250,5 +250,5 @@ int spapr_ovec_populate_dt(void *fdt, int fdt_offset,
}
}
return fdt_setprop(fdt, fdt_offset, name, vec, vec_len);
return fdt_setprop(fdt, fdt_offset, name, vec, vec_len + 1);
}