linux_dsm_epyc7002/drivers/scsi/be2iscsi
Mike Christie fa95d206e4 [SCSI] be2iscsi: fix disconnection cleanup
This patch fixes 4 bugs in the connection connect/disconnect
cleanup path.

1. If beiscsi_open_conn fails beiscsi_free_ep was always being
called, and if beiscsi_open_conn failed because beiscsi_get_cid
failed then we would free an unallocated cid.

2. If beiscsi_ep_connect failed due to a beiscsi_open_conn failure
it was leaking iscsi_endpoints.

3. beiscsi_ep_disconnect was leaking iscsi_endpoints.
beiscsi_ep_disconnect should free the iscsi_endpoint. We cannot
do it in beiscsi_conn_stop because that is only called for
iscsi connection cleanup. If beiscsi_ep_connect returns
success, but then the poll function fails or the connect
times out then beiscsi_ep_disconnect will be called to clean
up the ep. The conn_stop callout will not be called in that path.

4. beiscsi_conn_stop was freeing the iscsi_endpoint then accessing
it a couple lines later.

Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2010-07-27 12:01:39 -05:00
..
be_cmds.c [SCSI] be2iscsi: Fix for a possible udelay while holding lock 2010-03-03 17:40:04 +05:30
be_cmds.h [SCSI] be2iscsi: changing copyright to 2010 2010-02-08 18:34:09 -06:00
be_iscsi.c [SCSI] be2iscsi: fix disconnection cleanup 2010-07-27 12:01:39 -05:00
be_iscsi.h [SCSI] be2iscsi: fix disconnection cleanup 2010-07-27 12:01:39 -05:00
be_main.c [SCSI] be2iscsi: fix disconnection cleanup 2010-07-27 12:01:39 -05:00
be_main.h [SCSI] be2iscsi: Fixing memory allocation for connection 2010-03-03 18:30:06 +05:30
be_mgmt.c [SCSI] be2iscsi: correct return value in mgmt_invalidate_icds() 2010-05-24 11:11:03 -05:00
be_mgmt.h [SCSI] be2iscsi: Cleanup of resets for device and target 2010-03-03 17:39:24 +05:30
be.h [SCSI] be2iscsi: Adding support for BE3 2010-02-17 13:41:10 -06:00
Kconfig [SCSI] be2iscsi: add 10Gbps iSCSI - BladeEngine 2 driver 2009-10-02 09:50:33 -05:00
Makefile [SCSI] be2iscsi: add 10Gbps iSCSI - BladeEngine 2 driver 2009-10-02 09:50:33 -05:00