summaryrefslogtreecommitdiff
path: root/include/target/target_core_base.h
diff options
context:
space:
mode:
authorMike Christie <michael.christie@oracle.com>2021-02-27 11:00:02 -0600
committerMartin K. Petersen <martin.petersen@oracle.com>2021-03-04 17:37:02 -0500
commit302990ac3b1b1a2b7b66f59a5c88038a51fbe18e (patch)
treebe970c2bc90c9b7f68cc2c2217c2f5168bbdc68b /include/target/target_core_base.h
parent802ec4f672ed64fc3e6a09aa0e4a92a018383767 (diff)
scsi: target: core: Fix backend plugging
target_core_iblock is plugging and unplugging on every command and this is causing perf issues for drivers that prefer batched cmds. With recent patches we can now take multiple cmds from a fabric driver queue and then pass them down the backend drivers in a batch. This patch adds this support by adding 2 callouts to the backend for plugging and unplugging the device. Subsequent commits will add support for iblock and tcmu device plugging. Link: https://lore.kernel.org/r/20210227170006.5077-22-michael.christie@oracle.com Reviewed-by: Bodo Stroesser <bostroesser@gmail.com> Signed-off-by: Mike Christie <michael.christie@oracle.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/target/target_core_base.h')
-rw-r--r--include/target/target_core_base.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/target/target_core_base.h b/include/target/target_core_base.h
index fbe5b5b93afa..cf445c3a551a 100644
--- a/include/target/target_core_base.h
+++ b/include/target/target_core_base.h
@@ -770,6 +770,10 @@ struct se_cmd_queue {
struct work_struct work;
};
+struct se_dev_plug {
+ struct se_device *se_dev;
+};
+
struct se_device_queue {
struct list_head state_list;
spinlock_t lock;