summaryrefslogtreecommitdiff
path: root/arch/powerpc/sysdev/mpic.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-05-07 16:34:40 (GMT)
committerLinus Torvalds <torvalds@linux-foundation.org>2013-05-07 16:34:40 (GMT)
commitc818c778b0384e5d9e8184ec43b73e05a7ced86f (patch)
tree2d50257ac6f94448f1dfe2bb65b4ff5aa383fe4a /arch/powerpc/sysdev/mpic.c
parentc8de2fa4dc2778ae3605925c127b3deac54b2b3a (diff)
parent5737789c8340620d7b542d1d4e9b197de8eb2801 (diff)
downloadlinux-fsl-qoriq-c818c778b0384e5d9e8184ec43b73e05a7ced86f.tar.xz
Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc
Pull powerpc updates from Benjamin Herrenschmidt: "Here are a few more powerpc bits that I would like in 3.10. Mostly remaining bolts & screw tightening of power8 support such as actually exposing the new features via the previously added AT_HWCAP2, and a few fixes, some of them for problems exposed recently like irqdomain warnings or sysfs access permission issues, some exposed by power8 hardware. The only change outside of arch/powerpc is a small one to irqdomain.c to allow silent failure to fix a problem on Cell where we get a dozen WARN_ON's tripping at boot for what is basically a normal case." * 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc: powerpc: Make hard_irq_disable() do the right thing vs. irq tracing powerpc/topology: Fix spurr attribute permission powerpc/pci: Support per-aperture memory offset powerpc/cell/iommu: Improve error message for missing node powerpc/cell/spufs: Fix status attribute permission irqdomain: Allow quiet failure mode powerpc/pnv: Fix "compatible" property for P8 PHB powerpc/pci: Don't add bogus empty resources to PHBs powerpc/powerpnv: Properly handle failure starting CPUs powerpc/cputable: Advertise support for ISEL/HTM/DSCR/TAR on POWER8 powerpc/cputable: Advertise ISEL support on appropriate embedded processors powerpc/cputable: Advertise DSCR support on P7/P7+ powerpc/cputable: Reserve bits in HWCAP2 for new features powerpc/pseries: Perform proper max_bus_speed detection powerpc/pseries: Force 32 bit MSIs for devices that require it powerpc/tm: Fix null pointer deference in flush_hash_page powerpc/powernv: Defer OPAL exception handler registration powerpc: Emulate non privileged DSCR read and write
Diffstat (limited to 'arch/powerpc/sysdev/mpic.c')
-rw-r--r--arch/powerpc/sysdev/mpic.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/arch/powerpc/sysdev/mpic.c b/arch/powerpc/sysdev/mpic.c
index d30e6a6..ee21b5e 100644
--- a/arch/powerpc/sysdev/mpic.c
+++ b/arch/powerpc/sysdev/mpic.c
@@ -1001,8 +1001,12 @@ static int mpic_host_map(struct irq_domain *h, unsigned int virq,
if (hw == mpic->spurious_vec)
return -EINVAL;
- if (mpic->protected && test_bit(hw, mpic->protected))
- return -EINVAL;
+ if (mpic->protected && test_bit(hw, mpic->protected)) {
+ pr_warning("mpic: Mapping of source 0x%x failed, "
+ "source protected by firmware !\n",\
+ (unsigned int)hw);
+ return -EPERM;
+ }
#ifdef CONFIG_SMP
else if (hw >= mpic->ipi_vecs[0]) {
@@ -1029,8 +1033,12 @@ static int mpic_host_map(struct irq_domain *h, unsigned int virq,
if (mpic_map_error_int(mpic, virq, hw))
return 0;
- if (hw >= mpic->num_sources)
+ if (hw >= mpic->num_sources) {
+ pr_warning("mpic: Mapping of source 0x%x failed, "
+ "source out of range !\n",\
+ (unsigned int)hw);
return -EINVAL;
+ }
mpic_msi_reserve_hwirq(mpic, hw);