aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/of_device.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2008-08-25 19:44:58 -0400
committerDavid S. Miller <davem@davemloft.net>2008-08-25 19:44:58 -0400
commit51e0f004a9ab9104acbe323c0b20e0279bf9be85 (patch)
tree477ccb9efa52eff7531cd04dc605bbf9e90152a4 /arch/sparc64/kernel/of_device.c
parent783c98b911fce8d47aa2906468ca39d44d46d7ce (diff)
sparc64: Fix irq_of_parse_and_map() and irq_dispose_mapping().
Stephen Rothwell noticed that I committed an earlier version of the patch that didn't have two things fixed: 1) irq_of_parse_and_map() should return "unsigned int" not "int" and it should return zero for "no irq" 2) irq_dispose_mapping() should be an inline function, not a macro, for type checking With feedback and suggestions from Anton Vorontsov. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/kernel/of_device.c')
-rw-r--r--arch/sparc64/kernel/of_device.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/sparc64/kernel/of_device.c b/arch/sparc64/kernel/of_device.c
index 8a0d82343a25..a30f2af0bf2c 100644
--- a/arch/sparc64/kernel/of_device.c
+++ b/arch/sparc64/kernel/of_device.c
@@ -55,12 +55,12 @@ struct of_device *of_find_device_by_node(struct device_node *dp)
55} 55}
56EXPORT_SYMBOL(of_find_device_by_node); 56EXPORT_SYMBOL(of_find_device_by_node);
57 57
58int irq_of_parse_and_map(struct device_node *node, int index) 58unsigned int irq_of_parse_and_map(struct device_node *node, int index)
59{ 59{
60 struct of_device *op = of_find_device_by_node(node); 60 struct of_device *op = of_find_device_by_node(node);
61 61
62 if (!op || index >= op->num_irqs) 62 if (!op || index >= op->num_irqs)
63 return 0xffffffff; 63 return 0;
64 64
65 return op->irqs[index]; 65 return op->irqs[index];
66} 66}