public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Rabin VINCENT <rabin.vincent@stericsson.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 6/8] ux500: add SoC-specific code
Date: Wed, 7 Apr 2010 11:45:32 +0530	[thread overview]
Message-ID: <20100407061531.GC7459@bnru02.bnr.st.com> (raw)
In-Reply-To: <4BAF9503.5040706@windriver.com>

On Sun, Mar 28, 2010 at 07:42:27PM +0200, Tom wrote:
> Rabin Vincent wrote:
> > +/* Turn on peripheral clock at PRCC level */
> > +void u8500_clock_enable(int periph, int kern, int cluster)
> > +{
> > +     struct clkrst *clkrst = (struct clkrst *) clkrst_base[periph - 1];
> 
> -1 on array access.
> Convert to unsigned access

I'm not sure what you mean by this.  Periph numbering starts from 1.

> > +
> > +     if (kern != -1)
> > +             writel(1 << kern, &clkrst->kcken);
> > +
> > +     if (cluster != -1)
> > +             writel(1 << cluster, &clkrst->pcken);
> 
> Checking that some of the parameters are expected to be bad.
> This function should be split.

The three arguments to this function come from a table in the SoC
manual.  -1 corresponds to the "not used" cells in the table.  The
function is better unsplit since the majority of peripherals require
both the register writes to enable their clock.

Rabin

  reply	other threads:[~2010-04-07  6:15 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-18  4:20 [U-Boot] [PATCH 0/8] ST-Ericsson Ux500 support Rabin Vincent
2010-03-18  4:20 ` [U-Boot] [PATCH 1/8] Nomadik: move timer code to drivers/misc Rabin Vincent
2010-03-28 17:30   ` Tom
2010-04-06 11:16     ` Rabin VINCENT
2010-04-06 11:30       ` Alessandro Rubini
2010-03-18  4:28 ` [U-Boot] [PATCH 2/8] Nomadik: move gpio driver to drivers/gpio Rabin Vincent
2010-03-28 17:32   ` Tom
2010-04-06 11:25     ` Rabin VINCENT
2010-03-18  5:02 ` [U-Boot] [PATCH 3/8] nomadik_gpio: get base address from platform code Rabin Vincent
2010-03-28 17:35   ` Tom
2010-03-18  5:08 ` [U-Boot] [PATCH 4/8] nomadik_mtu: support configurable clock rates Rabin Vincent
2010-03-28 17:36   ` Tom
2010-03-18  5:10 ` [U-Boot] [PATCH 5/8] ARM Cortex A8: ifdef code calling lowlevel init Rabin Vincent
2010-03-28 17:38   ` Tom
2010-03-18  5:10 ` [U-Boot] [PATCH 6/8] ux500: add SoC-specific code Rabin Vincent
2010-03-28 17:42   ` Tom
2010-04-07  6:15     ` Rabin VINCENT [this message]
2010-03-18  5:10 ` [U-Boot] [PATCH 7/8] pl01x: add support for Ux500 variant of pl011 Rabin Vincent
2010-03-28 17:45   ` Tom
2010-03-18  5:33 ` [U-Boot] [PATCH 8/8] mop500: add board-specific files Rabin Vincent
2010-03-28 17:49   ` Tom
2010-04-08 13:41     ` Rabin VINCENT
2010-04-09 22:28       ` Wolfgang Denk
2010-04-17 21:46       ` Tom Rix
2010-03-21 19:42 ` [U-Boot] [PATCH 0/8] ST-Ericsson Ux500 support Wolfgang Denk
2010-03-28 17:27 ` Tom

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=20100407061531.GC7459@bnru02.bnr.st.com \
    --to=rabin.vincent@stericsson.com \
    --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