[U-Boot] [PATCH] at91: Add support for taskit AT91SAM9G20 boards.

Markus Hubig mhubig at imko.de
Thu Aug 2 16:14:37 CEST 2012


On Wed, Aug 01, 2012 at 11:58:22AM +0200, Andreas Bießmann wrote:
> On 30.07.12 20:01, Markus Hubig wrote:
> >

<snipp>

> > +int board_early_init_f(void)
> > +{
> > +	struct at91_pmc *pmc = (struct at91_pmc *)ATMEL_BASE_PMC;
> > +
> > +	/* Enable clocks for all PIOs */
> > +	writel((1 << ATMEL_ID_PIOA) | (1 << ATMEL_ID_PIOB) |
> > +		(1 << ATMEL_ID_PIOC), &pmc->pcer);
> 
> you should initialize seriald_hw here to avoid strange characters on
> serial line when switching from at91bootstrap to u-boot.

<snip>

> > +	/* adress of boot parameters */
> > +	gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
> > +
> > +	at91_set_gpio_output(AT91_PIN_PC9, 1);
> > +	at91_set_gpio_output(AT91_PIN_PC5, 1);
> 
> Can you please add some comment why switching these pins?

OK now I now that PC5 switches the red LED on and there since is a
LED framework in u-boot I will use that in a later patch.

PC9 is somewhat strange. If I set it to 0 I don't have a console!

So I tried to put both

| at91_set_gpio_output(AT91_PIN_PC9, 1);
| at91_seriald_hw_init();

into board_early_init_f() to avoid the strange characters at boot time,
but again no console output ...

Further tests showed that It seems that I can't use at91_set_gpio_output()
inside board_early_init_f(). Switching on the red LED with PC5 also do not
work in board_early_init_f() ...

Any ideas?

Cheers, Markus


More information about the U-Boot mailing list