summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/ufs/ufs-mediatek.h
diff options
context:
space:
mode:
authorStanley Chu <stanley.chu@mediatek.com>2020-06-01 12:46:42 +0200
committerMartin K. Petersen <martin.petersen@oracle.com>2020-06-16 05:06:39 +0200
commitfb43337cd4cff6639b174e3b6766e6eade523836 (patch)
treeec6de8d7d90a652bc3eef23cebb94f867df4b2c6 /drivers/scsi/ufs/ufs-mediatek.h
parentscsi: ufs: ufs-exynos: Add UFS host support for Exynos SoCs (diff)
downloadlinux-fb43337cd4cff6639b174e3b6766e6eade523836.tar.xz
linux-fb43337cd4cff6639b174e3b6766e6eade523836.zip
scsi: ufs-mediatek: Fix imprecise waiting time for ref-clk control
Currently ref-clk control timeout is implemented by jiffies. However jiffies is not accurate enough thus "false timeout" may happen. Use more accurate delay mechanism instead, i.e. ktime. Link: https://lore.kernel.org/r/20200601104646.15436-2-stanley.chu@mediatek.com Reviewed-by: Andy Teng <andy.teng@mediatek.com> Reviewed-by: Avri Altman <avri.altman@wdc.com> Signed-off-by: Stanley Chu <stanley.chu@mediatek.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to '')
-rw-r--r--drivers/scsi/ufs/ufs-mediatek.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/ufs/ufs-mediatek.h b/drivers/scsi/ufs/ufs-mediatek.h
index 5bbd3e9cbae2..fc42dcbfd800 100644
--- a/drivers/scsi/ufs/ufs-mediatek.h
+++ b/drivers/scsi/ufs/ufs-mediatek.h
@@ -28,7 +28,7 @@
#define REFCLK_REQUEST BIT(0)
#define REFCLK_ACK BIT(1)
-#define REFCLK_REQ_TIMEOUT_MS 3
+#define REFCLK_REQ_TIMEOUT_US 3000
/*
* Vendor specific pre-defined parameters