aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/irq.c
diff options
context:
space:
mode:
authorEric Sesterhenn <snakebyte@gmx.de>2006-03-06 16:48:40 -0500
committerDavid S. Miller <davem@sunset.davemloft.net>2006-03-20 04:14:19 -0500
commit9132983ae140a8ca81e95e081d5a4c0dd7a7f670 (patch)
treef3aec20b1bb5a2cc111bbbf6775a0f8d84d28994 /arch/sparc64/kernel/irq.c
parentf7c00338cfeef125032aa12aa8ebeacf9e117e81 (diff)
[SPARC64]: kzalloc() conversion
this patch converts arch/sparc64 to kzalloc usage. Crosscompile tested with allyesconfig. Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/kernel/irq.c')
-rw-r--r--arch/sparc64/kernel/irq.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/sparc64/kernel/irq.c b/arch/sparc64/kernel/irq.c
index 712b16cdd5fb..8c93ba655b33 100644
--- a/arch/sparc64/kernel/irq.c
+++ b/arch/sparc64/kernel/irq.c
@@ -316,12 +316,11 @@ unsigned int build_irq(int pil, int inofixup, unsigned long iclr, unsigned long
316 goto out; 316 goto out;
317 } 317 }
318 318
319 bucket->irq_info = kmalloc(sizeof(struct irq_desc), GFP_ATOMIC); 319 bucket->irq_info = kzalloc(sizeof(struct irq_desc), GFP_ATOMIC);
320 if (!bucket->irq_info) { 320 if (!bucket->irq_info) {
321 prom_printf("IRQ: Error, kmalloc(irq_desc) failed.\n"); 321 prom_printf("IRQ: Error, kmalloc(irq_desc) failed.\n");
322 prom_halt(); 322 prom_halt();
323 } 323 }
324 memset(bucket->irq_info, 0, sizeof(struct irq_desc));
325 324
326 /* Ok, looks good, set it up. Don't touch the irq_chain or 325 /* Ok, looks good, set it up. Don't touch the irq_chain or
327 * the pending flag. 326 * the pending flag.
@@ -357,12 +356,11 @@ unsigned int sun4v_build_irq(u32 devhandle, unsigned int devino, int pil, unsign
357 bucket->pil = pil; 356 bucket->pil = pil;
358 bucket->flags = flags; 357 bucket->flags = flags;
359 358
360 bucket->irq_info = kmalloc(sizeof(struct irq_desc), GFP_ATOMIC); 359 bucket->irq_info = kzalloc(sizeof(struct irq_desc), GFP_ATOMIC);
361 if (!bucket->irq_info) { 360 if (!bucket->irq_info) {
362 prom_printf("IRQ: Error, kmalloc(irq_desc) failed.\n"); 361 prom_printf("IRQ: Error, kmalloc(irq_desc) failed.\n");
363 prom_halt(); 362 prom_halt();
364 } 363 }
365 memset(bucket->irq_info, 0, sizeof(struct irq_desc));
366 364
367 return __irq(bucket); 365 return __irq(bucket);
368} 366}