From: Andrew Vasquez Date: Tue, 10 May 2011 18:30:14 +0000 (-0700) Subject: [SCSI] qla2xxx: Clear complete initialization control block. X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=773120e4df1d2bf543345ad850cc92dc1f1bad8a;p=linux-beck.git [SCSI] qla2xxx: Clear complete initialization control block. Use proper init_cb_size member which takes into account MID/non-MID init-cb structure sizes. Signed-off-by: Andrew Vasquez Signed-off-by: Madhuranath Iyengar Signed-off-by: James Bottomley Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c index cb6969320b47..920b76bfbb93 100644 --- a/drivers/scsi/qla2xxx/qla_init.c +++ b/drivers/scsi/qla2xxx/qla_init.c @@ -5210,7 +5210,7 @@ qla81xx_nvram_config(scsi_qla_host_t *vha) } /* Reset Initialization control block */ - memset(icb, 0, sizeof(struct init_cb_81xx)); + memset(icb, 0, ha->init_cb_size); /* Copy 1st segment. */ dptr1 = (uint8_t *)icb;