All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christian Riesch <christian.riesch@omicron.at>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 6/8] arm, davinci, am1808: add lowlevel functions for booting from NOR
Date: Tue, 27 Sep 2011 08:57:56 +0200	[thread overview]
Message-ID: <CABkLObrh-c1EEYQ-hWxEV-i58J1oy_fv5VcZ51zPDscq91BZDw@mail.gmail.com> (raw)
In-Reply-To: <4E8037C8.5020905@denx.de>

Hello Heiko,
Thank you for your reply. I have just noticed that the patches have
already been pulled into arm/next so I guess I am quite late with my
comments. I'd like to apologize for this; apparently I need another
email filter that also filters for messages containing "am1808" and
not only "da850" ;-)

Which brings me to my next point: AFAIK Texas Instruments's AM18xx
SoCs, their OMAP-L138, and their DA850 based devices basically differ
only in the DSP/PRU part of the device. If you are (like in u-boot)
only interested in the ARM part of chip, they are basically the same
device. For some reason the Linux kernel and u-boot support for all
these devices is labelled da850... Although I have no hardware to test
it, I guess that your DDR memory controller initialization code could
be used for the OMAP-L138 and the corresponding Davinci device as
well. So since all code in u-boot for the entire device family is
labelled da850... I guess your DDR initialization functions should get
this prefix as well for consistency. Any comments from the
maintainers/TI employees who know these devices better than I do?

On Mon, Sep 26, 2011 at 10:28 AM, Heiko Schocher <hs@denx.de> wrote:
> Hello Christian,
>
> Christian Riesch wrote:
>> Heiko,
>> I am looking forward to see these patches in mainline u-boot. My
>> custom board also directly boots from NOR, so I think there is a lot I
>> can re-use for my board.
>
> Thats the goal ;-)
>
>> I have one question, please see below:
> [...]
>>> +void am1808_lpc_transition(unsigned char pscnum, unsigned char module,
>>> + ? ? ? ? ? ? ? unsigned char domain, unsigned char state)
>>> +{
> [...]
>>> + ? ? ? /* Wait for transition to complete */
>>> + ? ? ? while (readl(&reg->ptstat) & (0x00000001 << domain))
>>> + ? ? ? ? ? ? ? ;
>>> +
>>> + ? ? ? /* Wait and verify the state */
>>> + ? ? ? while ((readl(mdstat) & 0x1F) != state)
>>> + ? ? ? ? ? ? ? ;
>>> +}
>>
>> There is some similar code in arch/arm/cpu/arm926ejs/davinci/psc.c. Is
>> there any reason why you don't use this code or adapt it for your
>> needs?
>
> No, there is no reason, just missed it! I try the functions in
> arch/arm/cpu/arm926ejs/davinci/psc.c and if they work, I remove the
> am1808_lpc_transition function.

Ok. Actually you do LPSC transitions twice in your board
configuration, first in the low level initialization in
arch/arm/cpu/arm926ejs/davinci/am1808_lowlevel.c (using your own
function) and then again in your board initialization in
board/enbw/enbw_cmc/enbw_cmc.c (using the code in
arch/arm/cpu/arm926ejs/davinci/psc.c). I assume you ran into the same
problem as I did with the da850evm board. The UART is used before it
is turned on in the board_init() function. A few weeks ago I submitted
a patch [1][2] for this issue but did not get any comments on it.
Would you mind having a look at it so we could find a common solution
for both your configuration and the da850evm?

Regards, Christian

[1] http://lists.denx.de/pipermail/u-boot/2011-September/100352.html
[2] http://patchwork.ozlabs.org/patch/113335/

  reply	other threads:[~2011-09-27  6:57 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-15  5:59 [U-Boot] [PATCH 0/8] arm, davinci: add support for the am1808 based enbw_cmc board Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 1/8] arm, davinci: add SYSCFG1 base and register struct Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 2/8] arm, davinci: add some missing defines in hardware.h Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 3/8] arm, davinci, am1808, gpio: add missing defines for bank 8 Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 4/8] arm, davinci: add ddr2 definition Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 5/8] arm, davinci: add NOR Boot Configuration Word Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 6/8] arm, davinci, am1808: add lowlevel functions for booting from NOR Heiko Schocher
2011-09-26  8:02   ` Christian Riesch
2011-09-26  8:28     ` Heiko Schocher
2011-09-27  6:57       ` Christian Riesch [this message]
2011-09-27  7:27         ` Heiko Schocher
2011-09-27  8:37           ` Christian Riesch
2011-09-27  8:50             ` Heiko Schocher
2011-09-27 10:36               ` Christian Riesch
2011-09-27 11:18         ` Heiko Schocher
2011-09-30  6:57   ` Christian Riesch
2011-09-30  7:11     ` Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 7/8] arm, davinci, da8xx: add cpuinfo Heiko Schocher
2011-09-15  5:59 ` [U-Boot] [PATCH 8/8] arm, davinci: add support for am1808 based enbw_cmc board Heiko Schocher
2011-09-15  7:39   ` Igor Grinberg
2011-09-15  7:56     ` Heiko Schocher
2011-09-19  5:50   ` [U-Boot] [PATCH v2 " Heiko Schocher
2011-09-23 20:47     ` Paulraj, Sandeep
2011-09-26  5:43       ` Heiko Schocher
2011-09-26  6:03         ` Paulraj, Sandeep
2011-09-26  6:08           ` Heiko Schocher
2011-09-27  7:05           ` Albert ARIBAUD
2011-09-30  7:55     ` Christian Riesch
2011-09-30  8:46       ` Heiko Schocher
2011-09-30  9:02         ` Christian Riesch
2011-09-30  9:32           ` Heiko Schocher

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=CABkLObrh-c1EEYQ-hWxEV-i58J1oy_fv5VcZ51zPDscq91BZDw@mail.gmail.com \
    --to=christian.riesch@omicron.at \
    --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.