Skip to content

Commit 2d6c7bc

Browse files
superna9999martinkpetersen
authored andcommitted
scsi: ufs: core: Track when MCQ ESI is enabled
In preparation of adding a threaded interrupt handler, track when the MCQ ESI interrupt handlers were installed so we can optimize the MCQ interrupt handling to avoid walking the threaded handler in the case ESI handlers are enabled. Signed-off-by: Neil Armstrong <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent 56f4bef commit 2d6c7bc

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

drivers/ufs/core/ufshcd.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8717,6 +8717,7 @@ static void ufshcd_config_mcq(struct ufs_hba *hba)
87178717
u32 intrs;
87188718

87198719
ret = ufshcd_mcq_vops_config_esi(hba);
8720+
hba->mcq_esi_enabled = !ret;
87208721
dev_info(hba->dev, "ESI %sconfigured\n", ret ? "is not " : "");
87218722

87228723
intrs = UFSHCD_ENABLE_MCQ_INTRS;

include/ufs/ufshcd.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -954,6 +954,7 @@ enum ufshcd_mcq_opr {
954954
* ufshcd_resume_complete()
955955
* @mcq_sup: is mcq supported by UFSHC
956956
* @mcq_enabled: is mcq ready to accept requests
957+
* @mcq_esi_enabled: is mcq ESI configured
957958
* @res: array of resource info of MCQ registers
958959
* @mcq_base: Multi circular queue registers base address
959960
* @uhq: array of supported hardware queues
@@ -1122,6 +1123,7 @@ struct ufs_hba {
11221123
bool mcq_sup;
11231124
bool lsdb_sup;
11241125
bool mcq_enabled;
1126+
bool mcq_esi_enabled;
11251127
struct ufshcd_res_info res[RES_MAX];
11261128
void __iomem *mcq_base;
11271129
struct ufs_hw_queue *uhq;

0 commit comments

Comments
 (0)