From: Stefano Babic <sbabic@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 2/2] MX28: Fixup the ad-hoc use of DIGCTL_MICROSECONDS
Date: Wed, 29 Aug 2012 09:51:41 +0200 [thread overview]
Message-ID: <503DCA0D.1000004@denx.de> (raw)
In-Reply-To: <1346202953-19486-2-git-send-email-marex@denx.de>
On 29/08/2012 03:15, Marek Vasut wrote:
> Use proper struct-based access for this register in the SPL code.
>
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Wolfgang Denk <wd@denx.de>
> Cc: Stefano Babic <sbabic@denx.de>
> Cc: Fabio Estevam <festevam@freescale.com>
> ---
> arch/arm/cpu/arm926ejs/mxs/spl_boot.c | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/arch/arm/cpu/arm926ejs/mxs/spl_boot.c b/arch/arm/cpu/arm926ejs/mxs/spl_boot.c
> index ddafddb..ad66c57 100644
> --- a/arch/arm/cpu/arm926ejs/mxs/spl_boot.c
> +++ b/arch/arm/cpu/arm926ejs/mxs/spl_boot.c
> @@ -38,12 +38,14 @@
> * takes a few seconds to roll. The boot doesn't take that long, so to keep the
> * code simple, it doesn't take rolling into consideration.
> */
> -#define HW_DIGCTRL_MICROSECONDS 0x8001c0c0
> void early_delay(int delay)
> {
> - uint32_t st = readl(HW_DIGCTRL_MICROSECONDS);
> + struct mxs_digctl_regs *digctl_regs =
> + (struct mxs_digctl_regs *)MXS_DIGCTL_BASE;
> +
> + uint32_t st = readl(&digctl_regs->hw_digctl_microseconds);
> st += delay;
> - while (st > readl(HW_DIGCTRL_MICROSECONDS))
> + while (st > readl(&digctl_regs->hw_digctl_microseconds))
> ;
> }
>
>
Acked-by: Stefano Babic <sbabic@denx.de>
Best regards,
Stefano Babic
--
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================
next prev parent reply other threads:[~2012-08-29 7:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-29 1:15 [U-Boot] [PATCH 1/2] MX28: Cleanup mxsboot within make mrproper Marek Vasut
2012-08-29 1:15 ` [U-Boot] [PATCH 2/2] MX28: Fixup the ad-hoc use of DIGCTL_MICROSECONDS Marek Vasut
2012-08-29 7:51 ` Stefano Babic [this message]
2012-09-04 10:02 ` Stefano Babic
2012-08-29 7:51 ` [U-Boot] [PATCH 1/2] MX28: Cleanup mxsboot within make mrproper Stefano Babic
2012-09-04 10:02 ` Stefano Babic
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=503DCA0D.1000004@denx.de \
--to=sbabic@denx.de \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox