summaryrefslogtreecommitdiff
path: root/drivers/ufs
diff options
context:
space:
mode:
authorBart Van Assche <bvanassche@acm.org>2023-05-29 13:26:38 -0700
committerMartin K. Petersen <martin.petersen@oracle.com>2023-05-31 11:42:46 -0400
commit6c03c8e9b729a1ca2131a187233f8836a66a277b (patch)
tree9d423d1278f3dcf69f654941d5cab59ec1c7c80f /drivers/ufs
parentb125bb99559e3639764b8d169e3e9b80858fa2af (diff)
scsi: ufs: Conditionally enable the BLK_MQ_F_BLOCKING flag
Prepare for adding code in ufshcd_queuecommand() that may sleep. Acked-by: Adrian Hunter <adrian.hunter@intel.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Link: https://lore.kernel.org/r/20230529202640.11883-4-bvanassche@acm.org Reviewed-by: Bean Huo <beanhuo@micron.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/ufs')
-rw-r--r--drivers/ufs/core/ufshcd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c
index 17d7bb875fee..e093ce33887c 100644
--- a/drivers/ufs/core/ufshcd.c
+++ b/drivers/ufs/core/ufshcd.c
@@ -10218,6 +10218,7 @@ int ufshcd_init(struct ufs_hba *hba, void __iomem *mmio_base, unsigned int irq)
host->max_channel = UFSHCD_MAX_CHANNEL;
host->unique_id = host->host_no;
host->max_cmd_len = UFS_CDB_SIZE;
+ host->queuecommand_may_block = !!(hba->caps & UFSHCD_CAP_CLK_GATING);
hba->max_pwr_info.is_valid = false;