Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=cddf7ff766ee53e24ff37f55a897efc90cb3526e
Commit:     cddf7ff766ee53e24ff37f55a897efc90cb3526e
Parent:     a850cef77f148c2e305022a1ed86ca6cff5ee300
Author:     Mariusz Kozlowski <[EMAIL PROTECTED]>
AuthorDate: Wed Oct 17 18:04:38 2007 +0200
Committer:  Thomas Gleixner <[EMAIL PROTECTED]>
CommitDate: Wed Oct 17 20:16:18 2007 +0200

    x86: kmalloc + memset conversion to kzalloc
    
    arch/x86_64/kernel/io_apic.c | 56080 -> 56038 (-42 bytes)
    
    also eliminate unnecessary local variable assignment.
    
    [ tglx: arch/x86 adaptation ]
    
    Signed-off-by: Mariusz Kozlowski <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Andi Kleen <[EMAIL PROTECTED]>
    Signed-off-by: Ingo Molnar <[EMAIL PROTECTED]>
    Signed-off-by: Thomas Gleixner <[EMAIL PROTECTED]>
---
 arch/x86/kernel/io_apic_64.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/arch/x86/kernel/io_apic_64.c b/arch/x86/kernel/io_apic_64.c
index 966fa10..66a27d2 100644
--- a/arch/x86/kernel/io_apic_64.c
+++ b/arch/x86/kernel/io_apic_64.c
@@ -1845,7 +1845,7 @@ static struct sysdev_class ioapic_sysdev_class = {
 static int __init ioapic_init_sysfs(void)
 {
        struct sys_device * dev;
-       int i, size, error = 0;
+       int i, size, error;
 
        error = sysdev_class_register(&ioapic_sysdev_class);
        if (error)
@@ -1854,12 +1854,11 @@ static int __init ioapic_init_sysfs(void)
        for (i = 0; i < nr_ioapics; i++ ) {
                size = sizeof(struct sys_device) + nr_ioapic_registers[i]
                        * sizeof(struct IO_APIC_route_entry);
-               mp_ioapic_data[i] = kmalloc(size, GFP_KERNEL);
+               mp_ioapic_data[i] = kzalloc(size, GFP_KERNEL);
                if (!mp_ioapic_data[i]) {
                        printk(KERN_ERR "Can't suspend/resume IOAPIC %d\n", i);
                        continue;
                }
-               memset(mp_ioapic_data[i], 0, size);
                dev = &mp_ioapic_data[i]->dev;
                dev->id = i;
                dev->cls = &ioapic_sysdev_class;
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to