From 88abaab4f9b08381e30e737980a1c49d6b524dfc Mon Sep 17 00:00:00 2001 From: Eric Sesterhenn Date: Fri, 24 Mar 2006 03:15:31 -0800 Subject: [PATCH] s390: kzalloc() conversion in drivers/s390 Convert all kmalloc + memset sequences in drivers/s390 to kzalloc usage. Signed-off-by: Eric Sesterhenn Signed-off-by: Martin Schwidefsky Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/s390/s390_rdev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'drivers/s390/s390_rdev.c') diff --git a/drivers/s390/s390_rdev.c b/drivers/s390/s390_rdev.c index e3f647169827..3c7145d9f9a1 100644 --- a/drivers/s390/s390_rdev.c +++ b/drivers/s390/s390_rdev.c @@ -27,10 +27,9 @@ s390_root_dev_register(const char *name) if (!strlen(name)) return ERR_PTR(-EINVAL); - dev = kmalloc(sizeof(struct device), GFP_KERNEL); + dev = kzalloc(sizeof(struct device), GFP_KERNEL); if (!dev) return ERR_PTR(-ENOMEM); - memset(dev, 0, sizeof(struct device)); strncpy(dev->bus_id, name, min(strlen(name), (size_t)BUS_ID_SIZE)); dev->release = s390_root_dev_release; ret = device_register(dev); -- cgit v1.2.2