diff options
author | Jeremy Kerr <jk@ozlabs.org> | 2006-07-12 01:39:54 -0400 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2006-07-31 01:55:04 -0400 |
commit | c61c27d58af61e5b78257019b173732c29ce0c64 (patch) | |
tree | 259c64446662670d36b40f26dd702b5006a97e1d /arch/powerpc/platforms/cell/spider-pic.c | |
parent | 8efca49329a50710d656a8bb78d6f0f0e2f48a26 (diff) |
[POWERPC] cell: Constify & voidify get_property()
Now that get_property() returns a void *, there's no need to cast its
return value. Also, treat the return value as const, so we can
constify get_property later.
cell platform changes.
Built for cell_defconfig
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/platforms/cell/spider-pic.c')
-rw-r--r-- | arch/powerpc/platforms/cell/spider-pic.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/powerpc/platforms/cell/spider-pic.c b/arch/powerpc/platforms/cell/spider-pic.c index ae7ef88f1a37..ab4c252a4d9b 100644 --- a/arch/powerpc/platforms/cell/spider-pic.c +++ b/arch/powerpc/platforms/cell/spider-pic.c | |||
@@ -230,7 +230,7 @@ static void spider_irq_cascade(unsigned int irq, struct irq_desc *desc, | |||
230 | static unsigned int __init spider_find_cascade_and_node(struct spider_pic *pic) | 230 | static unsigned int __init spider_find_cascade_and_node(struct spider_pic *pic) |
231 | { | 231 | { |
232 | unsigned int virq; | 232 | unsigned int virq; |
233 | u32 *imap, *tmp; | 233 | const u32 *imap, *tmp; |
234 | int imaplen, intsize, unit; | 234 | int imaplen, intsize, unit; |
235 | struct device_node *iic; | 235 | struct device_node *iic; |
236 | struct irq_host *iic_host; | 236 | struct irq_host *iic_host; |
@@ -248,25 +248,25 @@ static unsigned int __init spider_find_cascade_and_node(struct spider_pic *pic) | |||
248 | #endif | 248 | #endif |
249 | 249 | ||
250 | /* Now do the horrible hacks */ | 250 | /* Now do the horrible hacks */ |
251 | tmp = (u32 *)get_property(pic->of_node, "#interrupt-cells", NULL); | 251 | tmp = get_property(pic->of_node, "#interrupt-cells", NULL); |
252 | if (tmp == NULL) | 252 | if (tmp == NULL) |
253 | return NO_IRQ; | 253 | return NO_IRQ; |
254 | intsize = *tmp; | 254 | intsize = *tmp; |
255 | imap = (u32 *)get_property(pic->of_node, "interrupt-map", &imaplen); | 255 | imap = get_property(pic->of_node, "interrupt-map", &imaplen); |
256 | if (imap == NULL || imaplen < (intsize + 1)) | 256 | if (imap == NULL || imaplen < (intsize + 1)) |
257 | return NO_IRQ; | 257 | return NO_IRQ; |
258 | iic = of_find_node_by_phandle(imap[intsize]); | 258 | iic = of_find_node_by_phandle(imap[intsize]); |
259 | if (iic == NULL) | 259 | if (iic == NULL) |
260 | return NO_IRQ; | 260 | return NO_IRQ; |
261 | imap += intsize + 1; | 261 | imap += intsize + 1; |
262 | tmp = (u32 *)get_property(iic, "#interrupt-cells", NULL); | 262 | tmp = get_property(iic, "#interrupt-cells", NULL); |
263 | if (tmp == NULL) | 263 | if (tmp == NULL) |
264 | return NO_IRQ; | 264 | return NO_IRQ; |
265 | intsize = *tmp; | 265 | intsize = *tmp; |
266 | /* Assume unit is last entry of interrupt specifier */ | 266 | /* Assume unit is last entry of interrupt specifier */ |
267 | unit = imap[intsize - 1]; | 267 | unit = imap[intsize - 1]; |
268 | /* Ok, we have a unit, now let's try to get the node */ | 268 | /* Ok, we have a unit, now let's try to get the node */ |
269 | tmp = (u32 *)get_property(iic, "ibm,interrupt-server-ranges", NULL); | 269 | tmp = get_property(iic, "ibm,interrupt-server-ranges", NULL); |
270 | if (tmp == NULL) { | 270 | if (tmp == NULL) { |
271 | of_node_put(iic); | 271 | of_node_put(iic); |
272 | return NO_IRQ; | 272 | return NO_IRQ; |