tqm5200: Correct comment and code in post_hotkeys_pressed.

This fixes the code and the comment according to the original intent of
doing an intensive memory test when PSC6_3 is pulled low on the STK52xx.
Notably PORT_CONFIG will be overridden with this correct code now,
so beware.

The original code only worked by coincidence depending on the PORT_CONFIG
setting from the header file.  The new code was tested to ensure that the
(undocumented) memory test still works on the STK52x.

Signed-off-by: Detlev Zundel <dzu@denx.de>
CC: Martin Krause <Martin.Krause@tqs.de>

Minor white-space cleanup.
Signed-off-by: Wolfgang Denk <wd@denx.de>
This commit is contained in:
Detlev Zundel 2009-10-07 16:38:05 +02:00 committed by Wolfgang Denk
parent da01f53404
commit 95c44ec485
2 changed files with 10 additions and 10 deletions

View file

@ -358,11 +358,9 @@ int post_hotkeys_pressed(void)
gpio = (struct mpc5xxx_gpio*) MPC5XXX_GPIO; gpio = (struct mpc5xxx_gpio*) MPC5XXX_GPIO;
/* /*
* Configure PSC6_1 and PSC6_3 as GPIO. PSC6 then couldn't be used in * Configure PSC6_0 through PSC6_3 as GPIO.
* CODEC or UART mode. Consumer IrDA should still be possible.
*/ */
gpio->port_config &= ~(0x07000000); gpio->port_config &= ~(0x00700000);
gpio->port_config |= 0x03000000;
/* Enable GPIO for GPIO_IRDA_1 (IR_USB_CLK pin) = PSC6_3 */ /* Enable GPIO for GPIO_IRDA_1 (IR_USB_CLK pin) = PSC6_3 */
gpio->simple_gpioe |= 0x20000000; gpio->simple_gpioe |= 0x20000000;

View file

@ -540,6 +540,8 @@
* 101 -> use PSC6 as UART. Pins PSC6_0 to PSC6_3 are used. * 101 -> use PSC6 as UART. Pins PSC6_0 to PSC6_3 are used.
* Extended POST test is not available. * Extended POST test is not available.
* Use for STK52xx, FO300 and CAM5200 boards. * Use for STK52xx, FO300 and CAM5200 boards.
* WARNING: When the extended POST is enabled, these bits will
* be overridden by this code as GPIOs!
* use PCI_DIS: Bit 16 (mask 0x00008000): * use PCI_DIS: Bit 16 (mask 0x00008000):
* 1 -> disable PCI controller (on CAM5200 board). * 1 -> disable PCI controller (on CAM5200 board).
* use USB: Bits 18-19 (mask 0x00003000): * use USB: Bits 18-19 (mask 0x00003000):