diff options
author | Wei Yongjun | 2020-07-09 19:46:36 +0800 |
---|---|---|
committer | Martin K. Petersen | 2020-07-13 23:11:15 -0400 |
commit | dd06a40201fe8a4db8071b4939fafc5905557b01 (patch) | |
tree | bd3fb074c136b8256f657e53f2335bbd9cd9fd1e | |
parent | 6edfdcfe285e499994b94a0f93e1f46ab2398162 (diff) |
scsi: target: Remove unused variable 'tpg'
Gcc reports warning as follows:
drivers/target/target_core_pr.c:1162:26: warning:
variable 'tpg' set but not used [-Wunused-but-set-variable]
1162 | struct se_portal_group *tpg;
| ^~~
After commit 63c9ffe473d3 ("scsi: target: Check enforce_pr_isids during
registration"), 'tpg' is never used. Remove it to avoid build warning.
Link: https://lore.kernel.org/r/20200709114636.69256-1-weiyongjun1@huawei.com
Reported-by: Hulk Robot <hulkci@huawei.com>
Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Reviewed-by: Mike Christie <michael.christie@oracle.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
-rw-r--r-- | drivers/target/target_core_pr.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/target/target_core_pr.c b/drivers/target/target_core_pr.c index 300b03b1b696..8fc88654bff6 100644 --- a/drivers/target/target_core_pr.c +++ b/drivers/target/target_core_pr.c @@ -1159,7 +1159,6 @@ static struct t10_pr_registration *__core_scsi3_locate_pr_reg( { struct t10_reservation *pr_tmpl = &dev->t10_pr; struct t10_pr_registration *pr_reg, *pr_reg_tmp; - struct se_portal_group *tpg; spin_lock(&pr_tmpl->registration_lock); list_for_each_entry_safe(pr_reg, pr_reg_tmp, @@ -1170,7 +1169,6 @@ static struct t10_pr_registration *__core_scsi3_locate_pr_reg( if (pr_reg->pr_reg_nacl != nacl) continue; - tpg = pr_reg->pr_reg_nacl->se_tpg; /* * If this registration does NOT contain a fabric provided * ISID, then we have found a match. |