diff options
author | Thomas Huth <thuth@redhat.com> | 2015-09-15 21:34:20 +0200 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2015-09-23 10:51:11 +1000 |
commit | ef001f069e0f175a036929782c5c63053df9569a (patch) | |
tree | 2bf211642512ebec996b2cc8c4dad7e6b786552e /hw/openrisc/Makefile.objs | |
parent | 20bb648dca6d7fe8cdd1941194e7851950b25dc5 (diff) |
ppc/spapr: Fix buffer overflow in spapr_populate_drconf_memory()
The buffer that is allocated in spapr_populate_drconf_memory()
is used for setting both, the "ibm,dynamic-memory" and the
"ibm,associativity-lookup-arrays" property. However, only the
size of the first one is taken into account when allocating the
memory. So if the length of the second property is larger than
the length of the first one, we run into a buffer overflow here!
Fix it by taking the length of the second property into account,
too.
Fixes: "spapr: Support ibm,dynamic-reconfiguration-memory" patch
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/openrisc/Makefile.objs')
0 files changed, 0 insertions, 0 deletions