[SCSI] qla4xxx: Do not add duplicate CHAP entry in FLASH
commit4549415af6915017f5d3fbdbfd5edd1dfbe63fa9
authorLalit Chandivade <lalit.chandivade@qlogic.com>
Fri, 7 Oct 2011 23:55:42 +0000 (7 16:55 -0700)
committerJames Bottomley <JBottomley@Parallels.com>
Sun, 16 Oct 2011 16:08:41 +0000 (16 11:08 -0500)
treeb06ad5224dd3093d6fd9377d8461a295f101e1b7
parent0854f665a1cbb4566d3ebe449169b0200b8cdad0
[SCSI] qla4xxx: Do not add duplicate CHAP entry in FLASH

QLogic applications store the CHAP information in FLASH. During login,
authentication information is provided using an index into the CHAP region.

In order to support QLogic applications along with iscsiadm, updated the
LLD to not add duplicate CHAP entries in the CHAP region and preserve the
existing CHAP info in the CHAP region in FLASH.
This allows QLogic applications to pre-write the CHAP entries in the
CHAP region.

With iscsiadm, when the CHAP authentication information is sent to the LLD, the
LLD searches for the entry in CHAP region in FLASH, if exists then do not add.
If CHAP entry does not exist then add the CHAP entry in the CHAP region.

JIRA Key: UPSISCSI-146

Signed-off-by: Lalit Chandivade <lalit.chandivade@qlogic.com>
Signed-off-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com>
Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
drivers/scsi/qla4xxx/ql4_def.h
drivers/scsi/qla4xxx/ql4_fw.h
drivers/scsi/qla4xxx/ql4_mbx.c
drivers/scsi/qla4xxx/ql4_nx.c
drivers/scsi/qla4xxx/ql4_os.c