Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-29 Thread Fausto Sessego
2017-05-27 14:50 GMT+02:00 Fabio Estevam :

> On Sat, May 27, 2017 at 8:00 AM, Fausto Sessego
>  wrote:
>
> > Starting kernel ...
> >
> > Uncompressing Linux... done, booting the kernel.
> >
> > Error: unrecognized/unsupported machine ID (r1 = 0x15b3).
> >
> > Available machine support:
> >
> > ID (hex)NAME
> > Generic DT based system
> > Freescale i.MX6 Quad/DualLite (Device Tree)
> > Freescale i.MX6 SoloLite (Device Tree)
> > Freescale i.MX6 SoloX (Device Tree)
> > Freescale i.MX6 Ultralite (Device Tree)
> > Freescale i.MX7 Dual (Device Tree)
> > Freescale i.MX50 (Device Tree Support)
> > Freescale i.MX53 (Device Tree Support)
> > Freescale Vybrid VF5xx/VF6xx (Device Tree)
> >
> > Please check your kernel config and/or bootloader.
> >
> > There is the error "Error: unrecognized/unsupported machine ID"
> >
> > I read many post but i didn't found any solution.
>
> You are probably missing:
> CONFIG_OF_LIBFDT=y
>
> in your defconfig file.
>
> Just looked at your defconfig and it has:
> #CONFIG_OF_LIBFDT=y
>
> So you need to remove the "#" in front of it.
>
> This will tell U-Boot that it will boot a kernel + dtb.
>

Now it's working and i'm able to load the kernel.

Thank you
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-27 Thread Fabio Estevam
On Sat, May 27, 2017 at 8:00 AM, Fausto Sessego
 wrote:

> Starting kernel ...
>
> Uncompressing Linux... done, booting the kernel.
>
> Error: unrecognized/unsupported machine ID (r1 = 0x15b3).
>
> Available machine support:
>
> ID (hex)NAME
> Generic DT based system
> Freescale i.MX6 Quad/DualLite (Device Tree)
> Freescale i.MX6 SoloLite (Device Tree)
> Freescale i.MX6 SoloX (Device Tree)
> Freescale i.MX6 Ultralite (Device Tree)
> Freescale i.MX7 Dual (Device Tree)
> Freescale i.MX50 (Device Tree Support)
> Freescale i.MX53 (Device Tree Support)
> Freescale Vybrid VF5xx/VF6xx (Device Tree)
>
> Please check your kernel config and/or bootloader.
>
> There is the error "Error: unrecognized/unsupported machine ID"
>
> I read many post but i didn't found any solution.

You are probably missing:
CONFIG_OF_LIBFDT=y

in your defconfig file.

Just looked at your defconfig and it has:
#CONFIG_OF_LIBFDT=y

So you need to remove the "#" in front of it.

This will tell U-Boot that it will boot a kernel + dtb.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-27 Thread Fausto Sessego
2017-05-26 14:04 GMT+02:00 Lothar Waßmann :

> Fausto Sessego  wrote:
>
> > Hi,
> >
> > here you are my configuration:
> >
> > #define CONFIG_EXTRA_ENV_SETTINGS \
> > "image=zImage\0" \
> > "console=" CONFIG_CONSOLE_DEV "\0" \
> > "fdt_file=imx6q-tibidabo.dtb\0" \
> > "fdt_addr=0x1400\0" \
> > "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
> > "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
> > "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
> > "mmcautodetect=yes\0" \
> > "mmcargs=setenv bootargs console=${console},${baudrate} earlyprintk " \
> > "root=${mmcroot}\0" \
> > "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
> > "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
> >
> >
> > #define CONFIG_BOOTCOMMAND \
> > "run mmcargs; " \
> > "run loadfdt; " \
> > "run loadimage; " \
> > "bootz ${loadaddr} - ${fdt_addr}; "\
> >
> > it is easy.
> >
> > I tried to put earlyprintk but i didn't see any output.
> >
> >
> Please do not top-post! (put your own comments _after_ the quoted
> portion of the original mail you are responding to just like everyone
> else on this mailing list).
>
> Your SDRAM size is 2GiB. That means U-Boot will relocate the FDT
> outside reach for the kernel. Try setting 'fdt_high=0x' (or
> ${fdt_addr}), to prevent U-Boot from relocating the FDT.
>
>
> Lothar Waßmann
> --
> ___
>
> Ka-Ro electronics GmbH | Pascalstraße 22 | D - 52076 Aachen
> Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
> Geschäftsführer: Matthias Kaussen
> Handelsregistereintrag: Amtsgericht Aachen, HRB 4996
>
> www.karo-electronics.de | i...@karo-electronics.de
> ___
>

I finally found the error enabling "earlyprintk"

U-Boot 2016.07 (May 27 2017 - 01:17:11 +0200)

CPU:   Freescale i.MX6Q rev1.2 at 792MHz
CPU:   Industrial temperature grade (-40C to 105C) at 30C
Reset cause: POR
Board: i.MX6Q TIBIDABO
I2C:   ready
DRAM:  gd->ram_size: 2147483648
DRAM test not implemented!
2 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1
*** Warning - bad CRC, using default environment

In:serial
Out:   serial
Err:   serial
Net:   FEC [PRIME]
Error: FEC address not set.

Hit any key to stop autoboot:  0
reading imx6q-tibidabo.dtb
29636 bytes read in 22 ms (1.3 MiB/s)
reading uImage
6622920 bytes read in 324 ms (19.5 MiB/s)
## Booting kernel from Legacy Image at 1200 ...
   Image Name:   Linux-4.1.38
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:6622856 Bytes = 6.3 MiB
   Load Address: 10008000
   Entry Point:  10008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

Error: unrecognized/unsupported machine ID (r1 = 0x15b3).

Available machine support:

ID (hex)NAME
Generic DT based system
Freescale i.MX6 Quad/DualLite (Device Tree)
Freescale i.MX6 SoloLite (Device Tree)
Freescale i.MX6 SoloX (Device Tree)
Freescale i.MX6 Ultralite (Device Tree)
Freescale i.MX7 Dual (Device Tree)
Freescale i.MX50 (Device Tree Support)
Freescale i.MX53 (Device Tree Support)
Freescale Vybrid VF5xx/VF6xx (Device Tree)

Please check your kernel config and/or bootloader.

There is the error "Error: unrecognized/unsupported machine ID"

I read many post but i didn't found any solution.

PS: is it ok if i answer this way?

thank
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-26 Thread Fausto Sessego
Hi Fabio,

i tried both solutions without any output.



--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*

info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*
*address:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*phone:* +39 070 92432952
*email:* fausto.sess...@infomob.it
*skype:* fausto.sessego.infomob
*web:* www.infomob.it

2017-05-26 14:36 GMT+02:00 Fabio Estevam :

> Hi Fausto,
>
> On Fri, May 26, 2017 at 7:39 AM, Fausto Sessego  > wrote:
>
>>
>>
>> #define CONFIG_BOOTCOMMAND \
>> "run mmcargs; " \
>> "run loadfdt; " \
>> "run loadimage; " \
>> "bootz ${loadaddr} - ${fdt_addr}; "\
>>
>
> The bootz command expects a zImage type of kernel.
>
> In your previous message you were passing uImage, so what you should do is:
>
> 1.Pass a zImage and use it with bootz
>
> or
>
> 2. Pass a uImage and use it with bootm.
>
> Hope this helps.
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-26 Thread Fabio Estevam
Hi Fausto,

On Fri, May 26, 2017 at 7:39 AM, Fausto Sessego 
wrote:

>
>
> #define CONFIG_BOOTCOMMAND \
> "run mmcargs; " \
> "run loadfdt; " \
> "run loadimage; " \
> "bootz ${loadaddr} - ${fdt_addr}; "\
>

The bootz command expects a zImage type of kernel.

In your previous message you were passing uImage, so what you should do is:

1.Pass a zImage and use it with bootz

or

2. Pass a uImage and use it with bootm.

Hope this helps.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-26 Thread Lothar Waßmann
Fausto Sessego  wrote:

> Hi,
> 
> here you are my configuration:
> 
> #define CONFIG_EXTRA_ENV_SETTINGS \
> "image=zImage\0" \
> "console=" CONFIG_CONSOLE_DEV "\0" \
> "fdt_file=imx6q-tibidabo.dtb\0" \
> "fdt_addr=0x1400\0" \
> "mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
> "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
> "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
> "mmcautodetect=yes\0" \
> "mmcargs=setenv bootargs console=${console},${baudrate} earlyprintk " \
> "root=${mmcroot}\0" \
> "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
> "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
> 
> 
> #define CONFIG_BOOTCOMMAND \
> "run mmcargs; " \
> "run loadfdt; " \
> "run loadimage; " \
> "bootz ${loadaddr} - ${fdt_addr}; "\
> 
> it is easy.
> 
> I tried to put earlyprintk but i didn't see any output.
> 
> 
Please do not top-post! (put your own comments _after_ the quoted
portion of the original mail you are responding to just like everyone
else on this mailing list).

Your SDRAM size is 2GiB. That means U-Boot will relocate the FDT
outside reach for the kernel. Try setting 'fdt_high=0x' (or
${fdt_addr}), to prevent U-Boot from relocating the FDT.


Lothar Waßmann
-- 
___

Ka-Ro electronics GmbH | Pascalstraße 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Geschäftsführer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | i...@karo-electronics.de
___
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-26 Thread Fausto Sessego
Hi,

here you are my configuration:

#define CONFIG_EXTRA_ENV_SETTINGS \
"image=zImage\0" \
"console=" CONFIG_CONSOLE_DEV "\0" \
"fdt_file=imx6q-tibidabo.dtb\0" \
"fdt_addr=0x1400\0" \
"mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
"mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
"mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
"mmcautodetect=yes\0" \
"mmcargs=setenv bootargs console=${console},${baudrate} earlyprintk " \
"root=${mmcroot}\0" \
"loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
"loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \


#define CONFIG_BOOTCOMMAND \
"run mmcargs; " \
"run loadfdt; " \
"run loadimage; " \
"bootz ${loadaddr} - ${fdt_addr}; "\

it is easy.

I tried to put earlyprintk but i didn't see any output.



--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*

info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*
*address:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*phone:* +39 070 92432952
*email:* fausto.sess...@infomob.it
*skype:* fausto.sessego.infomob
*web:* www.infomob.it

2017-05-25 10:57 GMT+02:00 Anatolij Gustschin :

> On Wed, 24 May 2017 18:29:50 +0200
> Fausto Sessego fausto.sess...@infomob.it wrote:
> ...
> > The Kernel doesn't start.
> >
> > U-Boot 2016.07 (May 24 2017 - 17:11:18 +0200)
> >
> > CPU:   Freescale i.MX6Q rev1.2 at 792MHz
> > CPU:   Industrial temperature grade (-40C to 105C) at 20C
> > Reset cause: POR
> > Board: i.MX6Q TIBIDABO
> > Support: http://www.infomob.it/
> > I2C:   ready
> > DRAM:  gd->ram_size: 2147483648
> > DRAM test not implemented!
> > 2 GiB
> > MMC:   FSL_SDHC: 0, FSL_SDHC: 1
> > *** Warning - bad CRC, using default environment
>
> you didn't save the environment, so the default environment is
> used.
>
> > In:serial
> > Out:   serial
> > Err:   serial
> > Net:   FEC [PRIME]
> > Error: FEC address not set.
> >
> > Hit any key to stop autoboot:  0
> > reading imx6q-tibidabo.dtb
> > 29640 bytes read in 22 ms (1.3 MiB/s)
> > reading uImage
> > 6621928 bytes read in 324 ms (19.5 MiB/s)
> > ## Booting kernel from Legacy Image at 1200 ...
> >Image Name:   Linux-4.1.38
> >Image Type:   ARM Linux Kernel Image (uncompressed)
> >Data Size:6621864 Bytes = 6.3 MiB
> >Load Address: 10008000
> >Entry Point:  10008000
> >Verifying Checksum ... OK
> >Loading Kernel Image ... OK
> >
> > Starting kernel ...
>
> Please check 'bootargs' environment variable (print bootargs).
> It should contain "console=ttymxc0,115200" among other values.
> Probably this is not set in the default environment and is missing.
> Ensure that you are passing the correct console string for your
> board in bootargs. I'm not sure if ttymxc0 is correct, please
> test it first.
>
> --
> Anatolij
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-25 Thread Anatolij Gustschin
On Wed, 24 May 2017 18:29:50 +0200
Fausto Sessego fausto.sess...@infomob.it wrote:
...
> The Kernel doesn't start.
> 
> U-Boot 2016.07 (May 24 2017 - 17:11:18 +0200)
> 
> CPU:   Freescale i.MX6Q rev1.2 at 792MHz
> CPU:   Industrial temperature grade (-40C to 105C) at 20C
> Reset cause: POR
> Board: i.MX6Q TIBIDABO
> Support: http://www.infomob.it/
> I2C:   ready
> DRAM:  gd->ram_size: 2147483648
> DRAM test not implemented!
> 2 GiB
> MMC:   FSL_SDHC: 0, FSL_SDHC: 1
> *** Warning - bad CRC, using default environment

you didn't save the environment, so the default environment is
used.

> In:serial
> Out:   serial
> Err:   serial
> Net:   FEC [PRIME]
> Error: FEC address not set.
> 
> Hit any key to stop autoboot:  0
> reading imx6q-tibidabo.dtb
> 29640 bytes read in 22 ms (1.3 MiB/s)
> reading uImage
> 6621928 bytes read in 324 ms (19.5 MiB/s)
> ## Booting kernel from Legacy Image at 1200 ...
>Image Name:   Linux-4.1.38
>Image Type:   ARM Linux Kernel Image (uncompressed)
>Data Size:6621864 Bytes = 6.3 MiB
>Load Address: 10008000
>Entry Point:  10008000
>Verifying Checksum ... OK
>Loading Kernel Image ... OK
> 
> Starting kernel ...

Please check 'bootargs' environment variable (print bootargs).
It should contain "console=ttymxc0,115200" among other values.
Probably this is not set in the default environment and is missing.
Ensure that you are passing the correct console string for your
board in bootargs. I'm not sure if ttymxc0 is correct, please
test it first.

--
Anatolij
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-24 Thread Fabio Estevam
On Wed, May 24, 2017 at 5:56 PM, Fabio Estevam  wrote:

> Then pass 'earyprintk' in the kernel command line as well.

I meant "earlyprintk".
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-24 Thread Fabio Estevam
Hi Fausto,

Please do not top post in mailing lists.

On Wed, May 24, 2017 at 1:29 PM, Fausto Sessego 
wrote
>
>
> I tried many procedures but i did'nt found any solution.
>

Try to do:

make menuconfig

Kernel hacking  --->
[*] Kernel low-level debugging functions (read help!)
  Kernel low-level debugging port (i.MX6Q/DL Debug UART)
(1) i.MX Debug UART Port Selection (NEW)
[*] Early printk

In this example the console port is at UART1. If you have the console on
another UART then adjust it properly.

Then pass 'earyprintk' in the kernel command line as well.

This would help you to see where the kernel is hanging.

Hope it helps.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-24 Thread Fausto Sessego
Ok.

The Kernel doesn't start.

U-Boot 2016.07 (May 24 2017 - 17:11:18 +0200)

CPU:   Freescale i.MX6Q rev1.2 at 792MHz
CPU:   Industrial temperature grade (-40C to 105C) at 20C
Reset cause: POR
Board: i.MX6Q TIBIDABO
Support: http://www.infomob.it/
I2C:   ready
DRAM:  gd->ram_size: 2147483648
DRAM test not implemented!
2 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1
*** Warning - bad CRC, using default environment

In:serial
Out:   serial
Err:   serial
Net:   FEC [PRIME]
Error: FEC address not set.

Hit any key to stop autoboot:  0
reading imx6q-tibidabo.dtb
29640 bytes read in 22 ms (1.3 MiB/s)
reading uImage
6621928 bytes read in 324 ms (19.5 MiB/s)
## Booting kernel from Legacy Image at 1200 ...
   Image Name:   Linux-4.1.38
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:6621864 Bytes = 6.3 MiB
   Load Address: 10008000
   Entry Point:  10008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK

Starting kernel ...

Can it depend on u-boot version?

I'm using u-boot 2016.07 and kernel 4.1-1.0.x.

I get u-boot and kernel directly from yocto, so i think the matching is
right.

I tried many procedures but i did'nt found any solution.

Thanks

--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*

info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*
*address:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*phone:* +39 070 92432952
*email:* fausto.sess...@infomob.it
*skype:* fausto.sessego.infomob
*web:* www.infomob.it

2017-05-05 13:56 GMT+02:00 Fabio Estevam :

>
>
> On Fri, May 5, 2017 at 8:51 AM, Fausto Sessego 
> wrote:
>
>> Ok.
>>
>> I have the problem the Kernel Stucks at startup "Starting Kernel  "
>>
>> Could it depend on boot configuration (the macro  CONFIG_MMCROOT) ?
>>
>
> No, the rootfs will be mounted at a much later stage.
>
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-05 Thread Fabio Estevam
On Fri, May 5, 2017 at 8:51 AM, Fausto Sessego 
wrote:

> Ok.
>
> I have the problem the Kernel Stucks at startup "Starting Kernel  "
>
> Could it depend on boot configuration (the macro  CONFIG_MMCROOT) ?
>

No, the rootfs will be mounted at a much later stage.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-05 Thread Fausto Sessego
Ok.

I have the problem the Kernel Stucks at startup "Starting Kernel  "

Could it depend on boot configuration (the macro  CONFIG_MMCROOT) ?


--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*

info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*
*address:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*phone:* +39 070 92432952
*email:* fausto.sess...@infomob.it
*skype:* fausto.sessego.infomob
*web:* www.infomob.it

2017-05-05 13:38 GMT+02:00 Fabio Estevam :

>
>
> On Fri, May 5, 2017 at 7:50 AM, Fausto Sessego 
> wrote:
>
>> Ok,
>>
>> now it seems to work fine.
>>
>
> Ok, great!
>
>
>>
>> I have another question:
>>
>> the define
>> #define CONFIG_MMCROOT "/dev/mmcblk0p2"
>>
>> what does it mean?
>>
>> I have 2 sd card in my custom board:
>> 1) SD3 used like mass storage
>> 2) SD4 used to load the SO
>>
>
> This option specifies the location of the rootfs.
>
> A better approach is to use PARTUUID instead. Please check:
> http://git.denx.de/?p=u-boot.git;a=commitdiff;h=ca4f338e2efe
> ce5196eb2178e5f7d07be828da6e;hp=375d19c9114c1aca722f22fca937aec70e6feecf
>
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-05 Thread Fabio Estevam
On Fri, May 5, 2017 at 7:50 AM, Fausto Sessego 
wrote:

> Ok,
>
> now it seems to work fine.
>

Ok, great!


>
> I have another question:
>
> the define
> #define CONFIG_MMCROOT "/dev/mmcblk0p2"
>
> what does it mean?
>
> I have 2 sd card in my custom board:
> 1) SD3 used like mass storage
> 2) SD4 used to load the SO
>

This option specifies the location of the rootfs.

A better approach is to use PARTUUID instead. Please check:
http://git.denx.de/?p=u-boot.git;a=commitdiff;h=
ca4f338e2efece5196eb2178e5f7d07be828da6e;hp=375d19c9114c1aca722f22fca937ae
c70e6feecf
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-05-05 Thread Fausto Sessego
Ok,

now it seems to work fine.

I have another question:

the define
#define CONFIG_MMCROOT "/dev/mmcblk0p2"

what does it mean?

I have 2 sd card in my custom board:
1) SD3 used like mass storage
2) SD4 used to load the SO

thanks



--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*

info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*
*address:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*phone:* +39 070 92432952
*email:* fausto.sess...@infomob.it
*skype:* fausto.sessego.infomob
*web:* www.infomob.it

2017-04-11 15:01 GMT+02:00 Fabio Estevam :

>
>
> On Tue, Apr 11, 2017 at 8:20 AM, Fausto Sessego  > wrote:
>
>> what do you suggest?
>>
>> How can i check if the ram configuration is right?
>>
>
> https://community.nxp.com/docs/DOC-331930
>
> https://community.nxp.com/docs/DOC-105652
>
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-11 Thread Fausto Sessego
what do you suggest?

How can i check if the ram configuration is right?

Thanks

--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*
info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*

*a:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*p:* +39 070 92432952
*e:* fausto.sess...@infomob.it
*w:* www.infomob.it

2017-04-11 12:51 GMT+02:00 Fabio Estevam :

>
>
> On Tue, Apr 11, 2017 at 6:29 AM, Fausto Sessego  > wrote
>>
>>
>>
>> Could it be a problem of ram configuration?
>>
>
> Yes, this could be the problem.
>
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-11 Thread Fausto Sessego
I tryed to remove it but the result was the same.

I have another straing problem: if i enable the macro #define DEBUG in my
mx6board.h the system stuck

U-Boot 2016.07 (Apr 11 2017 - 11:19:23 +0200)

initcall: 1780b930
U-Boot code: 1780 -> 17847A3C  BSS: -> 178928E8
initcall: 17801cb4
CPU:   Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz)
CPU:   Extended Commercial temperature grade (-20C to 105C)malloc_simple:
size=10, ptr=ec, limit=400: 93fbdc
uclass_find_device_by_seq: 0 -1
uclass_find_device_by_seq: 0 0
   - -1 -1
   - not found
 at 27C
Reset cause: POR
initcall: 1780be60
Board: i.MX6Q SIBIRI
Support: http://www.infomob.it/
initcall: 1780b974
I2C:   ready
initcall: 1780b95c
DRAM:  initcall: 17802db0
gd->ram_size: 1073741824
initcall: 17802dd8
DRAM test not implemented!
initcall: 1780bbb4
Monitor len: 000928E8
Ram size: 4000
Ram top: 5000
initcall: 1780b75c
initcall: 1780b8d8
TLB table from 4fff to 4fff4000
initcall: 1780b774
initcall: 1780b88c
Reserving 586k for U-Boot at: 4ff5d000
initcall: 1780b85c
Reserving 10248k for malloc() at: 4f55b000
initcall: 1780ba8c
Reserving 80 Bytes for Board Info at: 4f55afb0
initcall: 1780b77c
initcall: 1780b828
Reserving 248 Bytes for Global Data at: 4f55aeb8
initcall: 1780b7c4
initcall: 1780b798
initcall: 1780bc34
initcall: 1780bb8c
initcall: 1780bae4

RAM Configuration:
Bank #0: 1000 1 GiB

DRAM:  1 GiB
initcall: 1780b7a8
New Stack Pointer is: 4f55ae90
initcall: 1780ba50
initcall: 1780b9e4
Relocation Offset is: 3875d000
Relocating to 4ff5d000, new gd at 4f55aeb8, sp at 4f55ae90
initcall: 4ff68c80
initcall: 4ff68c88

Could it be a problem of ram configuration?

Thanks


--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*
info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*

*a:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*p:* +39 070 92432952
*e:* fausto.sess...@infomob.it
*w:* www.infomob.it

2017-04-10 22:14 GMT+02:00 Fabio Estevam :

> On Mon, Apr 10, 2017 at 5:07 PM, Fausto Sessego
>  wrote:
> > It is right because it is a custom board designed  by my self.
> >
> > I renamed CONFIG_TARGET_MX6BOARD=y
> >
> > Do you have any hint?
>
> You can try removing the line ""mmcbooterror=echo Boot from mmc
> ERROR!!; " from your CONFIG_EXTRA_ENV_SETTINGS.
>
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-11 Thread Fabio Estevam
On Tue, Apr 11, 2017 at 8:20 AM, Fausto Sessego 
wrote:

> what do you suggest?
>
> How can i check if the ram configuration is right?
>

https://community.nxp.com/docs/DOC-331930

https://community.nxp.com/docs/DOC-105652
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-11 Thread Fabio Estevam
On Tue, Apr 11, 2017 at 6:29 AM, Fausto Sessego 
wrote
>
>
>
> Could it be a problem of ram configuration?
>

Yes, this could be the problem.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-10 Thread Fabio Estevam
On Mon, Apr 10, 2017 at 5:07 PM, Fausto Sessego
 wrote:
> It is right because it is a custom board designed  by my self.
>
> I renamed CONFIG_TARGET_MX6BOARD=y
>
> Do you have any hint?

You can try removing the line ""mmcbooterror=echo Boot from mmc
ERROR!!; " from your CONFIG_EXTRA_ENV_SETTINGS.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-10 Thread Fabio Estevam
On Mon, Apr 10, 2017 at 12:29 PM, Fausto Sessego 
wrote:

> Hi Fabio,
>
> in attachment there are my configuration files.
>
> I started from SabreSD and i changed very minimal parts.7
>
> Could you check if you see any error in my files?
>

It would be better to submit a proper support for your mx6 board.

You seem to call it mx6board, but in your defconfig you have:

CONFIG_TARGET_MX6BAORD=y

Looks like a typo.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-10 Thread Fausto Sessego
Hi Fabio,

in attachment there are my configuration files.

I started from SabreSD and i changed very minimal parts.7

Could you check if you see any error in my files?

thanks


--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*
info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*

*a:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*p:* +39 070 92432952
*e:* fausto.sess...@infomob.it
*w:* www.infomob.it

2017-04-10 16:45 GMT+02:00 Fabio Estevam :

> Hi Fausto,
>
> On Mon, Apr 10, 2017 at 7:54 AM, Fausto Sessego
>  wrote:
> > Hi,
> >
> > i have a problem with my custom board.
> >
> >
> >
> > I created my custom u-boot and, now, i would like load automatically the
> > kernel by CONFIG_BOOTCOMMAND.
> >
> >
> >
> > #define CONFIG_BOOTCOMMAND \
> >
> > "mmc dev ${mmcdev};"  \
> >
> > "if mmc rescan; then "  \
> >
> > "echo test1; "  \
> >
> > "else echo test2; fi; "
> >
> >
> >
> > Because i have the "if" condition, i enabled the CONFIG_HUSH_PARSER=y
> into
> > deconf file.
> >
> > Adding this CONFIG, the u-boot stuck
>
> CONFIG_HUSH_PARSER=y is enabled in many mx6 boards without issues.
>
> It is difficult to see what is wrong without seeing your patch adding
> the support for your board.
>
> Make sure you are using the latest U-Boot code and check what other
> mx6 boards are doing.
>
/*
 * Copyright (C) 2012 Freescale Semiconductor, Inc.
 *
 * Configuration settings for the Freescale i.MX6Q SabreSD board.
 *
 * SPDX-License-Identifier:	GPL-2.0+
 */

#ifndef __MX6BOARD_COMMON_CONFIG_H
#define __MX6BOARD_COMMON_CONFIG_H

#include "mx6_common.h"

#define CONFIG_IMX_THERMAL

/* Size of malloc() pool */
#define CONFIG_SYS_MALLOC_LEN		(10 * SZ_1M)

#define CONFIG_BOARD_EARLY_INIT_F
#define CONFIG_BOARD_LATE_INIT

#define CONFIG_MXC_UART

/* MMC Configs */
#define CONFIG_SYS_FSL_ESDHC_ADDR  USDHC4_BASE_ADDR


#define CONFIG_FEC_MXC
#define CONFIG_MII
#define IMX_FEC_BASE			ENET_BASE_ADDR
#define CONFIG_FEC_XCV_TYPE		RGMII
#define CONFIG_ETHPRIME			"FEC"
#define CONFIG_FEC_MXC_PHYADDR		1


#define CONFIG_PHYLIB
#define CONFIG_PHY_ATHEROS


#ifdef CONFIG_CMD_SF
#define CONFIG_MXC_SPI
#define CONFIG_SF_DEFAULT_BUS		0
#define CONFIG_SF_DEFAULT_CS		0
#define CONFIG_SF_DEFAULT_SPEED		2000
#define CONFIG_SF_DEFAULT_MODE		SPI_MODE_0
#endif

/* Command definition */
#define CONFIG_CMD_BMODE

#ifdef CONFIG_SUPPORT_EMMC_BOOT
#define EMMC_ENV \
	"emmcdev=2\0" \
	"update_emmc_firmware=" \
		"if test ${ip_dyn} = yes; then " \
			"setenv get_cmd dhcp; " \
		"else " \
			"setenv get_cmd tftp; " \
		"fi; " \
		"if ${get_cmd} ${update_sd_firmware_filename}; then " \
			"if mmc dev ${emmcdev} 1; then "	\
"setexpr fw_sz ${filesize} / 0x200; " \
"setexpr fw_sz ${fw_sz} + 1; "	\
"mmc write ${loadaddr} 0x2 ${fw_sz}; " \
			"fi; "	\
		"fi\0"
#else
#define EMMC_ENV ""
#endif

#define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG

#ifndef VIDEO_ARGS
#define VIDEO_ARGS ""
#endif

#ifndef VIDEO_ARGS_SCRIPT
#define VIDEO_ARGS_SCRIPT ""
#endif

#define CONFIG_EXTRA_ENV_SETTINGS \
	"script=boot.scr\0" \
	"image=zImage\0" \
	"console=" CONFIG_CONSOLE_DEV "\0" \
	"fdt_high=0x\0" \
	"initrd_high=0x\0" \
	"fdt_file=imx6q-board.dtb\0" \
	"fdt_addr=0x1800\0" \
	"boot_fdt=try\0" \
	"mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
	"mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
	"mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
	"mmcautodetect=yes\0" \
	"mmcargs=setenv bootargs console=${console},${baudrate} " \
		"root=${mmcroot}\0" \
	"loadbootscript=" \
		"fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
	"bootscript=echo Running bootscript from mmc ...; " \
		"source\0" \
	"loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
	"loadimagerror=echo Load zImage from mmc ERROR!!; " \
	"loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
	"mmcboot=echo Booting from mmc ...; " \
		"run mmcargs; " \
		"if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
			"if run loadfdt; then " \
"bootm ${loadaddr} - ${fdt_addr}; " \
			"else " \
"if test ${boot_fdt} = try; then " \
	"bootm; " \
"else " \
	"echo WARN: Cannot load the DT; " \
"fi; " \
			"fi; " \
		"else " \
			"bootm; " \
		"fi;\0" \
	"mmcbooterror=echo Boot from mmc ERROR!!; "

#if 0
#define CONFIG_BOOTCOMMAND \
	"mmc dev ${mmcdev}; if mmc rescan; then " \
		"if run loadbootscript; then " \
			"run bootscript; " \
		"else " \
			"if run loadimage; then " \
"run mmcboot; " \
			"else run loadimagerror; " \
			"fi; " \
		"fi; " \
	"else run mmcbooterror; fi; " \

#endif

#define CONFIG_BOOTCOMMAND \
	"mmc dev ${mmcdev};" \
	"if mmc rescan; then " \
	"echo test1; " \

Re: [U-Boot] i.Mx6q u-boot stuck

2017-04-10 Thread Fabio Estevam
Hi Fausto,

On Mon, Apr 10, 2017 at 7:54 AM, Fausto Sessego
 wrote:
> Hi,
>
> i have a problem with my custom board.
>
>
>
> I created my custom u-boot and, now, i would like load automatically the
> kernel by CONFIG_BOOTCOMMAND.
>
>
>
> #define CONFIG_BOOTCOMMAND \
>
> "mmc dev ${mmcdev};"  \
>
> "if mmc rescan; then "  \
>
> "echo test1; "  \
>
> "else echo test2; fi; "
>
>
>
> Because i have the "if" condition, i enabled the CONFIG_HUSH_PARSER=y into
> deconf file.
>
> Adding this CONFIG, the u-boot stuck

CONFIG_HUSH_PARSER=y is enabled in many mx6 boards without issues.

It is difficult to see what is wrong without seeing your patch adding
the support for your board.

Make sure you are using the latest U-Boot code and check what other
mx6 boards are doing.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] i.Mx6q u-boot stuck

2017-04-10 Thread Fausto Sessego
Hi,

i have a problem with my custom board.



I created my custom u-boot and, now, i would like load automatically the
kernel by CONFIG_BOOTCOMMAND.



#define CONFIG_BOOTCOMMAND \

"mmc dev ${mmcdev};"  \

"if mmc rescan; then "  \

"echo test1; "  \

"else echo test2; fi; "



Because i have the "if" condition, i enabled the CONFIG_HUSH_PARSER=y into
deconf file.

Adding this CONFIG, the u-boot stuck



CPU: Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz)
CPU: Extended Commercial temperature grade (-20C to 105C) at 26C
Reset cause: POR
I2C: ready
DRAM: gd->ram_size: 1073741824
DRAM test not implemented!
1 GiB



Whitout the definition CONFIG_HUSH_PARSER=y i have the following result:




CPU: Freescale i.MX6Q rev1.5 996 MHz (running at 792 MHz)
CPU: Extended Commercial temperature grade (-20C to 105C) at 28C
Reset cause: POR
I2C: ready
DRAM: gd->ram_size: 1073741824
DRAM test not implemented!
1 GiB

1 GiB
MMC: FSL_SDHC: 0, FSL_SDHC: 1
*** Warning - bad CRC, using default environment

In: serial
Out: serial
Err: serial
Net: FEC [PRIME]
Error: FEC address not set.

Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc1 is current device
Unknown command 'if' - try 'help'
Unknown command 'then' - try 'help'
Unknown command 'else' - try 'help'
Unknown command 'fi' - try 'help'

Custimized_board>



Why, if i enable the CONFIG_HUSH_PARSER=y, the u-boot stuck?
--
*Ing. Fausto Sessego*
*R Hardware & Software Engineer*
info
mob
>
*Tecnologie Wireless per la logistica e la sicurezza*

*a:* Parco scientifico e tecnologico della Sardegna, Edificio 1 Loc.
Piscinamanna - 09010 Pula (CA)

*p:* +39 070 92432952
*e:* fausto.sess...@infomob.it
*w:* www.infomob.it
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot