aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pnp/core.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/pnp/core.c')
-rw-r--r--drivers/pnp/core.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pnp/core.c b/drivers/pnp/core.c
index 3e20b1cc7778..8e7b2dd38810 100644
--- a/drivers/pnp/core.c
+++ b/drivers/pnp/core.c
@@ -35,12 +35,11 @@ void *pnp_alloc(long size)
35{ 35{
36 void *result; 36 void *result;
37 37
38 result = kmalloc(size, GFP_KERNEL); 38 result = kzalloc(size, GFP_KERNEL);
39 if (!result){ 39 if (!result){
40 printk(KERN_ERR "pnp: Out of Memory\n"); 40 printk(KERN_ERR "pnp: Out of Memory\n");
41 return NULL; 41 return NULL;
42 } 42 }
43 memset(result, 0, size);
44 return result; 43 return result;
45} 44}
46 45