summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/device_handler/scsi_dh_alua.c
diff options
context:
space:
mode:
authorHillf Danton <dhillf@gmail.com>2011-02-11 15:17:33 -0700
committerJames Bottomley <James.Bottomley@suse.de>2011-02-12 14:13:34 -0600
commit9dfeb3157e34315b8ca27d816a79358698a999ac (patch)
treee60afdfe8e8443003b1a96274a5fadf4325f5a92 /drivers/scsi/device_handler/scsi_dh_alua.c
parent04b6e153b64471ff43dde82b0122e67cf491f2f5 (diff)
downloadlinux-9dfeb3157e34315b8ca27d816a79358698a999ac.tar.gz
linux-9dfeb3157e34315b8ca27d816a79358698a999ac.tar.bz2
linux-9dfeb3157e34315b8ca27d816a79358698a999ac.zip
[SCSI] scsi_dh: cosmetic change to sizeof()
instead of doing sizeof(struct X) it's better to do sizeof(*v) where v is the variable pointing to struct X. Signed-off-by: Hillf Danton <dhillf@gmail.com> Signed-off-by: Babu Moger <babu.moger@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/device_handler/scsi_dh_alua.c')
-rw-r--r--drivers/scsi/device_handler/scsi_dh_alua.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/device_handler/scsi_dh_alua.c b/drivers/scsi/device_handler/scsi_dh_alua.c
index 5b6f9ab10d7a..7cae0bc85390 100644
--- a/drivers/scsi/device_handler/scsi_dh_alua.c
+++ b/drivers/scsi/device_handler/scsi_dh_alua.c
@@ -763,7 +763,7 @@ static int alua_bus_attach(struct scsi_device *sdev)
unsigned long flags;
int err = SCSI_DH_OK;
- scsi_dh_data = kzalloc(sizeof(struct scsi_device_handler *)
+ scsi_dh_data = kzalloc(sizeof(*scsi_dh_data)
+ sizeof(*h) , GFP_KERNEL);
if (!scsi_dh_data) {
sdev_printk(KERN_ERR, sdev, "%s: Attach failed\n",