diff options
author | Gavin Shan | 2014-11-12 03:36:10 +0100 |
---|---|---|
committer | Michael Ellerman | 2014-11-14 07:24:25 +0100 |
commit | ec8e4e9d3d83b7a973477c2cb4831511b0eec06e (patch) | |
tree | a8409156326d0bd40e320b4c8b8a91144134cf41 /arch/powerpc/platforms | |
parent | powerpc/powernv: Simplify pnv_ioda_configure_pe() (diff) | |
download | kernel-qcow2-linux-ec8e4e9d3d83b7a973477c2cb4831511b0eec06e.tar.gz kernel-qcow2-linux-ec8e4e9d3d83b7a973477c2cb4831511b0eec06e.tar.xz kernel-qcow2-linux-ec8e4e9d3d83b7a973477c2cb4831511b0eec06e.zip |
powerpc/powernv: Bail upon invalid master PE
When freezing compound PEs in pnv_ioda_freeze_pe(), we should bail
upon illegal master PE. We needn't freeze slave PE because it should
have been put into frozen state by hardware.
Reported-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/platforms')
-rw-r--r-- | arch/powerpc/platforms/powernv/pci-ioda.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b/arch/powerpc/platforms/powernv/pci-ioda.c index 762ca14228ea..d03503515692 100644 --- a/arch/powerpc/platforms/powernv/pci-ioda.c +++ b/arch/powerpc/platforms/powernv/pci-ioda.c @@ -373,7 +373,9 @@ static void pnv_ioda_freeze_pe(struct pnv_phb *phb, int pe_no) /* Fetch master PE */ if (pe->flags & PNV_IODA_PE_SLAVE) { pe = pe->master; - WARN_ON(!pe || !(pe->flags & PNV_IODA_PE_MASTER)); + if (WARN_ON(!pe || !(pe->flags & PNV_IODA_PE_MASTER))) + return; + pe_no = pe->pe_number; } |