summaryrefslogtreecommitdiff
path: root/arch/arm/mach-imx
diff options
context:
space:
mode:
authorAnson Huang <Anson.Huang@nxp.com>2016-01-10 00:38:37 +0800
committerJason Liu <jason.hui.liu@nxp.com>2019-02-12 10:31:19 +0800
commit6d35143b05d241066f580b5a69fbdfe46120ff0f (patch)
treed34635cda42a287d40f53f95b31cceccb8a0ead3 /arch/arm/mach-imx
parent7964004a646886b10ecaa2e62b67c3a260c446e7 (diff)
MLK-12203-2 ARM: imx: adjust loop number to delay ~20us for i.MX7D low power idle
ARM does NOT execute one instruction every cycle, the bus bandwidth, cache status etc. would impacts the instruction execution time, so we can NOT just calculate the delay time by ARM frequency, this patch adjusts loop number to get a ~20us delay, measured via GPIO pin. Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Diffstat (limited to 'arch/arm/mach-imx')
-rw-r--r--arch/arm/mach-imx/imx7d_low_power_idle.S6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/arm/mach-imx/imx7d_low_power_idle.S b/arch/arm/mach-imx/imx7d_low_power_idle.S
index 2cc088df569f..07460dde6925 100644
--- a/arch/arm/mach-imx/imx7d_low_power_idle.S
+++ b/arch/arm/mach-imx/imx7d_low_power_idle.S
@@ -278,8 +278,8 @@
ldr r7, =0xf0000
str r7, [r10]
- /* assume ARM @ 1GHz, about delay 20us */
- ldr r7, =10000
+ /* delay 20us, measured by gpio */
+ ldr r7, =20
12:
subs r7, r7, #0x1
bne 12b
@@ -296,7 +296,7 @@
ldr r7, =0x0
str r7, [r10]
- ldr r7, =10000
+ ldr r7, =20
13:
subs r7, r7, #0x1
bne 13b