diff options
| author | Nicholas Bellinger <nab@linux-iscsi.org> | 2011-11-12 12:29:51 -0500 |
|---|---|---|
| committer | Nicholas Bellinger <nab@linux-iscsi.org> | 2011-12-06 01:00:51 -0500 |
| commit | 6297b07cbc42eb6b53eb88fce70a4727ea230797 (patch) | |
| tree | 34996a19baaa466e274b361e4437da97b85d249f /drivers/target/loopback | |
| parent | 97c34f3b04978799fd6eada69e1a8d84b74d9599 (diff) | |
target: Drop config_item_name usage in fabric TFO->free_wwn()
This patch removes config_item_name() informational usage of
TFO->free_wwn() treewide in loopback, tcm_fc, ib_srpt and
tcm_vhost module code.
Using v4 target_core_fabric_configfs.c logic, a fabric call for
config_item_name() in TFO->drop_wwn() context returns NULL as
target_fabric_drop_wwn() invoking config_item_put() ->
config_group_put() will release fabric_port->port_wwn.wwn_group
before the last config_item_put() -> TFO->drop_wwn() is
invoked.
Reported-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/target/loopback')
| -rw-r--r-- | drivers/target/loopback/tcm_loop.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/target/loopback/tcm_loop.c b/drivers/target/loopback/tcm_loop.c index cbf5e451374..0ca89f02e26 100644 --- a/drivers/target/loopback/tcm_loop.c +++ b/drivers/target/loopback/tcm_loop.c | |||
| @@ -1342,17 +1342,16 @@ void tcm_loop_drop_scsi_hba( | |||
| 1342 | { | 1342 | { |
| 1343 | struct tcm_loop_hba *tl_hba = container_of(wwn, | 1343 | struct tcm_loop_hba *tl_hba = container_of(wwn, |
| 1344 | struct tcm_loop_hba, tl_hba_wwn); | 1344 | struct tcm_loop_hba, tl_hba_wwn); |
| 1345 | int host_no = tl_hba->sh->host_no; | 1345 | |
| 1346 | pr_debug("TCM_Loop_ConfigFS: Deallocating emulated Target" | ||
| 1347 | " SAS Address: %s at Linux/SCSI Host ID: %d\n", | ||
| 1348 | tl_hba->tl_wwn_address, tl_hba->sh->host_no); | ||
| 1346 | /* | 1349 | /* |
| 1347 | * Call device_unregister() on the original tl_hba->dev. | 1350 | * Call device_unregister() on the original tl_hba->dev. |
| 1348 | * tcm_loop_fabric_scsi.c:tcm_loop_release_adapter() will | 1351 | * tcm_loop_fabric_scsi.c:tcm_loop_release_adapter() will |
| 1349 | * release *tl_hba; | 1352 | * release *tl_hba; |
| 1350 | */ | 1353 | */ |
| 1351 | device_unregister(&tl_hba->dev); | 1354 | device_unregister(&tl_hba->dev); |
| 1352 | |||
| 1353 | pr_debug("TCM_Loop_ConfigFS: Deallocated emulated Target" | ||
| 1354 | " SAS Address: %s at Linux/SCSI Host ID: %d\n", | ||
| 1355 | config_item_name(&wwn->wwn_group.cg_item), host_no); | ||
| 1356 | } | 1355 | } |
| 1357 | 1356 | ||
| 1358 | /* Start items for tcm_loop_cit */ | 1357 | /* Start items for tcm_loop_cit */ |
