summaryrefslogtreecommitdiffstats
path: root/drivers/char/ip2/ip2main.c
diff options
context:
space:
mode:
authorMariusz Kozlowski <m.kozlowski@tuxland.pl>2007-10-16 23:26:45 -0700
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-17 08:42:50 -0700
commit978550b828d1c29dfd65707f5d001053c3d2d610 (patch)
tree0a4bf0ee355796a250da395974326e474b4e1158 /drivers/char/ip2/ip2main.c
parentb63d50c438bd3a8910263e15c37ca8634b110c92 (diff)
downloadop-kernel-dev-978550b828d1c29dfd65707f5d001053c3d2d610.zip
op-kernel-dev-978550b828d1c29dfd65707f5d001053c3d2d610.tar.gz
drivers/char/ip2/ip2main.c: kmalloc + memset conversion to kzalloc
drivers/char/ip2/ip2main.c | 104398 -> 104346 (-52 bytes) drivers/char/ip2/ip2main.o | 210710 -> 210702 (-8 bytes) Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char/ip2/ip2main.c')
-rw-r--r--drivers/char/ip2/ip2main.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/char/ip2/ip2main.c b/drivers/char/ip2/ip2main.c
index bd94d5f..3300ba3 100644
--- a/drivers/char/ip2/ip2main.c
+++ b/drivers/char/ip2/ip2main.c
@@ -646,10 +646,9 @@ ip2_loadmain(int *iop, int *irqp, unsigned char *firmware, int firmsize)
for ( i = 0; i < IP2_MAX_BOARDS; ++i ) {
if ( ip2config.addr[i] ) {
- pB = kmalloc( sizeof(i2eBordStr), GFP_KERNEL);
- if ( pB != NULL ) {
+ pB = kzalloc(sizeof(i2eBordStr), GFP_KERNEL);
+ if (pB) {
i2BoardPtrTable[i] = pB;
- memset( pB, 0, sizeof(i2eBordStr) );
iiSetAddress( pB, ip2config.addr[i], ii2DelayTimer );
iiReset( pB );
} else {
OpenPOWER on IntegriCloud