[U-Boot] [PATCH] pm9263 converted to at91 soc access

Tom Rix tom at bumblecow.com
Sat Apr 17 23:09:12 CEST 2010


RONETIX - Asen Dimov wrote:
> Tom wrote:
>> Asen Dimov wrote:
>>> Signed-off-by: Asen Dimov <dimov at ronetix.at>
>>> ---
>>>  board/ronetix/pm9263/led.c    |   15 ++--
>>>  board/ronetix/pm9263/pm9263.c |  195 
>>> +++++++++++++++++++++--------------------
>>>  include/configs/pm9263.h      |   82 ++++++++---------
>>>  3 files changed, 146 insertions(+), 146 deletions(-)

<snip>


>>> +
>>>      /* Enable clock */
>>> -    at91_sys_write(AT91_PMC_PCER, 1 << AT91SAM9263_ID_PIOB |
>>> -                      1 << AT91SAM9263_ID_PIOCDE);
>>> +    writel(1 << AT91SAM9263_ID_PIOB, &pmc->pcer);
>> Missing PICOCDE..
>> Is this ok ?
>>
> The two leds are on PIOB, no leds on PIO: C, D or E.
> It is ok.
>>>  

ok

>>> -    at91_set_gpio_output(CONFIG_RED_LED, 1);
>>> -    at91_set_gpio_output(CONFIG_GREEN_LED, 1);

<snip>

>>> -               csa | AT91_MATRIX_EBI0_CS3A_SMC_SMARTMEDIA);
>>> +    csa = readl(&matrix->csa[0]) | AT91_MATRIX_CSA_EBI_CS3A;
>>> +    writel(csa, &matrix->csa[0]);
>> Missing SMARTMEDIA
>> Is this ok?
>>
> AT91_MATRIX_EBI0_CS3A_SMC_SMARTMEDIA sets the SMARTMEDIA bit and
> AT91_MATRIX_CSA_EBI_CS3A sets the SMARTMEDIA bit too.
> It is ok.

ok

>>>  
>>>      /* Configure SMC CS3 for NAND/SmartMedia */

<snip>
>>> +    writel(1 << 25, &pio->pioc.puer);
>>> +    writel((1 << 25) | (1 << 26), &pio->pioe.puer);
>>>  
>> There should be #defines for these values.
>> There are similar cases where old #define's have be
>> converted to bit ops.  The old method of #defines is preferred
> Ok. I will #define the values.
>> Tom
> Regards,
> Asen

Tom


More information about the U-Boot mailing list