summaryrefslogtreecommitdiff
path: root/arch/arm/cpu/pxa
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2019-11-14 12:57:28 -0700
committerTom Rini <trini@konsulko.com>2019-12-02 18:23:11 -0500
commite3107d159c180698bd45511afb76e9ab8f9957fb (patch)
tree48b41d2d695050e9f3400d377df947edca95e032 /arch/arm/cpu/pxa
parent036a017f79f6c485605c555b3a8733debb72d995 (diff)
arm: pxa: Drop pxa_wait_ticks()
This function has a similar name to the common wait_ticks(). It is only used in one place and seems small enough to drop. Inline it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'arch/arm/cpu/pxa')
-rw-r--r--arch/arm/cpu/pxa/pxa2xx.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/arch/arm/cpu/pxa/pxa2xx.c b/arch/arm/cpu/pxa/pxa2xx.c
index 0b28f0a3ef..14fe307c1a 100644
--- a/arch/arm/cpu/pxa/pxa2xx.c
+++ b/arch/arm/cpu/pxa/pxa2xx.c
@@ -39,13 +39,6 @@ int cleanup_before_linux(void)
return 0;
}
-void pxa_wait_ticks(int ticks)
-{
- writel(0, OSCR);
- while (readl(OSCR) < ticks)
- asm volatile("" : : : "memory");
-}
-
inline void writelrb(uint32_t val, uint32_t addr)
{
writel(val, addr);
@@ -136,8 +129,11 @@ void pxa2xx_dram_init(void)
writelrb(CONFIG_SYS_MDCNFG_VAL &
~(MDCNFG_DE0 | MDCNFG_DE1 | MDCNFG_DE2 | MDCNFG_DE3), MDCNFG);
+
/* Wait for the clock to the SDRAMs to stabilize, 100..200 usec. */
- pxa_wait_ticks(0x300);
+ writel(0, OSCR);
+ while (readl(OSCR) < 0x300)
+ asm volatile("" : : : "memory");
/*
* 8) Trigger a number (usually 8) refresh cycles by attempting