summaryrefslogtreecommitdiffstats
path: root/kernel/Kconfig.preempt
diff options
context:
space:
mode:
authorDavid Daney <david.daney@cavium.com>2012-04-05 16:52:13 -0700
committerGrant Likely <grant.likely@secretlab.ca>2012-04-10 22:39:16 -0600
commit5b7526e3a640e491075557acaa842c59c652c0c3 (patch)
tree43b3d5d33078b4683482b25559735e1e5d719a72 /kernel/Kconfig.preempt
parent0034102808e0dbbf3a2394b82b1bb40b5778de9e (diff)
downloadop-kernel-dev-5b7526e3a640e491075557acaa842c59c652c0c3.zip
op-kernel-dev-5b7526e3a640e491075557acaa842c59c652c0c3.tar.gz
irq/irq_domain: Quit ignoring error returns from irq_alloc_desc_from().
In commit 4bbdd45a (irq_domain/powerpc: eliminate irq_map; use irq_alloc_desc() instead) code was added that ignores error returns from irq_alloc_desc_from() by (silently) casting the return value to unsigned. The negitive value error return now suddenly looks like a valid irq number. Commits cc79ca69 (irq_domain: Move irq_domain code from powerpc to kernel/irq) and 1bc04f2c (irq_domain: Add support for base irq and hwirq in legacy mappings) move this code to its current location in irqdomain.c The result of all of this is a null pointer dereference OOPS if one of the error cases is hit. The fix: Don't cast away the negativeness of the return value and then check for errors. Signed-off-by: David Daney <david.daney@cavium.com> Acked-by: Rob Herring <rob.herring@calxeda.com> [grant.likely: dropped addition of new 'irq' variable] Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'kernel/Kconfig.preempt')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud