diff options
author | Sreekanth Reddy <sreekanth.reddy@broadcom.com> | 2021-09-01 17:25:42 +0200 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2021-09-14 04:15:44 +0200 |
commit | e4953a93104c1fb1ef7989541f9867cc276467f9 (patch) | |
tree | 22bc70d877de042a6a09466bae067ad3a366cc28 /drivers | |
parent | scsi: iscsi: Adjust iface sysfs attr detection (diff) | |
download | linux-e4953a93104c1fb1ef7989541f9867cc276467f9.tar.xz linux-e4953a93104c1fb1ef7989541f9867cc276467f9.zip |
scsi: mpt3sas: Call cpu_relax() before calling udelay()
Call cpu_relax() while waiting for the current blk-mq polling instance to
complete.
Link: https://lore.kernel.org/r/20210901152542.27866-1-sreekanth.reddy@broadcom.com
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Sreekanth Reddy <sreekanth.reddy@broadcom.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/mpt3sas/mpt3sas_base.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.c b/drivers/scsi/mpt3sas/mpt3sas_base.c index 6c82435bc9cc..27eb652b564f 100644 --- a/drivers/scsi/mpt3sas/mpt3sas_base.c +++ b/drivers/scsi/mpt3sas/mpt3sas_base.c @@ -1582,8 +1582,10 @@ mpt3sas_base_pause_mq_polling(struct MPT3SAS_ADAPTER *ioc) * wait for current poll to complete. */ for (qid = 0; qid < iopoll_q_count; qid++) { - while (atomic_read(&ioc->io_uring_poll_queues[qid].busy)) + while (atomic_read(&ioc->io_uring_poll_queues[qid].busy)) { + cpu_relax(); udelay(500); + } } } |