summaryrefslogtreecommitdiffstats
path: root/include/target/target_core_base.h
diff options
context:
space:
mode:
authorNicholas Bellinger <nab@linux-iscsi.org>2015-03-27 04:51:03 +0000
committerNicholas Bellinger <nab@linux-iscsi.org>2015-06-01 00:24:12 -0700
commit79dc9c9e865a7f8c14737453f112ced25deafdef (patch)
tree3b2ed302eecee3319868fc5f29c7ecfea1f8f27e /include/target/target_core_base.h
parent80bfdfa92481d431b199eff72788588d13a3988f (diff)
downloadtalos-obmc-linux-79dc9c9e865a7f8c14737453f112ced25deafdef.tar.gz
talos-obmc-linux-79dc9c9e865a7f8c14737453f112ced25deafdef.zip
target/pr: Change alloc_registration to avoid pr_reg_tg_pt_lun
This patch changes __core_scsi3_do_alloc_registration() code to drop pr_reg->pr_reg_tg_pt_lun pointer usage in favor of a new pr_reg RPTI + existing pr_reg->pr_aptpl_target_lun used by APTPL metadata logic. It also includes changes to REGISTER, REGISTER_AND_MOVE and APTPL feature bit codepaths to use rcu_dereference_check() with the expected non-zero se_dev_entry->pr_kref reference held. Reviewed-by: Hannes Reinecke <hare@suse.de> Cc: Christoph Hellwig <hch@lst.de> Cc: Sagi Grimberg <sagig@mellanox.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'include/target/target_core_base.h')
-rw-r--r--include/target/target_core_base.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/target/target_core_base.h b/include/target/target_core_base.h
index 508528a5e927..cf3c6addf05a 100644
--- a/include/target/target_core_base.h
+++ b/include/target/target_core_base.h
@@ -372,13 +372,14 @@ struct t10_pr_registration {
bool isid_present_at_reg;
u32 pr_res_mapped_lun;
u32 pr_aptpl_target_lun;
+ u16 tg_pt_sep_rtpi;
u32 pr_res_generation;
u64 pr_reg_bin_isid;
u64 pr_res_key;
atomic_t pr_res_holders;
struct se_node_acl *pr_reg_nacl;
+ /* Used by ALL_TG_PT=1 registration with deve->pr_ref taken */
struct se_dev_entry *pr_reg_deve;
- struct se_lun *pr_reg_tg_pt_lun;
struct list_head pr_reg_list;
struct list_head pr_reg_abort_list;
struct list_head pr_reg_aptpl_list;
@@ -498,7 +499,6 @@ struct se_cmd {
struct list_head se_delayed_node;
struct list_head se_qf_node;
struct se_device *se_dev;
- struct se_dev_entry *se_deve;
struct se_lun *se_lun;
/* Only used for internal passthrough and legacy TCM fabric modules */
struct se_session *se_sess;
OpenPOWER on IntegriCloud