[U-Boot] [PATCH v5 5/5] tegra2: Add support for Ventana
Mike Frysinger
vapier at gentoo.org
Wed Oct 12 20:02:22 CEST 2011
On Wednesday 12 October 2011 13:52:37 Stephen Warren wrote:
> --- a/board/nvidia/seaboard/seaboard.c
> +++ b/board/nvidia/seaboard/seaboard.c
> @@ -32,10 +32,10 @@
> #include "../common/board.h"
>
> /*
> - * Routine: gpio_config_uart
> + * Routine: gpio_config_uart_seaboard
> * Description: Force GPIO_PI3 low on Seaboard so UART4 works.
> */
> -void gpio_config_uart(void)
> +void gpio_config_uart_seaboard(void)
> {
> int gp = GPIO_PI3;
> struct gpio_ctlr *gpio = (struct gpio_ctlr *)NV_PA_GPIO_BASE;
> @@ -56,6 +56,13 @@ void gpio_config_uart(void)
> writel(val, &bank->gpio_dir_out[GPIO_PORT(gp)]);
> }
>
> +void gpio_config_uart(void)
> +{
> + if (machine_is_ventana())
> + return;
> + gpio_config_uart_seaboard();
> +}
another way to address this would be to add "__weak" to the existing
gpio_config_uart() function, and add a gpio_config_uart() stub to
board/nvidia/ventana/ventana.c.
although, if machine_is_ventana() returns a constant, and you marked
gpio_config_uart_seaboard() static (i think you want to do that anyways), the
code should come out the same.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20111012/cf21f5b9/attachment.pgp
More information about the U-Boot
mailing list