All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] U-Boot
       [not found] <CAP+B+qCMvQQBAGPaZ73UkKV2GpwoYx-OKVjjmLjB420fgwCEKA@mail.gmail.com>
@ 2018-02-12 14:59 ` Marek Vasut
  2018-02-12 15:13   ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Marek Vasut @ 2018-02-12 14:59 UTC (permalink / raw)
  To: u-boot

On 02/12/2018 03:52 PM, Mariano Coromac wrote:
> Hello, I was hoping you could help me out with something. I just have 2
> main questions. I am using a SAMA5D27 and I've managed to port
> AT91Bootloader and I'm currently on U-Boot

U-Boot SPL can bring SAMA5D2 up, you don't need the AT91 bootloader.

> 1. I am trying to use FLEXCOM1 (UART) as the main console of U-Boot but
> haven't been able to find any documentation saying where or how U-Boot
> specifies the console port.

$ git grep DEBUG_UART configs/sama5d2*
configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART=y
configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_ATMEL=y
configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_BASE=0xf8020000
configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_CLOCK=82000000
configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_BOARD_INIT=y
configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_ANNOUNCE=y

would indicate there's a debug uart which you can use.

I'm adding atmel maintainer to CC and dropping dead contacts.

> 2. When U-Boot tries to boot it gives me these errors:
> 
> bind node sdio-host at a0000000
>    - attempt to match compatible string 'atmel,sama5d2-sdhci'
> No match for node 'sdio-host at a0000000'
> bind node sdio-host at b0000000
>    - attempt to match compatible string 'atmel,sama5d2-sdhci'
> No match for node 'sdio-host at b0000000'
> bind node apb
>    - attempt to match compatible string 'simple-bus'
>    - found match at 'generic_simple_bus'
> bind node pmc at f0014000
>    - attempt to match compatible string 'atmel,sama5d2-pmc'
>    - found match at 'at91-pmc'
> bind node mainck
>    - attempt to match compatible string 'atmel,at91sam9x5-clk-main'
>    - found match at 'at91sam9x5-main-osc-clk'
> bind node pllack at 0
>    - attempt to match compatible string 'atmel,sama5d3-clk-pll'
>    - found match at 'at91-plla-clk'
> bind node utmick
>    - attempt to match compatible string 'atmel,at91sam9x5-clk-utmi'
> No match for node 'utmick'
> bind node masterck
>    - attempt to match compatible string 'atmel,at91sam9x5-clk-master'
>    - found match at 'at91-master-clk'
> bind node h32mxck
>    - attempt to match compatible string 'atmel,sama5d4-clk-h32mx'
> No match for node 'h32mxck'
> bind node periph32ck
>    - attempt to match compatible string 'atmel,at91sam9x5-clk-peripheral'
>    - found match at 'sam9x5-periph-clk'
> Cannot create device named 'uart1_clk at 25' (err=-12)
> Error binding driver 'sam9x5-periph-clk': -12
> bind node periph64ck
>    - attempt to match compatible string 'atmel,at91sam9x5-clk-peripheral'
>    - found match at 'sam9x5-periph-clk'
> Error binding driver 'sam9x5-periph-clk': -12
> bind node gck
>    - attempt to match compatible string 'atmel,sama5d2-clk-generated'
> No match for node 'gck'
> Some drivers failed to bind
> Error binding driver 'at91-pmc': -12
> bind node spi at f8000000
>    - attempt to match compatible string 'atmel,at91rm9200-spi'
> No match for node 'spi at f8000000'
> bind node serial at f8038200
>    - attempt to match compatible string 'atmel,at91sam9260-usart'
>    - found match at 'serial_atmel'
> Error binding driver 'serial_atmel': -12
> bind node gpio at fc038000
>    - attempt to match compatible string 'atmel,sama5d2-gpio'
>    - found match at 'gpio_atmel_pio4'
> Error binding driver 'gpio_atmel_pio4': -12
> Some drivers failed to bind
> Error binding driver 'generic_simple_bus': -12
> Some drivers failed to bind
> Error binding driver 'generic_simple_bus': -12
> Some drivers failed to bind
> initcall sequence 26f20864 failed at call 26f073e4 (err=-12)
> ### ERROR ### Please RESET the board ###
> 
> NOTE: On my lists.c file I changed all the "dm_debug" for "dm_warn"
> because the debug uart is the only one that's responding.
> Any help or guidance would be really appreciated.

Seems like some drivers are disabled.

Which version of U-Boot do you use ?

What platform did you derive your configuration from ?

-- 
Best regards,
Marek Vasut

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

* [U-Boot] U-Boot
  2018-02-12 14:59 ` [U-Boot] U-Boot Marek Vasut
@ 2018-02-12 15:13   ` Mariano Coromac
  2018-02-12 15:28     ` Marek Vasut
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-12 15:13 UTC (permalink / raw)
  To: u-boot

Oh ok.
My main problem is that I DO have debug_uart but I don't have U-Boot main
console.
I already have the configuration on my defconf for the debug UART like this:
CONFIG_DM=y
CONFIG_DM_SERIAL=y
CONFIG_DEBUG_UART=y
CONFIG_DEBUG_UART_ATMEL=y
CONFIG_DEBUG_UART_BASE=0xf8038200
CONFIG_DEBUG_UART_CLOCK=58000000
CONFIG_DEBUG_UART_BOARD_INIT=y
CONFIG_DEBUG_UART_ANNOUNCE=y
I cloned from the github repository *https://github.com/linux4sam/u-boot-at91
<https://github.com/linux4sam/u-boot-at91>*
My configuration was derived from the sama5d2_xplained board because I'm
working with a custom one.

On Mon, Feb 12, 2018 at 8:59 AM, Marek Vasut <marex@denx.de> wrote:

> On 02/12/2018 03:52 PM, Mariano Coromac wrote:
> > Hello, I was hoping you could help me out with something. I just have 2
> > main questions. I am using a SAMA5D27 and I've managed to port
> > AT91Bootloader and I'm currently on U-Boot
>
> U-Boot SPL can bring SAMA5D2 up, you don't need the AT91 bootloader.
>
> > 1. I am trying to use FLEXCOM1 (UART) as the main console of U-Boot but
> > haven't been able to find any documentation saying where or how U-Boot
> > specifies the console port.
>
> $ git grep DEBUG_UART configs/sama5d2*
> configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART=y
> configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_ATMEL=y
> configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_BASE=0xf8020000
> configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_CLOCK=82000000
> configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_BOARD_INIT=y
> configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_ANNOUNCE=y
>
> would indicate there's a debug uart which you can use.
>
> I'm adding atmel maintainer to CC and dropping dead contacts.
>
> > 2. When U-Boot tries to boot it gives me these errors:
> >
> > bind node sdio-host at a0000000
> >    - attempt to match compatible string 'atmel,sama5d2-sdhci'
> > No match for node 'sdio-host at a0000000'
> > bind node sdio-host at b0000000
> >    - attempt to match compatible string 'atmel,sama5d2-sdhci'
> > No match for node 'sdio-host at b0000000'
> > bind node apb
> >    - attempt to match compatible string 'simple-bus'
> >    - found match at 'generic_simple_bus'
> > bind node pmc at f0014000
> >    - attempt to match compatible string 'atmel,sama5d2-pmc'
> >    - found match at 'at91-pmc'
> > bind node mainck
> >    - attempt to match compatible string 'atmel,at91sam9x5-clk-main'
> >    - found match at 'at91sam9x5-main-osc-clk'
> > bind node pllack at 0
> >    - attempt to match compatible string 'atmel,sama5d3-clk-pll'
> >    - found match at 'at91-plla-clk'
> > bind node utmick
> >    - attempt to match compatible string 'atmel,at91sam9x5-clk-utmi'
> > No match for node 'utmick'
> > bind node masterck
> >    - attempt to match compatible string 'atmel,at91sam9x5-clk-master'
> >    - found match at 'at91-master-clk'
> > bind node h32mxck
> >    - attempt to match compatible string 'atmel,sama5d4-clk-h32mx'
> > No match for node 'h32mxck'
> > bind node periph32ck
> >    - attempt to match compatible string 'atmel,at91sam9x5-clk-
> peripheral'
> >    - found match at 'sam9x5-periph-clk'
> > Cannot create device named 'uart1_clk at 25' (err=-12)
> > Error binding driver 'sam9x5-periph-clk': -12
> > bind node periph64ck
> >    - attempt to match compatible string 'atmel,at91sam9x5-clk-
> peripheral'
> >    - found match at 'sam9x5-periph-clk'
> > Error binding driver 'sam9x5-periph-clk': -12
> > bind node gck
> >    - attempt to match compatible string 'atmel,sama5d2-clk-generated'
> > No match for node 'gck'
> > Some drivers failed to bind
> > Error binding driver 'at91-pmc': -12
> > bind node spi at f8000000
> >    - attempt to match compatible string 'atmel,at91rm9200-spi'
> > No match for node 'spi at f8000000'
> > bind node serial at f8038200
> >    - attempt to match compatible string 'atmel,at91sam9260-usart'
> >    - found match at 'serial_atmel'
> > Error binding driver 'serial_atmel': -12
> > bind node gpio at fc038000
> >    - attempt to match compatible string 'atmel,sama5d2-gpio'
> >    - found match at 'gpio_atmel_pio4'
> > Error binding driver 'gpio_atmel_pio4': -12
> > Some drivers failed to bind
> > Error binding driver 'generic_simple_bus': -12
> > Some drivers failed to bind
> > Error binding driver 'generic_simple_bus': -12
> > Some drivers failed to bind
> > initcall sequence 26f20864 failed at call 26f073e4 (err=-12)
> > ### ERROR ### Please RESET the board ###
> >
> > NOTE: On my lists.c file I changed all the "dm_debug" for "dm_warn"
> > because the debug uart is the only one that's responding.
> > Any help or guidance would be really appreciated.
>
> Seems like some drivers are disabled.
>
> Which version of U-Boot do you use ?
>
> What platform did you derive your configuration from ?
>
> --
> Best regards,
> Marek Vasut
>



-- 
Mariano Coromac <https://gps.gt/>
I&D of Electronics Engineer
mcoromac at stsa.info
+502 41544712
www.gps.gt <http://facebook.com/startracksa>

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

* [U-Boot] U-Boot
  2018-02-12 15:13   ` Mariano Coromac
@ 2018-02-12 15:28     ` Marek Vasut
  2018-02-12 16:28       ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Marek Vasut @ 2018-02-12 15:28 UTC (permalink / raw)
  To: u-boot

On 02/12/2018 04:13 PM, Mariano Coromac wrote:
> Oh ok.
> My main problem is that I DO have debug_uart but I don't have U-Boot
> main console.
> I already have the configuration on my defconf for the debug UART like this:
> CONFIG_DM=y
> CONFIG_DM_SERIAL=y
> CONFIG_DEBUG_UART=y
> CONFIG_DEBUG_UART_ATMEL=y
> CONFIG_DEBUG_UART_BASE=0xf8038200
> CONFIG_DEBUG_UART_CLOCK=58000000
> CONFIG_DEBUG_UART_BOARD_INIT=y
> CONFIG_DEBUG_UART_ANNOUNCE=y
> I cloned from the github repository
> *https://github.com/linux4sam/u-boot-at91*
> My configuration was derived from the sama5d2_xplained board because I'm
> working with a custom one.

If you used vendor fork of U-Boot, please ask vendor, the U-Boot
upstream repo is at [1]. You should rather use that. Adding more Atmel
people on CC, they should be able to help.

You should also tell us which version (or even better, which commit in
which repo) do you use. That's important.

Also please stop top-posting.

[1] http://git.denx.de/?p=u-boot.git;a=summary

> On Mon, Feb 12, 2018 at 8:59 AM, Marek Vasut <marex@denx.de
> <mailto:marex@denx.de>> wrote:
> 
>     On 02/12/2018 03:52 PM, Mariano Coromac wrote:
>     > Hello, I was hoping you could help me out with something. I just have 2
>     > main questions. I am using a SAMA5D27 and I've managed to port
>     > AT91Bootloader and I'm currently on U-Boot
> 
>     U-Boot SPL can bring SAMA5D2 up, you don't need the AT91 bootloader.
> 
>     > 1. I am trying to use FLEXCOM1 (UART) as the main console of U-Boot but
>     > haven't been able to find any documentation saying where or how U-Boot
>     > specifies the console port.
> 
>     $ git grep DEBUG_UART configs/sama5d2*
>     configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART=y
>     configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_ATMEL=y
>     configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_BASE=0xf8020000
>     configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_CLOCK=82000000
>     configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_BOARD_INIT=y
>     configs/sama5d27_som1_ek_mmc_defconfig:CONFIG_DEBUG_UART_ANNOUNCE=y
> 
>     would indicate there's a debug uart which you can use.
> 
>     I'm adding atmel maintainer to CC and dropping dead contacts.
> 
>     > 2. When U-Boot tries to boot it gives me these errors:
>     >
>     > bind node sdio-host at a0000000
>     >    - attempt to match compatible string 'atmel,sama5d2-sdhci'
>     > No match for node 'sdio-host at a0000000'
>     > bind node sdio-host at b0000000
>     >    - attempt to match compatible string 'atmel,sama5d2-sdhci'
>     > No match for node 'sdio-host at b0000000'
>     > bind node apb
>     >    - attempt to match compatible string 'simple-bus'
>     >    - found match at 'generic_simple_bus'
>     > bind node pmc at f0014000
>     >    - attempt to match compatible string 'atmel,sama5d2-pmc'
>     >    - found match at 'at91-pmc'
>     > bind node mainck
>     >    - attempt to match compatible string 'atmel,at91sam9x5-clk-main'
>     >    - found match at 'at91sam9x5-main-osc-clk'
>     > bind node pllack at 0
>     >    - attempt to match compatible string 'atmel,sama5d3-clk-pll'
>     >    - found match at 'at91-plla-clk'
>     > bind node utmick
>     >    - attempt to match compatible string 'atmel,at91sam9x5-clk-utmi'
>     > No match for node 'utmick'
>     > bind node masterck
>     >    - attempt to match compatible string 'atmel,at91sam9x5-clk-master'
>     >    - found match at 'at91-master-clk'
>     > bind node h32mxck
>     >    - attempt to match compatible string 'atmel,sama5d4-clk-h32mx'
>     > No match for node 'h32mxck'
>     > bind node periph32ck
>     >    - attempt to match compatible string
>     'atmel,at91sam9x5-clk-peripheral'
>     >    - found match at 'sam9x5-periph-clk'
>     > Cannot create device named 'uart1_clk at 25' (err=-12)
>     > Error binding driver 'sam9x5-periph-clk': -12
>     > bind node periph64ck
>     >    - attempt to match compatible string
>     'atmel,at91sam9x5-clk-peripheral'
>     >    - found match at 'sam9x5-periph-clk'
>     > Error binding driver 'sam9x5-periph-clk': -12
>     > bind node gck
>     >    - attempt to match compatible string 'atmel,sama5d2-clk-generated'
>     > No match for node 'gck'
>     > Some drivers failed to bind
>     > Error binding driver 'at91-pmc': -12
>     > bind node spi at f8000000
>     >    - attempt to match compatible string 'atmel,at91rm9200-spi'
>     > No match for node 'spi at f8000000'
>     > bind node serial at f8038200
>     >    - attempt to match compatible string 'atmel,at91sam9260-usart'
>     >    - found match at 'serial_atmel'
>     > Error binding driver 'serial_atmel': -12
>     > bind node gpio at fc038000
>     >    - attempt to match compatible string 'atmel,sama5d2-gpio'
>     >    - found match at 'gpio_atmel_pio4'
>     > Error binding driver 'gpio_atmel_pio4': -12
>     > Some drivers failed to bind
>     > Error binding driver 'generic_simple_bus': -12
>     > Some drivers failed to bind
>     > Error binding driver 'generic_simple_bus': -12
>     > Some drivers failed to bind
>     > initcall sequence 26f20864 failed at call 26f073e4 (err=-12)
>     > ### ERROR ### Please RESET the board ###
>     >
>     > NOTE: On my lists.c file I changed all the "dm_debug" for "dm_warn"
>     > because the debug uart is the only one that's responding.
>     > Any help or guidance would be really appreciated.
> 
>     Seems like some drivers are disabled.
> 
>     Which version of U-Boot do you use ?
> 
>     What platform did you derive your configuration from ?
> 
>     --
>     Best regards,
>     Marek Vasut
> 
> 
> 
> 
> -- 
> Mariano Coromac	<https://gps.gt/>
> I&D of Electronics Engineer
> mcoromac at stsa.info <mailto:mcoromac@stsa.info>
> +502 41544712
> www.gps.gt <http://www.gps.gt>	<http://facebook.com/startracksa>
> 


-- 
Best regards,
Marek Vasut

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

* [U-Boot] U-Boot
  2018-02-12 15:28     ` Marek Vasut
@ 2018-02-12 16:28       ` Mariano Coromac
  2018-02-12 16:39         ` Nicolas Ferre
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-12 16:28 UTC (permalink / raw)
  To: u-boot

Sorry, I tried to switch to the upstream repo but it gave some compiling
errors.
I am using the 409952795f8a28d3c266b2b8b2b9eccf46347601 commit from git://
github.com/linux4sam/u-boot-at91.git

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

* [U-Boot] U-Boot
  2018-02-12 16:28       ` Mariano Coromac
@ 2018-02-12 16:39         ` Nicolas Ferre
  2018-02-12 17:13           ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Nicolas Ferre @ 2018-02-12 16:39 UTC (permalink / raw)
  To: u-boot

On 12/02/2018 at 17:28, Mariano Coromac wrote:
> Sorry, I tried to switch to the upstream repo but it gave some compiling
> errors.
> I am using the 409952795f8a28d3c266b2b8b2b9eccf46347601 commit from
> git://github.com/linux4sam/u-boot-at91.git
> <http://github.com/linux4sam/u-boot-at91.git>

Can you tell us what is the compiling error that you are experiencing?

Best regards,
-- 
Nicolas Ferre

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

* [U-Boot] U-Boot
  2018-02-12 16:39         ` Nicolas Ferre
@ 2018-02-12 17:13           ` Mariano Coromac
  2018-02-13  8:37             ` Nicolas Ferre
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-12 17:13 UTC (permalink / raw)
  To: u-boot

With that one there is none, I had problems with the other one.
Right now I just want to know how the CONIG parameters like this one:
CONFIG_8xx_CONS_SMC1=
Apply to my SAMA5D2. I already have my debug uart working but not the
monitor console. Therefore I can't even print 'help'.
Also, I'm still having trouble with the drivers as you can see above.

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

* [U-Boot] U-Boot
  2018-02-12 17:13           ` Mariano Coromac
@ 2018-02-13  8:37             ` Nicolas Ferre
  2018-02-13 16:00               ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Nicolas Ferre @ 2018-02-13  8:37 UTC (permalink / raw)
  To: u-boot

On 12/02/2018 at 18:13, Mariano Coromac wrote:
> With that one there is none, I had problems with the other one.

I don't understand this sentence.

> Right now I just want to know how the CONIG parameters like this one:
> CONFIG_8xx_CONS_SMC1=

I don't see such parameter in a sama5d2 xplained .config.

For a sama5d2 xplained board, you can refer to these files for
configuration:
include/configs/at91-sama5_common.h
include/configs/sama5d2_xplained.h
configs/sama5d2_xplained_spiflash_defconfig and other defconfigs
and you can follow the initialization phase from:
board/atmel/sama5d2_xplained/sama5d2_xplained.c

Device tree files are also important:
arch/arm/dts/at91-sama5d2_xplained.dts

> Apply to my SAMA5D2. I already have my debug uart working but not the
> monitor console. Therefore I can't even print 'help'.
> Also, I'm still having trouble with the drivers as you can see above.

On the u-boot-2017.03-at91 branch of our vendor tree, you have an
example of moving the console from one USART to the other with this commit:
74f976f8d1fe714b5b28d450e7213657ca8dd71e
(board: atmel: sama5d2_ptc_ek: use uart0 as console output)

Best regards,
-- 
Nicolas Ferre

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

* [U-Boot] U-Boot
  2018-02-13  8:37             ` Nicolas Ferre
@ 2018-02-13 16:00               ` Mariano Coromac
  2018-02-13 17:29                 ` Simon Glass
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-13 16:00 UTC (permalink / raw)
  To: u-boot

Thanks for the info. Apparently now the console is redirected but I keep
getting these driver errors:
bind node serial at f8038200
   - attempt to match compatible string 'atmel,at91sam9260-usart'
   - found match at 'serial_atmel'
Error binding driver 'serial_atmel': -12

For what I understand, the drivers are found but not binded. Any idea why?
All the parameters seemed to be correct. I found the function declared in
System.map and u-boot.map
Does this have to do with uclass.c? I don't know if I am correct but that
one is in charge of handling all the drivers.

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

* [U-Boot] U-Boot
  2018-02-13 16:00               ` Mariano Coromac
@ 2018-02-13 17:29                 ` Simon Glass
  2018-02-13 22:23                   ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Simon Glass @ 2018-02-13 17:29 UTC (permalink / raw)
  To: u-boot

Hi Mariano,

On 13 February 2018 at 09:00, Mariano Coromac <mcoromac@stsa.info> wrote:
> Thanks for the info. Apparently now the console is redirected but I keep
> getting these driver errors:
> bind node serial at f8038200
>    - attempt to match compatible string 'atmel,at91sam9260-usart'
>    - found match at 'serial_atmel'
> Error binding driver 'serial_atmel': -12
>
> For what I understand, the drivers are found but not binded. Any idea why?
> All the parameters seemed to be correct. I found the function declared in
> System.map and u-boot.map
> Does this have to do with uclass.c? I don't know if I am correct but that
> one is in charge of handling all the drivers.

$ grep 12 include/linux/errno.h
#define ENOMEM 12 /* Out of memory */

You could look at CONFIG_SYS_MALLOC_F_LEN and make it a little larger?

Regards,
Simon

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

* [U-Boot] U-Boot
  2018-02-13 17:29                 ` Simon Glass
@ 2018-02-13 22:23                   ` Mariano Coromac
  2018-02-14  3:09                     ` Simon Glass
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-13 22:23 UTC (permalink / raw)
  To: u-boot

Thank you very much. I expanded the malloc into a bigger number and now I
don't get those errors.
My remaining problem is that I can't seem to move the serial console or
console monitor (I don't know which term is better) into my flexcom1 usart.
It always keep saying:

No serial driver found
resetting ...

I followed the example that Nicolas pointed to (modified the stdout-path,
modified the address, modified the pins, added the serial port into my
device tree, modified all the CONFIGS in my defconfig file) but still I
don't know why it doesn't link.

My device tree is alright because now I see that the drivers do get binded.
If I disable the CONFIG_DEBUG_UART=n nothing gets displayed but if I
activate it, it shows me the message above.
Any idea on how to debug this help would be appreciated.

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

* [U-Boot] U-Boot
  2018-02-13 22:23                   ` Mariano Coromac
@ 2018-02-14  3:09                     ` Simon Glass
  2018-02-14 14:54                       ` Mariano Coromac
  2018-03-01 19:55                       ` Mariano Coromac
  0 siblings, 2 replies; 36+ messages in thread
From: Simon Glass @ 2018-02-14  3:09 UTC (permalink / raw)
  To: u-boot

Hi Mariano,

On 13 February 2018 at 15:23, Mariano Coromac <mcoromac@stsa.info> wrote:
>
> Thank you very much. I expanded the malloc into a bigger number and now I don't get those errors.
> My remaining problem is that I can't seem to move the serial console or console monitor (I don't know which term is better) into my flexcom1 usart.
> It always keep saying:
>
> No serial driver found
> resetting ...
>
> I followed the example that Nicolas pointed to (modified the stdout-path, modified the address, modified the pins, added the serial port into my device tree, modified all the CONFIGS in my defconfig file) but still I don't know why it doesn't link.
>
> My device tree is alright because now I see that the drivers do get binded.
> If I disable the CONFIG_DEBUG_UART=n nothing gets displayed but if I activate it, it shows me the message above.
> Any idea on how to debug this help would be appreciated.
>

You can look at serial_find_console_or_panic() and add a call to
dm_dump_all() to print out the device list. Hopefully you can see your
device in the list?

Regards,
Simon

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

* [U-Boot] U-Boot
  2018-02-14  3:09                     ` Simon Glass
@ 2018-02-14 14:54                       ` Mariano Coromac
  2018-02-14 18:34                         ` Mariano Coromac
  2018-03-01 19:55                       ` Mariano Coromac
  1 sibling, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-14 14:54 UTC (permalink / raw)
  To: u-boot

Hmmmm it displays the following:
<debug_uart>  Class       Probed   Name
----------------------------------------
 root        [ + ]    root_driver
 simple_bus  [   ]    `-- ahb
 mmc         [   ]        |-- sdio-host at a0000000
 blk         [   ]        |   `-- sdio-host at a0000000.blk
 mmc         [   ]        |-- sdio-host at b0000000
 blk         [   ]        |   `-- sdio-host at b0000000.blk
 simple_bus  [   ]        `-- apb
 simple_bus  [   ]            |-- pmc at f0014000
 clk         [   ]            |   |-- mainck
 clk         [   ]            |   |-- pllack at 0
 clk         [   ]            |   |-- utmick
 clk         [   ]            |   |-- masterck
 clk         [   ]            |   |-- h32mxck
 misc        [   ]            |   |-- periph32ck
 clk         [   ]            |   |   |-- pioA_clk at 18
 clk         [   ]            |   |   |-- uart0_clk at 24
 clk         [   ]            |   |   |-- uart1_clk at 25
 clk         [   ]            |   |   |-- uart2_clk at 26
 clk         [   ]            |   |   `-- spi0_clk at 33
 misc        [   ]            |   |-- periph64ck
 clk         [   ]            |   |   |-- sdmmc0_hclk at 31
 clk         [   ]            |   |   |-- sdmmc1_hclk at 32
 clk         [   ]            |   |   |-- qspi0_clk at 52
 clk         [   ]            |   |   `-- qspi1_clk at 53
 misc        [   ]            |   `-- gck
 clk         [   ]            |       |-- sdmmc0_gclk at 31
 clk         [   ]            |       `-- sdmmc1_gclk at 32
 spi         [   ]            |-- spi at f8000000
 serial      [   ]            |-- serial at f8038200
 gpio        [   ]            `-- gpio at fc038000
 pinctrl     [   ]                `-- pinctrl
 pinconfig   [   ]                    |-- sdmmc0_cmd_dat_default
 pinconfig   [   ]                    |-- sdmmc0_ck_cd_default
 pinconfig   [   ]                    |-- sdmmc1_cmd_dat_default
 pinconfig   [   ]                    |-- sdmmc1_ck_cd_default
 pinconfig   [   ]                    |-- spi0_default
 pinconfig   [   ]                    `-- serial0_default
bind node serial at f8038200
   - attempt to match compatible string 'atmel,at91sam9260-usart'
   - found match at 'serial_atmel'
No serial driver found
resetting ...

stdout is declared like this: stdout-path = &serial0;

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

* [U-Boot] U-Boot
  2018-02-14 14:54                       ` Mariano Coromac
@ 2018-02-14 18:34                         ` Mariano Coromac
  2018-02-14 21:27                           ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-14 18:34 UTC (permalink / raw)
  To: u-boot

I think I found the root problem for this. I am using a flexcom uart. The
ones that are defined in sama5d2.dtsi are normal uarts, one can use those
definitions alongside the drivers to use uart0 to uart4.
I found a definition to use flexcom, here:
https://github.com/linux4sam/linux-at91/blob/master/Documentation/devicetree/bindings/mfd/atmel-flexcom.txt
The problem I see is that I need a driver also and atmel did not provide
one. Or at least I'm not seeing it because I have search for it around the
entire project.

Could you confirm if my assumptions are correct? Because I see that the
flexcom clocks are defined and makes me wonder if the problem is something
else.

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

* [U-Boot] U-Boot
  2018-02-14 18:34                         ` Mariano Coromac
@ 2018-02-14 21:27                           ` Mariano Coromac
  2018-02-26 17:09                             ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-14 21:27 UTC (permalink / raw)
  To: u-boot

Forget it guys, I just realized what was wrong.
reg = <0xf8038200 0x200>;
Before it was
reg = <0xf8038200 0x100>;
So if anyone else (that wants to use the flexcom uart) asks you about this
now there's another thing you can point to.
If I encounter another problem or something I'll get back to you.

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

* [U-Boot] U-Boot
  2018-02-14 21:27                           ` Mariano Coromac
@ 2018-02-26 17:09                             ` Mariano Coromac
  2018-02-27  1:55                               ` Yang, Wenyou
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-26 17:09 UTC (permalink / raw)
  To: u-boot

Hello Again,
I have been working with UBoot but now when I try to boot my Linux kernel
image that's inside my eMMC it displays the following:
=> boot
CMD_SEND:0
        ARG             0x00000000
        RET             -110
mmc_init: -110, time 10
** Bad device mmc 1 **
CMD_SEND:0
        ARG             0x00000000
        RET             -110
mmc_init: -110, time 11
** Bad device mmc 1 **

I know it is a timeout error and I also know that the error occurs inside
mmc-uclass line 31. I'm aware send_cmd() is defined in mmc.h but I honestly
don't know how to dig deeper into this error.

mmc info works fine. Here's the mmc rescan log if it makes any use:
=> mmc rescan
CMD_SEND:0
        ARG             0x00000000
        MMC_RSP_NONE
CMD_SEND:8
        ARG             0x000001AA
        RET             -110
CMD_SEND:55
        ARG             0x00000000
        RET             -110
CMD_SEND:0
        ARG             0x00000000
        MMC_RSP_NONE
CMD_SEND:1
        ARG             0x00000000
        MMC_RSP_R3,4         0x00FF8080
CMD_SEND:1
        ARG             0x40360080
        MMC_RSP_R3,4         0xC0FF8080
CMD_SEND:2
        ARG             0x00000000
        MMC_RSP_R2         0xEB010D65
                           0x4D4D4320
                           0x205000AC
                           0x008E7300

                    DUMPING DATA
                    000 - EB 01 0D 65
                    004 - 4D 4D 43 20
                    008 - 20 50 00 AC
                    012 - 00 8E 73 00
CMD_SEND:3
        ARG             0x00010000
        MMC_RSP_R1,5,6,7      0x00000500
CMD_SEND:9
        ARG             0x00010000
        MMC_RSP_R2         0xD04F0132
                           0x0F5903FF
                           0xFFFFFFEF
                           0x8A400000

                    DUMPING DATA
                    000 - D0 4F 01 32
                    004 - 0F 59 03 FF
                    008 - FF FF FF EF
                    012 - 8A 40 00 00
CMD_SEND:13
        ARG             0x00010000
        MMC_RSP_R1,5,6,7      0x00000700
CURR STATE:3
CMD_SEND:7
        ARG             0x00010000
        MMC_RSP_R1,5,6,7      0x00000700
CMD_SEND:8
        ARG             0x00000000
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:8
        ARG             0x00000000
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:6
        ARG             0x03B90100
        MMC_RSP_R1b         0x00000800
CMD_SEND:13
        ARG             0x00010000
        MMC_RSP_R1,5,6,7      0x00000900
CURR STATE:4
CMD_SEND:8
        ARG             0x00000000
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:6
        ARG             0x03B70100
        MMC_RSP_R1b         0x00000800
CMD_SEND:13
        ARG             0x00010000
        MMC_RSP_R1,5,6,7      0x00000900
CURR STATE:4
CMD_SEND:8
        ARG             0x00000000
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:16
        ARG             0x00000200
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:17
        ARG             0x00000000
        MMC_RSP_R1,5,6,7      0x00000900

Any guidance would be appreciated.
Thank you.

On Wed, Feb 14, 2018 at 3:27 PM, Mariano Coromac <mcoromac@stsa.info> wrote:

> Forget it guys, I just realized what was wrong.
> reg = <0xf8038200 0x200>;
> Before it was
> reg = <0xf8038200 0x100>;
> So if anyone else (that wants to use the flexcom uart) asks you about this
> now there's another thing you can point to.
> If I encounter another problem or something I'll get back to you.
>



-- 
Mariano Coromac <https://gps.gt/>
I&D of Electronics Engineer
mcoromac at stsa.info
+502 41544712
www.gps.gt <http://facebook.com/startracksa>

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

* [U-Boot] U-Boot
  2018-02-26 17:09                             ` Mariano Coromac
@ 2018-02-27  1:55                               ` Yang, Wenyou
  2018-02-27 16:55                                 ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Yang, Wenyou @ 2018-02-27  1:55 UTC (permalink / raw)
  To: u-boot

Hi Mariano,

On 2018/2/27 1:09, Mariano Coromac wrote:
> Hello Again,
> I have been working with UBoot but now when I try to boot my Linux 
> kernel image that's inside my eMMC it displays the following:
> => boot
> CMD_SEND:0
>         ARG             0x00000000
>         RET             -110
> mmc_init: -110, time 10
> ** Bad device mmc 1 **
> CMD_SEND:0
>         ARG             0x00000000
>         RET             -110
> mmc_init: -110, time 11
> ** Bad device mmc 1 **
>
> I know it is a timeout error and I also know that the error occurs 
> inside mmc-uclass line 31. I'm aware send_cmd() is defined in mmc.h 
> but I honestly don't know how to dig deeper into this error.
>
> mmc info works fine. Here's the mmc rescan log if it makes any use:
> => mmc rescan
> CMD_SEND:0
>         ARG             0x00000000
>         MMC_RSP_NONE
> CMD_SEND:8
>         ARG             0x000001AA
>         RET             -110
> CMD_SEND:55
>         ARG             0x00000000
>         RET             -110
> CMD_SEND:0
>         ARG             0x00000000
>         MMC_RSP_NONE
> CMD_SEND:1
>         ARG             0x00000000
>         MMC_RSP_R3,4         0x00FF8080
> CMD_SEND:1
>         ARG             0x40360080
>         MMC_RSP_R3,4         0xC0FF8080
> CMD_SEND:2
>         ARG             0x00000000
>         MMC_RSP_R2         0xEB010D65
>                            0x4D4D4320
>                            0x205000AC
>                            0x008E7300
>
>                     DUMPING DATA
>                     000 - EB 01 0D 65
>                     004 - 4D 4D 43 20
>                     008 - 20 50 00 AC
>                     012 - 00 8E 73 00
> CMD_SEND:3
>         ARG             0x00010000
>         MMC_RSP_R1,5,6,7      0x00000500
> CMD_SEND:9
>         ARG             0x00010000
>         MMC_RSP_R2         0xD04F0132
>                            0x0F5903FF
>                            0xFFFFFFEF
>                            0x8A400000
>
>                     DUMPING DATA
>                     000 - D0 4F 01 32
>                     004 - 0F 59 03 FF
>                     008 - FF FF FF EF
>                     012 - 8A 40 00 00
> CMD_SEND:13
>         ARG             0x00010000
>         MMC_RSP_R1,5,6,7      0x00000700
> CURR STATE:3
> CMD_SEND:7
>         ARG             0x00010000
>         MMC_RSP_R1,5,6,7      0x00000700
> CMD_SEND:8
>         ARG             0x00000000
>         MMC_RSP_R1,5,6,7      0x00000900
> CMD_SEND:8
>         ARG             0x00000000
>         MMC_RSP_R1,5,6,7      0x00000900
> CMD_SEND:6
>         ARG             0x03B90100
>         MMC_RSP_R1b         0x00000800
> CMD_SEND:13
>         ARG             0x00010000
>         MMC_RSP_R1,5,6,7      0x00000900
> CURR STATE:4
> CMD_SEND:8
>         ARG             0x00000000
>         MMC_RSP_R1,5,6,7      0x00000900
> CMD_SEND:6
>         ARG             0x03B70100
>         MMC_RSP_R1b         0x00000800
> CMD_SEND:13
>         ARG             0x00010000
>         MMC_RSP_R1,5,6,7      0x00000900
> CURR STATE:4
> CMD_SEND:8
>         ARG             0x00000000
>         MMC_RSP_R1,5,6,7      0x00000900
> CMD_SEND:16
>         ARG             0x00000200
>         MMC_RSP_R1,5,6,7      0x00000900
> CMD_SEND:17
>         ARG             0x00000000
>         MMC_RSP_R1,5,6,7      0x00000900
>
> Any guidance would be appreciated.
Please check if there is a pin conflict to configure, or if the mmc 
sequential number is correct.

On sama5d2 Xplained board, the eMMC works with the commands,

=> mmc info
Device: sdio-host at a0000000
Manufacturer ID: fe
OEM: 14e
Name: MMC04
Tran Speed: 52000000
Rd Block Len: 512
MMC version 4.4.1
High Capacity: Yes
Capacity: 3.7 GiB
Bus Width: 4-bit
Erase Group Size: 512 KiB
HC WP Group Size: 4 MiB
User Capacity: 3.7 GiB
Boot Capacity: 1 MiB ENH
RPMB Capacity: 128 KiB ENH


> Thank you.
>
> On Wed, Feb 14, 2018 at 3:27 PM, Mariano Coromac <mcoromac@stsa.info 
> <mailto:mcoromac@stsa.info>> wrote:
>
>     Forget it guys, I just realized what was wrong.
>     reg = <0xf8038200 0x200>;
>     Before it was
>     reg = <0xf8038200 0x100>;
>     So if anyone else (that wants to use the flexcom uart) asks you
>     about this now there's another thing you can point to.
>     If I encounter another problem or something I'll get back to you.
>
>
>
>
> -- 
> Mariano Coromac 	<https://gps.gt/>
> I&D of Electronics Engineer
> mcoromac at stsa.info <mailto:mcoromac@stsa.info>
> +502 41544712
> www.gps.gt <http://www.gps.gt> 	<http://facebook.com/startracksa>
>

Best Regards,
Wenyou Yang

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

* [U-Boot] U-Boot
  2018-02-27  1:55                               ` Yang, Wenyou
@ 2018-02-27 16:55                                 ` Mariano Coromac
  2018-02-28  1:24                                   ` Yang, Wenyou
  0 siblings, 1 reply; 36+ messages in thread
From: Mariano Coromac @ 2018-02-27 16:55 UTC (permalink / raw)
  To: u-boot

Hmmm, by sequential number do you mean the Specification Version? This one
is correct.
Here's my eMMC info.
=> mmc info
Device: sdio-host at a0000000
Manufacturer ID: eb
OEM: 10d
Name: eMMC
Tran Speed: 52000000
Rd Block Len: 512
MMC version 5.0
High Capacity: Yes
Capacity: 3.6 GiB
Bus Width: 4-bit
Erase Group Size: 512 KiB
HC WP Group Size: 8 MiB
User Capacity: 3.6 GiB
Boot Capacity: 2 MiB ENH
RPMB Capacity: 512 KiB ENH

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

* [U-Boot] U-Boot
  2018-02-27 16:55                                 ` Mariano Coromac
@ 2018-02-28  1:24                                   ` Yang, Wenyou
  2018-02-28 22:15                                     ` Mariano Coromac
  0 siblings, 1 reply; 36+ messages in thread
From: Yang, Wenyou @ 2018-02-28  1:24 UTC (permalink / raw)
  To: u-boot


On 2018/2/28 0:55, Mariano Coromac wrote:
> Hmmm, by sequential number do you mean the Specification Version? This 
> one is correct.
> Here's my eMMC info.
> => mmc info
> Device: sdio-host at a0000000
> Manufacturer ID: eb
> OEM: 10d
> Name: eMMC
> Tran Speed: 52000000
> Rd Block Len: 512
> MMC version 5.0
> High Capacity: Yes
> Capacity: 3.6 GiB
> Bus Width: 4-bit
> Erase Group Size: 512 KiB
> HC WP Group Size: 8 MiB
> User Capacity: 3.6 GiB
> Boot Capacity: 2 MiB ENH
> RPMB Capacity: 512 KiB ENH
This is right, did you try the command,
=> mmc read addr blk# cnt
does it work?

Best Regards,
Wenyou Yang

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

* [U-Boot] U-Boot
  2018-02-28  1:24                                   ` Yang, Wenyou
@ 2018-02-28 22:15                                     ` Mariano Coromac
  0 siblings, 0 replies; 36+ messages in thread
From: Mariano Coromac @ 2018-02-28 22:15 UTC (permalink / raw)
  To: u-boot

Yes, for example I did:
=> mmc read 0x00000000 512 1

MMC read: dev # 0, block # 1298, count 1 ... CMD_SEND:16
        ARG                             0x00000200
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:17
        ARG                             0x00000512
        MMC_RSP_R1,5,6,7      0x00000900
1 blocks read: OK

Then I tried to write into it like this:
=> mmc write 0x00000000 512 1

MMC write: dev # 0, block # 1298, count 1 ... CMD_SEND:16
        ARG                             0x00000200
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:24
        ARG                             0x00000512
        MMC_RSP_R1,5,6,7      0x00000900
CMD_SEND:13
        ARG             0x00010000
sdhci_send_command: MMC: 0 busy timeout increasing to: 200 ms.
        MMC_RSP_R1,5,6,7      0x00000900
CURR STATE:4
1 blocks written: OK

What do you think?
I'm reading JEDEC Specification Version 5.0 document maybe it could bring
some insight on what is happening. The driver is supposed to match with any
eMMC but still.

On Tue, Feb 27, 2018 at 7:24 PM, Yang, Wenyou <Wenyou.Yang@microchip.com>
wrote:

>
> On 2018/2/28 0:55, Mariano Coromac wrote:
>
>> Hmmm, by sequential number do you mean the Specification Version? This
>> one is correct.
>> Here's my eMMC info.
>> => mmc info
>> Device: sdio-host at a0000000
>> Manufacturer ID: eb
>> OEM: 10d
>> Name: eMMC
>> Tran Speed: 52000000
>> Rd Block Len: 512
>> MMC version 5.0
>> High Capacity: Yes
>> Capacity: 3.6 GiB
>> Bus Width: 4-bit
>> Erase Group Size: 512 KiB
>> HC WP Group Size: 8 MiB
>> User Capacity: 3.6 GiB
>> Boot Capacity: 2 MiB ENH
>> RPMB Capacity: 512 KiB ENH
>>
> This is right, did you try the command,
> => mmc read addr blk# cnt
> does it work?
>
> Best Regards,
> Wenyou Yang
>



-- 
Mariano Coromac <https://gps.gt/>
I&D of Electronics Engineer
mcoromac at stsa.info
+502 41544712
www.gps.gt <http://facebook.com/startracksa>

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

* [U-Boot] U-Boot
  2018-02-14  3:09                     ` Simon Glass
  2018-02-14 14:54                       ` Mariano Coromac
@ 2018-03-01 19:55                       ` Mariano Coromac
  2018-03-02 15:53                         ` Lothar Waßmann
  2018-03-02 17:58                         ` Nicolas Ferre
  1 sibling, 2 replies; 36+ messages in thread
From: Mariano Coromac @ 2018-03-01 19:55 UTC (permalink / raw)
  To: u-boot

I found the problem. In my header file I was reading from eMMC device 1.
Not 0. That's why the operations with mmc worked in command line but did
not on startup.
Please correct me if I'm mistaken but I have a couple questions.
1) Do I need a partition in my eMMC in order to boot the Linux kernel?
When I run "mmc part" it shows no partition at all.
2) When U-Boot finishes compiling it generates a .dtb with the name of my
custom board. I need to write this file (alongside zImage) inside my eMMC
for my Linux Kernel to boot right?
When I try to boot the kernel it hangs in here:
=> boot
reading p_a5_tab_reva.dtb
13699 bytes read in 18 ms (743.2 KiB/s)
reading zImage
3749624 bytes read in 298 ms (12 MiB/s)
## Flattened Device Tree blob at 21000000
   Booting using the fdt blob at 0x21000000
   Loading Device Tree to 27b7d000, end 27b83582 ... OK

Starting kernel ...

What do you think of this? Perhaps is regarding the kernel itself or maybe
is a UBoot configuration?

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

* [U-Boot] U-Boot
  2018-03-01 19:55                       ` Mariano Coromac
@ 2018-03-02 15:53                         ` Lothar Waßmann
  2018-03-02 17:58                         ` Nicolas Ferre
  1 sibling, 0 replies; 36+ messages in thread
From: Lothar Waßmann @ 2018-03-02 15:53 UTC (permalink / raw)
  To: u-boot

Hi,

On Thu, 1 Mar 2018 13:55:19 -0600 Mariano Coromac wrote:
> I found the problem. In my header file I was reading from eMMC device 1.
> Not 0. That's why the operations with mmc worked in command line but did
> not on startup.
> Please correct me if I'm mistaken but I have a couple questions.
> 1) Do I need a partition in my eMMC in order to boot the Linux kernel?
> When I run "mmc part" it shows no partition at all.
> 2) When U-Boot finishes compiling it generates a .dtb with the name of my
> custom board. I need to write this file (alongside zImage) inside my eMMC
> for my Linux Kernel to boot right?
> When I try to boot the kernel it hangs in here:
> => boot
> reading p_a5_tab_reva.dtb
> 13699 bytes read in 18 ms (743.2 KiB/s)
> reading zImage
> 3749624 bytes read in 298 ms (12 MiB/s)
> ## Flattened Device Tree blob at 21000000
>    Booting using the fdt blob at 0x21000000
>    Loading Device Tree to 27b7d000, end 27b83582 ... OK
> 
> Starting kernel ...
> 
> What do you think of this? Perhaps is regarding the kernel itself or maybe
> is a UBoot configuration?
>
My guess is that the fdt is out of reach for the kernel.
Try setting the fdt_high variable to limit the range where U-Boot will
copy the fdt.
fdt_high=ffffffff will prevent copying the fdt at all, other values
specify the upper limit for the memory address where the fdt will end
after copying.


Lothar Waßmann

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

* [U-Boot] U-Boot
  2018-03-01 19:55                       ` Mariano Coromac
  2018-03-02 15:53                         ` Lothar Waßmann
@ 2018-03-02 17:58                         ` Nicolas Ferre
  2018-03-05 22:15                           ` Mariano Coromac
  1 sibling, 1 reply; 36+ messages in thread
From: Nicolas Ferre @ 2018-03-02 17:58 UTC (permalink / raw)
  To: u-boot

On 01/03/2018 at 20:55, Mariano Coromac wrote:
> I found the problem. In my header file I was reading from eMMC device 1. 
> Not 0. That's why the operations with mmc worked in command line but did 
> not on startup.
> Please correct me if I'm mistaken but I have a couple questions.
> 1) Do I need a partition in my eMMC in order to boot the Linux kernel?
> When I run "mmc part" it shows no partition at all.
> 2) When U-Boot finishes compiling it generates a .dtb with the name of 
> my custom board. I need to write this file (alongside zImage) inside my 
> eMMC for my Linux Kernel to boot right?

Actually no: the .dtb from U-Boot is for U-Boot to use. For loading the 
Linux kernel, you must use the .dtb that is produced by the compilation 
of the kernel (in arch/arm/boot/dts/)


> When I try to boot the kernel it hangs in here:
> => boot
> reading p_a5_tab_reva.dtb
> 13699 bytes read in 18 ms (743.2 KiB/s)
> reading zImage
> 3749624 bytes read in 298 ms (12 MiB/s)
> ## Flattened Device Tree blob at 21000000
>     Booting using the fdt blob at 0x21000000
>     Loading Device Tree to 27b7d000, end 27b83582 ... OK
> 
> Starting kernel ...
> 
> What do you think of this? Perhaps is regarding the kernel itself or 
> maybe is a UBoot configuration?


-- 
Nicolas Ferre

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

* [U-Boot] U-Boot
  2018-03-02 17:58                         ` Nicolas Ferre
@ 2018-03-05 22:15                           ` Mariano Coromac
  0 siblings, 0 replies; 36+ messages in thread
From: Mariano Coromac @ 2018-03-05 22:15 UTC (permalink / raw)
  To: u-boot

I changed fdt_high but got the same result.
I wrote my device tree, added it into the makefile and copy the
sama5d2.config with my board name. I also got rid of all the unnecessary
stuff.
I'm now using the correct .dtb file (in arch/arm/boot/dts/)
My device tree stdout-path does point into my flexcom1 serial port.
Do you see something wrong?
            flx1: flexcom at f8038000 {
                atmel,flexcom-mode = <ATMEL_FLEXCOM_MODE_TWI>;
                status = "okay";

                uart5: serial at 200 {
                    compatible = "atmel,at91sam9260-usart";
                    reg = <0x200 0x200>;
                    interrupts = <19 IRQ_TYPE_LEVEL_HIGH 7>;
                    #address-cells = <1>;
                    #size-cells = <0>;
                    clocks = <&flx0_clk>;
                    pinctrl-names = "default";
                    pinctrl-0 = <&pinctrl_flx0_default>;
                    atmel,fifo-size = <16>;
                    status = "okay";
                };
            };
Here's a new log if it is of any use:
AT91Bootstrap 3.8.9-00026-gd7a52fb-dirty (mié feb 21 10:03:49 CST 2018)

SD/MMC: Image: Read file u-boot.bin to 0x26f00000
MMC: Specification Version 1.2
SD/MMC: Done to load image
<debug_uart> MMC:   sdio-host at a0000000: 0

** Unable to use mmc 0:1 for loading the env **
Using default environment

In:    serial at f8038200
Out:   serial at f8038200
Err:   serial at f8038200
stdin
stdout
stderr
Hit any key to stop autoboot:  0
reading p_a5_tab_reva.dtb
26135 bytes read in 18 ms (1.4 MiB/s)
reading zImage
2452336 bytes read in 198 ms (11.8 MiB/s)
## Current stack ends at 0x27b84588 *  kernel: cmdline image address =
0x22000000
## Flattened Device Tree blob at 21000000
   Booting using the fdt blob at 0x21000000
using: FDT
   Loading Device Tree to 27b79000, end 27b82616 ... OK
## Transferring control to Linux (at address 22000000)...

Starting kernel ...

As my understanding goes those are the only things I need, my device tree
and the linux image. I think my main problem is that I don't have the
console in my serial port, that's why it appears like it hangs but I'm not
so sure about that.
I also defined the following inside my config file:
CONFIG_DEBUG_UART_PHYS=0xf8038200
CONFIG_DEBUG_UART_VIRT=0xf7038200

Any help would be appreciated.


On Fri, Mar 2, 2018 at 11:58 AM, Nicolas Ferre <nicolas.ferre@microchip.com>
wrote:

> On 01/03/2018 at 20:55, Mariano Coromac wrote:
>
>> I found the problem. In my header file I was reading from eMMC device 1.
>> Not 0. That's why the operations with mmc worked in command line but did
>> not on startup.
>> Please correct me if I'm mistaken but I have a couple questions.
>> 1) Do I need a partition in my eMMC in order to boot the Linux kernel?
>> When I run "mmc part" it shows no partition at all.
>> 2) When U-Boot finishes compiling it generates a .dtb with the name of my
>> custom board. I need to write this file (alongside zImage) inside my eMMC
>> for my Linux Kernel to boot right?
>>
>
> Actually no: the .dtb from U-Boot is for U-Boot to use. For loading the
> Linux kernel, you must use the .dtb that is produced by the compilation of
> the kernel (in arch/arm/boot/dts/)
>
>
>
> When I try to boot the kernel it hangs in here:
>> => boot
>> reading p_a5_tab_reva.dtb
>> 13699 bytes read in 18 ms (743.2 KiB/s)
>> reading zImage
>> 3749624 bytes read in 298 ms (12 MiB/s)
>> ## Flattened Device Tree blob at 21000000
>>     Booting using the fdt blob at 0x21000000
>>     Loading Device Tree to 27b7d000, end 27b83582 ... OK
>>
>> Starting kernel ...
>>
>> What do you think of this? Perhaps is regarding the kernel itself or
>> maybe is a UBoot configuration?
>>
>
>
> --
> Nicolas Ferre
>



-- 
Mariano Coromac <https://gps.gt/>
I&D of Electronics Engineer
mcoromac at stsa.info
+502 41544712
www.gps.gt <http://facebook.com/startracksa>

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

* [U-Boot] u-boot
  2017-01-12 16:45 [U-Boot] u-boot adam.davis at stfc.ac.uk
@ 2017-01-13  8:56 ` Michal Simek
  0 siblings, 0 replies; 36+ messages in thread
From: Michal Simek @ 2017-01-13  8:56 UTC (permalink / raw)
  To: u-boot

Hi,

please subscribe here.
http://lists.denx.de/mailman/listinfo/u-boot

Thanks,
Michal

On 12.1.2017 17:45, adam.davis at stfc.ac.uk wrote:
> Hi,
> 
> Just starting out looking at u-boot for a project using Xilinx Zynq zc7020 chip on an Enclustra module
> 
> Please add me to the mailing list
> 
> Many thanks
> 
> Regards
> 
> Adam Davis MEng
> R65, G.15
> Application Engineering Group
> Science & Technology Facilities Council,
> Rutherford Appleton Laboratory,
> Chilton,
> Didcot,
> Oxon,
> OX11 0QX
> TE : 01235 821900
> EX : 6700
> EM : adam.davis at stfc.ac.uk<mailto:adam.davis@stfc.ac.uk>
> 
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
> 


-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Xilinx Microblaze
Maintainer of Linux kernel - Xilinx Zynq ARM and ZynqMP ARM64 SoCs
U-Boot custodian - Xilinx Microblaze/Zynq/ZynqMP SoCs


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170113/b50f70a3/attachment.sig>

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

* [U-Boot] u-boot
@ 2017-01-12 16:45 adam.davis at stfc.ac.uk
  2017-01-13  8:56 ` Michal Simek
  0 siblings, 1 reply; 36+ messages in thread
From: adam.davis at stfc.ac.uk @ 2017-01-12 16:45 UTC (permalink / raw)
  To: u-boot

Hi,

Just starting out looking at u-boot for a project using Xilinx Zynq zc7020 chip on an Enclustra module

Please add me to the mailing list

Many thanks

Regards

Adam Davis MEng
R65, G.15
Application Engineering Group
Science & Technology Facilities Council,
Rutherford Appleton Laboratory,
Chilton,
Didcot,
Oxon,
OX11 0QX
TE : 01235 821900
EX : 6700
EM : adam.davis at stfc.ac.uk<mailto:adam.davis@stfc.ac.uk>

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

* [U-Boot] u-boot
  2016-06-24  3:04 ` Venky Venkatesh
@ 2016-06-24  6:33   ` Wolfgang Denk
  0 siblings, 0 replies; 36+ messages in thread
From: Wolfgang Denk @ 2016-06-24  6:33 UTC (permalink / raw)
  To: u-boot

Dear Venkatesh,

In message <CAONbAMs0goUd+46fmcgu6KA+=Tqs0LTTv0iPKRM1vOC43JOKng@mail.gmail.com> you wrote:
> 
> Is there any possibility to modify the code and load the kernel at the end
> of the first stage boot so that i can skipp of the 2nd stage boot loader.

Well - in U-Boot terminology, the 1st stage loader is the ROM boot
loader (RBL).  I am not aware of systems where the RBL can directly
load and start a Linux kernel in a somewhat sane way.  So you will
always need at least the U-Boot SPL.  But you can avoid loading and
running the full-blown U-Boot itself - this is what Falcon Mode does.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Imagination was given to man to compensate him for what he is not;  a
sence of humor to console him for what he is.          - Fancis Bacon

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

* [U-Boot] u-boot
  2016-06-23 14:15 Venky Venkatesh
  2016-06-23 18:23 ` Wolfgang Denk
@ 2016-06-24  3:04 ` Venky Venkatesh
  2016-06-24  6:33   ` Wolfgang Denk
  1 sibling, 1 reply; 36+ messages in thread
From: Venky Venkatesh @ 2016-06-24  3:04 UTC (permalink / raw)
  To: u-boot

Thanks wolfgang,

Is there any possibility to modify the code and load the kernel at the end
of the first stage boot so that i can skipp of the 2nd stage boot loader.

Thanks & Regards,
Venkatesh
On Jun 23, 2016 7:45 PM, "Venky Venkatesh" <venkateshv377@gmail.com> wrote:

> Hi,
>      How can i load the kernel by using first stage boot loader (MLO)
> directly, without giving the control to the second stage boot loader
> (i.e u-boot.bin). Here at the end of the first stage boot loader i
> want to load the kernel, so that i can boot the kernel by using
> x-loader directly. Give me suggestions
>
> Thanks,
> Venkatesh
>

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

* [U-Boot] u-boot
  2016-06-23 14:15 Venky Venkatesh
@ 2016-06-23 18:23 ` Wolfgang Denk
  2016-06-24  3:04 ` Venky Venkatesh
  1 sibling, 0 replies; 36+ messages in thread
From: Wolfgang Denk @ 2016-06-23 18:23 UTC (permalink / raw)
  To: u-boot

Dear Venky,

In message <CAONbAMvq7fLPU1qkLrQp0HJiwesWtmXHqx9dLTy_R-GdmsZ=Tg@mail.gmail.com> you wrote:
>
>      How can i load the kernel by using first stage boot loader (MLO)

In U-Boot terminology, this is the SPL.

> directly, without giving the control to the second stage boot loader
> (i.e u-boot.bin). Here at the end of the first stage boot loader i
> want to load the kernel, so that i can boot the kernel by using
> x-loader directly. Give me suggestions

This boot method is called "Falcon Mode".   You want to read
doc/README.falcon

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Bus error -- driver executed.

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

* [U-Boot] u-boot
@ 2016-06-23 14:15 Venky Venkatesh
  2016-06-23 18:23 ` Wolfgang Denk
  2016-06-24  3:04 ` Venky Venkatesh
  0 siblings, 2 replies; 36+ messages in thread
From: Venky Venkatesh @ 2016-06-23 14:15 UTC (permalink / raw)
  To: u-boot

Hi,
     How can i load the kernel by using first stage boot loader (MLO)
directly, without giving the control to the second stage boot loader
(i.e u-boot.bin). Here at the end of the first stage boot loader i
want to load the kernel, so that i can boot the kernel by using
x-loader directly. Give me suggestions

Thanks,
Venkatesh

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

* [U-Boot] U-Boot
@ 2015-04-17 14:16 wehner.junior at googlemail.com
  0 siblings, 0 replies; 36+ messages in thread
From: wehner.junior at googlemail.com @ 2015-04-17 14:16 UTC (permalink / raw)
  To: u-boot

Hello,

I want to add a fixed phy connection to describe the rgmii interface between a cpu and an ethernet switch.

What is the recommended way over the phylib?

Kind regards,

Mark

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

* [U-Boot] U-BOOT
  2011-08-05 11:48 [U-Boot] U-BOOT Rajeev Rao Battu
@ 2011-08-05 13:03 ` Albert ARIBAUD
  0 siblings, 0 replies; 36+ messages in thread
From: Albert ARIBAUD @ 2011-08-05 13:03 UTC (permalink / raw)
  To: u-boot

Hi Rajeev,

On 05/08/2011 13:48, Rajeev Rao Battu wrote:
> Greetings,
>
>             I am working as an R&D Engineer. presently i am using u-boot ver
> 2008.10 and wanted to shift to latest version.
> I had downloaded 2011.06 from DENX website. when i tried to compile it its
> bit different and i am facing problems.
> where can i get document of change log  or any  other document which can
> help in my compilation.

Why don't you use git and download the full git repository of U-Boot, 
with complete history?

> IS there any problem,
> if i use new u-boot version with older kernel like 2.6.28 or 2.6.32
> versions.

This is too much of a general question, especially since you don't 
mention which board you're working with, and what problem exactly you 
have when trying these linux kernels.

> please help me in this regard.
>                                           Thanks in advance.

Amicalement,
-- 
Albert.

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

* [U-Boot] U-BOOT
@ 2011-08-05 11:48 Rajeev Rao Battu
  2011-08-05 13:03 ` Albert ARIBAUD
  0 siblings, 1 reply; 36+ messages in thread
From: Rajeev Rao Battu @ 2011-08-05 11:48 UTC (permalink / raw)
  To: u-boot

Greetings,

           I am working as an R&D Engineer. presently i am using u-boot ver
2008.10 and wanted to shift to latest version.
I had downloaded 2011.06 from DENX website. when i tried to compile it its
bit different and i am facing problems.
where can i get document of change log  or any  other document which can
help in my compilation. IS there any problem,
if i use new u-boot version with older kernel like 2.6.28 or 2.6.32
versions. please help me in this regard.
                                         Thanks in advance.


-- 
Regards,
RAJEEV RAO BATTU
R&D Engineer,
ANALOGICS TECH INDIA LTD.
Phone:9985144835.
Tel: ++91-40-67355000, 2717 2672/2673/2674.
http://www.analogicgroup.com

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

* [U-Boot] U-Boot
  2011-06-20 11:08 [U-Boot] U-Boot Yash Jain
@ 2011-06-20 11:27 ` Wolfgang Denk
  0 siblings, 0 replies; 36+ messages in thread
From: Wolfgang Denk @ 2011-06-20 11:27 UTC (permalink / raw)
  To: u-boot

Dear Yash Jain,

In message <BANLkTikSK11q6=t5eQxTLRjViRJxv42QRA@mail.gmail.com> you wrote:
>
> I am very new to u boot and want to know more in detail about u boot
> including the software flow, drivers and adding a new board
> configuration to u boot.
> Please let me know how to start with this task and also provide me few
> documents if available.

Start reading at the home page: http://www.denx.de/wiki/U-Boot

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
The Gates in my computer are AND, OR and NOT; they are not Bill.

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

* [U-Boot] U-Boot
@ 2011-06-20 11:08 Yash Jain
  2011-06-20 11:27 ` Wolfgang Denk
  0 siblings, 1 reply; 36+ messages in thread
From: Yash Jain @ 2011-06-20 11:08 UTC (permalink / raw)
  To: u-boot

Hello Guys,
I am very new to u boot and want to know more in detail about u boot
including the software flow, drivers and adding a new board
configuration to u boot.
Please let me know how to start with this task and also provide me few
documents if available.

Thanks and Regards,
Yash.

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

* [U-Boot] u-boot
  2010-08-29  2:12 [U-Boot] u-boot Ò»ºÅ º«
@ 2010-08-30  9:13 ` Detlev Zundel
  0 siblings, 0 replies; 36+ messages in thread
From: Detlev Zundel @ 2010-08-30  9:13 UTC (permalink / raw)
  To: u-boot

Hi,

> hi, i would like to subscribe the news about u-boot ,thank you.

Use the web-interface referenced in all mails:

>       _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot

Cheers
  Detlev

-- 
He thinks he's really smooth, but he's only C^1.
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de

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

* [U-Boot] u-boot
@ 2010-08-29  2:12 Ò»ºÅ º«
  2010-08-30  9:13 ` Detlev Zundel
  0 siblings, 1 reply; 36+ messages in thread
From: Ò»ºÅ º« @ 2010-08-29  2:12 UTC (permalink / raw)
  To: u-boot

hi, i would like to subscribe the news about u-boot ,thank you.


      

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

end of thread, other threads:[~2018-03-05 22:15 UTC | newest]

Thread overview: 36+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAP+B+qCMvQQBAGPaZ73UkKV2GpwoYx-OKVjjmLjB420fgwCEKA@mail.gmail.com>
2018-02-12 14:59 ` [U-Boot] U-Boot Marek Vasut
2018-02-12 15:13   ` Mariano Coromac
2018-02-12 15:28     ` Marek Vasut
2018-02-12 16:28       ` Mariano Coromac
2018-02-12 16:39         ` Nicolas Ferre
2018-02-12 17:13           ` Mariano Coromac
2018-02-13  8:37             ` Nicolas Ferre
2018-02-13 16:00               ` Mariano Coromac
2018-02-13 17:29                 ` Simon Glass
2018-02-13 22:23                   ` Mariano Coromac
2018-02-14  3:09                     ` Simon Glass
2018-02-14 14:54                       ` Mariano Coromac
2018-02-14 18:34                         ` Mariano Coromac
2018-02-14 21:27                           ` Mariano Coromac
2018-02-26 17:09                             ` Mariano Coromac
2018-02-27  1:55                               ` Yang, Wenyou
2018-02-27 16:55                                 ` Mariano Coromac
2018-02-28  1:24                                   ` Yang, Wenyou
2018-02-28 22:15                                     ` Mariano Coromac
2018-03-01 19:55                       ` Mariano Coromac
2018-03-02 15:53                         ` Lothar Waßmann
2018-03-02 17:58                         ` Nicolas Ferre
2018-03-05 22:15                           ` Mariano Coromac
2017-01-12 16:45 [U-Boot] u-boot adam.davis at stfc.ac.uk
2017-01-13  8:56 ` Michal Simek
  -- strict thread matches above, loose matches on Subject: below --
2016-06-23 14:15 Venky Venkatesh
2016-06-23 18:23 ` Wolfgang Denk
2016-06-24  3:04 ` Venky Venkatesh
2016-06-24  6:33   ` Wolfgang Denk
2015-04-17 14:16 [U-Boot] U-Boot wehner.junior at googlemail.com
2011-08-05 11:48 [U-Boot] U-BOOT Rajeev Rao Battu
2011-08-05 13:03 ` Albert ARIBAUD
2011-06-20 11:08 [U-Boot] U-Boot Yash Jain
2011-06-20 11:27 ` Wolfgang Denk
2010-08-29  2:12 [U-Boot] u-boot Ò»ºÅ º«
2010-08-30  9:13 ` Detlev Zundel

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.