public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* microSD Breakout Port
@ 2020-06-25 20:13 Faruk Kılavuz
  2020-06-26 20:22 ` Tom Rini
  2020-07-11  9:09 ` Jagan Teki
  0 siblings, 2 replies; 3+ messages in thread
From: Faruk Kılavuz @ 2020-06-25 20:13 UTC (permalink / raw)
  To: u-boot

Hello

This is my first mail. I tried running uart-0 with microsd breakout method. I have added the following codes to open the F port.

diff --git a/arch/arm/include/asm/arch-sunxi/gpio.h b/arch/arm/include/asm/arch-sunxi/gpio.h
index 40a3f845d0..9140b35450 100644
--- a/arch/arm/include/asm/arch-sunxi/gpio.h
+++ b/arch/arm/include/asm/arch-sunxi/gpio.h
@@ -181,6 +181,7 @@ enum sunxi_gpio_number {
 #define SUNXI_GPF_SDC0         2
 #define SUNXI_GPF_UART0              4
 #define SUN8I_GPF_UART0                3
+#define SUN50I_GPF_UART0       3

 #define SUN4I_GPG_SDC1         4
 #define SUN5I_GPG_SDC1         2
diff --git a/arch/arm/mach-sunxi/board.c b/arch/arm/mach-sunxi/board.c
index b74eaf2a0e..019c9b9296 100644
--- a/arch/arm/mach-sunxi/board.c
+++ b/arch/arm/mach-sunxi/board.c
@@ -76,6 +76,9 @@ static int gpio_init(void)
 #if defined(CONFIG_MACH_SUN8I) && !defined(CONFIG_MACH_SUN8I_R40)
        sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN8I_GPF_UART0);
        sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN8I_GPF_UART0);
+#elif defined(CONFIG_MACH_SUN50I)
+       sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN50I_GPF_UART0);
+       sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN50I_GPF_UART0);
 #else
        sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUNXI_GPF_UART0);
        sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUNXI_GPF_UART0);


Should I send this code as a u-boot patch? Thanks

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* microSD Breakout Port
  2020-06-25 20:13 microSD Breakout Port Faruk Kılavuz
@ 2020-06-26 20:22 ` Tom Rini
  2020-07-11  9:09 ` Jagan Teki
  1 sibling, 0 replies; 3+ messages in thread
From: Tom Rini @ 2020-06-26 20:22 UTC (permalink / raw)
  To: u-boot

On Thu, Jun 25, 2020 at 08:13:08PM +0000, Faruk K?lavuz wrote:

> Hello
> 
> This is my first mail. I tried running uart-0 with microsd breakout method. I have added the following codes to open the F port.
> 
> diff --git a/arch/arm/include/asm/arch-sunxi/gpio.h b/arch/arm/include/asm/arch-sunxi/gpio.h
> index 40a3f845d0..9140b35450 100644
> --- a/arch/arm/include/asm/arch-sunxi/gpio.h
> +++ b/arch/arm/include/asm/arch-sunxi/gpio.h
> @@ -181,6 +181,7 @@ enum sunxi_gpio_number {
>  #define SUNXI_GPF_SDC0         2
>  #define SUNXI_GPF_UART0              4
>  #define SUN8I_GPF_UART0                3
> +#define SUN50I_GPF_UART0       3
> 
>  #define SUN4I_GPG_SDC1         4
>  #define SUN5I_GPG_SDC1         2
> diff --git a/arch/arm/mach-sunxi/board.c b/arch/arm/mach-sunxi/board.c
> index b74eaf2a0e..019c9b9296 100644
> --- a/arch/arm/mach-sunxi/board.c
> +++ b/arch/arm/mach-sunxi/board.c
> @@ -76,6 +76,9 @@ static int gpio_init(void)
>  #if defined(CONFIG_MACH_SUN8I) && !defined(CONFIG_MACH_SUN8I_R40)
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN8I_GPF_UART0);
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN8I_GPF_UART0);
> +#elif defined(CONFIG_MACH_SUN50I)
> +       sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN50I_GPF_UART0);
> +       sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN50I_GPF_UART0);
>  #else
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUNXI_GPF_UART0);
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUNXI_GPF_UART0);
> 
> 
> Should I send this code as a u-boot patch? Thanks

Thanks for your patch.  I've cc'd the sunxi maintainer for their
thoughts.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200626/3f98f0ce/attachment.sig>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* microSD Breakout Port
  2020-06-25 20:13 microSD Breakout Port Faruk Kılavuz
  2020-06-26 20:22 ` Tom Rini
@ 2020-07-11  9:09 ` Jagan Teki
  1 sibling, 0 replies; 3+ messages in thread
From: Jagan Teki @ 2020-07-11  9:09 UTC (permalink / raw)
  To: u-boot

On Fri, Jun 26, 2020 at 5:28 AM Faruk K?lavuz <farukkilavuz@hotmail.com> wrote:
>
> Hello
>
> This is my first mail. I tried running uart-0 with microsd breakout method. I have added the following codes to open the F port.
>
> diff --git a/arch/arm/include/asm/arch-sunxi/gpio.h b/arch/arm/include/asm/arch-sunxi/gpio.h
> index 40a3f845d0..9140b35450 100644
> --- a/arch/arm/include/asm/arch-sunxi/gpio.h
> +++ b/arch/arm/include/asm/arch-sunxi/gpio.h
> @@ -181,6 +181,7 @@ enum sunxi_gpio_number {
>  #define SUNXI_GPF_SDC0         2
>  #define SUNXI_GPF_UART0              4
>  #define SUN8I_GPF_UART0                3
> +#define SUN50I_GPF_UART0       3
>
>  #define SUN4I_GPG_SDC1         4
>  #define SUN5I_GPG_SDC1         2
> diff --git a/arch/arm/mach-sunxi/board.c b/arch/arm/mach-sunxi/board.c
> index b74eaf2a0e..019c9b9296 100644
> --- a/arch/arm/mach-sunxi/board.c
> +++ b/arch/arm/mach-sunxi/board.c
> @@ -76,6 +76,9 @@ static int gpio_init(void)
>  #if defined(CONFIG_MACH_SUN8I) && !defined(CONFIG_MACH_SUN8I_R40)
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN8I_GPF_UART0);
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN8I_GPF_UART0);
> +#elif defined(CONFIG_MACH_SUN50I)
> +       sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUN50I_GPF_UART0);
> +       sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUN50I_GPF_UART0);
>  #else
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(2), SUNXI_GPF_UART0);
>         sunxi_gpio_set_cfgpin(SUNXI_GPF(4), SUNXI_GPF_UART0);
>
>
> Should I send this code as a u-boot patch? Thanks

Yes, please.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-07-11  9:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-25 20:13 microSD Breakout Port Faruk Kılavuz
2020-06-26 20:22 ` Tom Rini
2020-07-11  9:09 ` Jagan Teki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox