diff options
author | Burman Yan <yan_952@hotmail.com> | 2006-12-19 15:56:11 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2006-12-20 16:54:54 -0500 |
commit | 36bcbec7ce21e2e8b3143b11a05747330abeca70 (patch) | |
tree | d9ace4d83a5013dbb3cd599e7bc4358ce4cdb980 /drivers/acpi/acpi_memhotplug.c | |
parent | 5b7b4119553dd7cc0bc200c0d1b1598e158eec9a (diff) |
ACPI: replace kmalloc+memset with kzalloc
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/acpi_memhotplug.c')
-rw-r--r-- | drivers/acpi/acpi_memhotplug.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/acpi/acpi_memhotplug.c b/drivers/acpi/acpi_memhotplug.c index 150112ae48ed..cd946ed192d3 100644 --- a/drivers/acpi/acpi_memhotplug.c +++ b/drivers/acpi/acpi_memhotplug.c | |||
@@ -395,10 +395,9 @@ static int acpi_memory_device_add(struct acpi_device *device) | |||
395 | if (!device) | 395 | if (!device) |
396 | return -EINVAL; | 396 | return -EINVAL; |
397 | 397 | ||
398 | mem_device = kmalloc(sizeof(struct acpi_memory_device), GFP_KERNEL); | 398 | mem_device = kzalloc(sizeof(struct acpi_memory_device), GFP_KERNEL); |
399 | if (!mem_device) | 399 | if (!mem_device) |
400 | return -ENOMEM; | 400 | return -ENOMEM; |
401 | memset(mem_device, 0, sizeof(struct acpi_memory_device)); | ||
402 | 401 | ||
403 | INIT_LIST_HEAD(&mem_device->res_list); | 402 | INIT_LIST_HEAD(&mem_device->res_list); |
404 | mem_device->device = device; | 403 | mem_device->device = device; |