summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/ibm_acpi.c
diff options
context:
space:
mode:
authorBurman Yan2006-12-19 21:56:11 +0100
committerLen Brown2006-12-20 22:54:54 +0100
commit36bcbec7ce21e2e8b3143b11a05747330abeca70 (patch)
treed9ace4d83a5013dbb3cd599e7bc4358ce4cdb980 /drivers/acpi/ibm_acpi.c
parentPull sgi into test branch (diff)
downloadkernel-qcow2-linux-36bcbec7ce21e2e8b3143b11a05747330abeca70.tar.gz
kernel-qcow2-linux-36bcbec7ce21e2e8b3143b11a05747330abeca70.tar.xz
kernel-qcow2-linux-36bcbec7ce21e2e8b3143b11a05747330abeca70.zip
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/ibm_acpi.c')
-rw-r--r--drivers/acpi/ibm_acpi.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/acpi/ibm_acpi.c b/drivers/acpi/ibm_acpi.c
index 130cc8c37e22..0e7682a88aa8 100644
--- a/drivers/acpi/ibm_acpi.c
+++ b/drivers/acpi/ibm_acpi.c
@@ -2516,13 +2516,12 @@ static int __init register_driver(struct ibm_struct *ibm)
{
int ret;
- ibm->driver = kmalloc(sizeof(struct acpi_driver), GFP_KERNEL);
+ ibm->driver = kzalloc(sizeof(struct acpi_driver), GFP_KERNEL);
if (!ibm->driver) {
printk(IBM_ERR "kmalloc(ibm->driver) failed\n");
return -1;
}
- memset(ibm->driver, 0, sizeof(struct acpi_driver));
sprintf(ibm->driver->name, "%s_%s", IBM_NAME, ibm->name);
ibm->driver->ids = ibm->hid;
ibm->driver->ops.add = &ibm_device_add;