Skip to content

Commit

Permalink
sunxi: add support for H616 uart0
Browse files Browse the repository at this point in the history
This port is used for debug terminal on all known H616 boards.

Reviewed-by: Samuel Holland <[email protected]>
Signed-off-by: Jernej Skrabec <[email protected]>
Reviewed-by: Andre Przywara <[email protected]>
Signed-off-by: Andre Przywara <[email protected]>
  • Loading branch information
jernejsk authored and Andre-ARM committed Jan 25, 2021
1 parent b18bd53 commit c13d98b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions arch/arm/include/asm/arch-sunxi/gpio.h
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ enum sunxi_gpio_number {
#define SUN6I_GPH_UART0 2
#define SUN9I_GPH_UART0 2
#define SUN50I_H6_GPH_UART0 2
#define SUN50I_H616_GPH_UART0 2

#define SUNXI_GPI_SDC3 2
#define SUN7I_GPI_TWI3 3
Expand Down
4 changes: 4 additions & 0 deletions arch/arm/mach-sunxi/board.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,10 @@ static int gpio_init(void)
sunxi_gpio_set_cfgpin(SUNXI_GPH(0), SUN50I_H6_GPH_UART0);
sunxi_gpio_set_cfgpin(SUNXI_GPH(1), SUN50I_H6_GPH_UART0);
sunxi_gpio_set_pull(SUNXI_GPH(1), SUNXI_GPIO_PULL_UP);
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_MACH_SUN50I_H616)
sunxi_gpio_set_cfgpin(SUNXI_GPH(0), SUN50I_H616_GPH_UART0);
sunxi_gpio_set_cfgpin(SUNXI_GPH(1), SUN50I_H616_GPH_UART0);
sunxi_gpio_set_pull(SUNXI_GPH(1), SUNXI_GPIO_PULL_UP);
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_MACH_SUN8I_A83T)
sunxi_gpio_set_cfgpin(SUNXI_GPB(9), SUN8I_A83T_GPB_UART0);
sunxi_gpio_set_cfgpin(SUNXI_GPB(10), SUN8I_A83T_GPB_UART0);
Expand Down

0 comments on commit c13d98b

Please sign in to comment.