powerpc/vphn: Check for error from hcall_vphn
There is no value in unpacking associativity, if H_HOME_NODE_ASSOCIATIVITY hcall has returned an error. Signed-off-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Reported-by: Abdul Haleem <abdhalee@linux.vnet.ibm.com> Reviewed-by: Nathan Lynch <nathanl@linux.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20200129135301.24739-2-srikar@linux.vnet.ibm.com
This commit is contained in:
parent
a05f0e5be4
commit
e7214ae9d8
|
@ -82,7 +82,8 @@ long hcall_vphn(unsigned long cpu, u64 flags, __be32 *associativity)
|
|||
long retbuf[PLPAR_HCALL9_BUFSIZE] = {0};
|
||||
|
||||
rc = plpar_hcall9(H_HOME_NODE_ASSOCIATIVITY, retbuf, flags, cpu);
|
||||
vphn_unpack_associativity(retbuf, associativity);
|
||||
if (rc == H_SUCCESS)
|
||||
vphn_unpack_associativity(retbuf, associativity);
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue