Staging: slicoss: use kzalloc
authorLior Dotan <liodot@gmail.com>
Wed, 5 Nov 2008 09:27:17 +0000 (11:27 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 6 Jan 2009 21:52:08 +0000 (13:52 -0800)
This patch uses kzalloc() where really applicable.

Signed-off-by: Lior Dotan <liodot@gmail.com>
Cc: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/slicoss/slicoss.c

index 0039036..b8ac872 100644 (file)
@@ -2832,9 +2832,8 @@ static u32 slic_card_locate(struct adapter *adapter)
        }
        if (!physcard) {
                /* no structure allocated for this physical card yet */
-               physcard = kmalloc(sizeof(struct physcard *), GFP_ATOMIC);
+               physcard = kzalloc(sizeof(struct physcard *), GFP_ATOMIC);
                ASSERT(physcard);
-               memset(physcard, 0, sizeof(struct physcard *));
 
                DBG_MSG
                    ("\n%s Allocate a PHYSICALcard:\n    PHYSICAL_Card[%p]\n\