From 8551158abc8ef45a7f473a87e69624d05ebfd684 Mon Sep 17 00:00:00 2001 From: Stefan Richter Date: Mon, 7 Nov 2005 06:31:45 -0500 Subject: kmalloc/kzalloc changes: dv1394, eth1394, ieee1394, ohci1394, pcilynx, raw1394, sbp2c, video1394: - use kzalloc - provide safer size arguments to kmalloc and kzalloc - omit some casts Signed-off-by: Stefan Richter Signed-off-by: Jody McIntyre --- drivers/ieee1394/pcilynx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/ieee1394/pcilynx.c') diff --git a/drivers/ieee1394/pcilynx.c b/drivers/ieee1394/pcilynx.c index 6b1ab875333b..e2edc41e1b6f 100644 --- a/drivers/ieee1394/pcilynx.c +++ b/drivers/ieee1394/pcilynx.c @@ -1435,7 +1435,7 @@ static int __devinit add_card(struct pci_dev *dev, struct i2c_algo_bit_data i2c_adapter_data; error = -ENOMEM; - i2c_ad = kmalloc(sizeof(struct i2c_adapter), SLAB_KERNEL); + i2c_ad = kmalloc(sizeof(*i2c_ad), SLAB_KERNEL); if (!i2c_ad) FAIL("failed to allocate I2C adapter memory"); memcpy(i2c_ad, &bit_ops, sizeof(struct i2c_adapter)); -- cgit v1.2.3