From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?ISO-8859-1?Q?Andreas_Bie=DFmann?= Date: Tue, 07 Aug 2012 09:09:57 +0200 Subject: [U-Boot] [PATCH v4] at91: Add support for taskit AT91SAM9G20 boards. In-Reply-To: <20120806183736.019114d5-d17e-49ba-a2ec-eeb5f47de4df.mhubig@imko.de> References: <1344244285-26071-1-git-send-email-mhubig@imko.de> <501FC034.5080506@gmail.com> <20120806183736.019114d5-d17e-49ba-a2ec-eeb5f47de4df.mhubig@imko.de> Message-ID: <5020BF45.4040805@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Markus Hubig, On 06.08.2012 18:49, Markus Hubig wrote: > On Mon, Aug 06, 2012 at 03:01:40PM +0200, Andreas Bie?mann wrote: >> On 06.08.2012 11:11, Markus Hubig wrote: >>> >>> +static unsigned int saved_state[3] = {STATUS_LED_OFF, >>> + STATUS_LED_OFF, STATUS_LED_OFF}; >>> + >>> +void coloured_LED_init(void) >>> +{ >>> + /* Clock is enabled in board_early_init_f() */ >> >> But coloured_LED_init() is called way before! >> >> Beware, this coloured LED stuff is sometimes used for very early debug >> purposes. To get this working you will need to switch the clocks here. >> >> If you not insist on this colour LED framework I would appreciate to not >> add this coloured_LED_init for the stamp9g20 but use the status LED >> framework -> README.LED > > Are you shure about this? No, I've not worked with that status LED thing. Contrastingly I thought that LED stuff is at91 specific. But there are some other ARM SoC using this colored LED and status LED thing. So this appears to be a wrong decision. > Is I just remove this and put the > >>> + at91_set_gpio_output(CONFIG_RED_LED, 1); >>> + at91_set_gpio_output(CONFIG_GREEN_LED, 1); >>> + at91_set_gpio_output(CONFIG_YELLOW_LED, 1); > > in __led_init() I have no LED's at all and the commandlie tool 'led' > stopps working... At all the Status LED stuff is a bit confusing ... > > - It's not clear to me if the STATUS_LED_BIT should be e.g. 1 or > e.g. AT91_PIN_PC5. > > - It's not clear what the benefit of using this is. > > - It's not clear if the coloured_LED stuff is part of it or something > extra. Sorry, I can not help you here. > Maybe it's better is I just switch on the green LED in board_init? but you will loose the led cmd which may be useful. > For now I just switched the clock on in coloured_LED_init. At least I > have some LED now. Thats ok with me. Best regards Andreas Bie?mann