From: Simon Glass <sjg@chromium.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v4 20/42] arm: pxa: Drop pxa_wait_ticks()
Date: Thu, 14 Nov 2019 12:57:28 -0700 [thread overview]
Message-ID: <20191114195751.30357-4-sjg@chromium.org> (raw)
In-Reply-To: <20191114195751.30357-1-sjg@chromium.org>
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>
---
Changes in v4: None
Changes in v3:
- Add new patch to inline pxa_wait_ticks()
Changes in v2: None
arch/arm/cpu/pxa/pxa2xx.c | 12 ++++--------
1 file 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
--
2.24.0.rc1.363.gb1bccd3e3d-goog
next prev parent reply other threads:[~2019-11-14 19:57 UTC|newest]
Thread overview: 60+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-14 19:57 [U-Boot] [PATCH v4 00/42] common: Further reduce common.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 01/42] common: Move older CPU functions to their own header Simon Glass
2019-11-20 0:45 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 02/42] Drop CONFIG_SHOW_ACTIVITY Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 03/42] common: Drop global inclusion of status_led.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 04/42] status_led: Tidy up the code style Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 05/42] common: Move random-number functions into their own header Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 06/42] common: Drop linux/crc8.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 07/42] crc: Fix code style with crc functions Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 08/42] crc32: Use the crc.h header for " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 09/42] spl: bootcount: Move code out of header file Simon Glass
2019-11-20 0:46 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 10/42] common: Move bootcount functions to their " Simon Glass
2019-11-20 0:45 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 11/42] common: Move sorting functions to their own " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 12/42] Move strtomhz() to vsprintf.h Simon Glass
2019-11-20 0:45 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 13/42] common: Move env_get_ip() to net.h Simon Glass
2019-11-18 21:27 ` Joe Hershberger
2019-11-14 19:57 ` [U-Boot] [PATCH v4 14/42] serial: usb: Correct the usbtty_...() prototypes Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 15/42] common: Move serial_printf() to the serial header Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 16/42] common: Move serial functions out of common.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 17/42] common: Add a new lz4.h header file Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 18/42] common: Move some time functions out of common.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 19/42] common: Move wait_ticks " Simon Glass
2019-11-14 19:57 ` Simon Glass [this message]
2019-11-14 19:57 ` [U-Boot] [PATCH v4 21/42] common: Move timer_get_us() function " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 22/42] common: Move get_ticks() " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 23/42] common: Move mii_init() " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 24/42] common: Move some CPU functions " Simon Glass
2019-11-20 0:45 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 25/42] common: Drop cpu_init() Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 26/42] common: Move checkcpu() out of common.h Simon Glass
2019-11-20 0:46 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 27/42] common: Move some SMP functions " Simon Glass
2019-11-20 0:46 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 28/42] arm: powerpc: Tidy up code style for cache functions Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 29/42] common: Move some cache and MMU functions out of common.h Simon Glass
2019-11-20 0:46 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 30/42] common: Drop checkicache() and checkdcache() Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 31/42] common: Move ARM cache operations out of common.h Simon Glass
2019-11-15 12:46 ` Daniel Schwierzeck
2019-11-15 16:46 ` Simon Glass
2019-11-20 0:46 ` Tom Rini
2019-11-14 19:57 ` [U-Boot] [PATCH v4 32/42] arm: powerpc: Tidy up code style for interrupt functions Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 33/42] common: Move interrupt functions into a new header Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 34/42] common: Move enable/disable_interrupts out of common.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 35/42] common: Move command functions " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 36/42] common: Drop board_show_dram() Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 37/42] common: Move board_get_usable_ram_top() out of common.h Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 38/42] common: Move some board functions " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 39/42] common: Move pci_init_board() " Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 40/42] common: Move trap_init() " Simon Glass
2019-11-15 13:07 ` Daniel Schwierzeck
2019-11-14 19:57 ` [U-Boot] [PATCH v4 41/42] common: Drop get_endaddr() Simon Glass
2019-11-14 19:57 ` [U-Boot] [PATCH v4 42/42] common: Move old EEPROM functions into a new header Simon Glass
2019-11-21 22:23 ` [U-Boot] [PATCH v4 00/42] common: Further reduce common.h Simon Glass
2019-11-21 23:03 ` Tom Rini
2019-11-22 0:21 ` Simon Glass
2019-12-03 3:10 ` Tom Rini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191114195751.30357-4-sjg@chromium.org \
--to=sjg@chromium.org \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.