How to Test Yocto for i.MX6

cancel
Showing results for 
Search instead for 
Did you mean: 

How to Test Yocto for i.MX6

How to Test Yocto for i.MX6

Join FSL-community-bsp project: https://lists.yoctoproject.org/listinfo/meta-freescale

In order to test Yocto Project for i.MX6 or any other supported board please follow the instructions pointed by FSL Community BSP.

In order to download the source code, please follow this instructions FSL Community BSP.

With the downloaded source code, you can follow the steps from this training: Yocto Training - HOME

If you face a problem, please, send an email to https://lists.yoctoproject.org/listinfo/meta-freescale

This page made sense when there was not other tutorial to point people on how to download and build the very first image using Yocto Project tools for i.MX family boards. Today, FSL Community BSP has become a complete environment with its own landing page (FSL Community BSP) and a collaborative community around meta-freescale mailing list. I encourage you to register in meta-freescale mailing list.

I configured this document to be closed for new comments. In case of any issue or bug, please, send an email to meta-freescale.

Comments

Daiane, my "repo sync" failed with this output:

* [new tag]     purple-3.2 -> purple-3.2
* [new tag]     purple-3.2.1 -> purple-3.2.1

Fetching projects: 100% (6/6), done. 

error: Exited sync due to gc errors


was you able to take the source code?

Are you under any proxy?

I have a lot of sync errors due to my proxy configurations, and when I try again I can take the source code without errors. Could you try again?

Thanks Daiane,

This is a terrific intro to Yocto.

Note that there is a typo above ("souce" should be "source").

Daiane, after I did "repo sync -j2" the problem went away. Thanks for all your help.

Hi,

I'm trying to follow the directions listed above by entering the following commands:

  curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ./repo

  chmod a+x ./repo

  repo init -u https://github.com/Freescale/fsl-community-bsp-platform -b master

  repo sync

  vi conf/local.conf

  bitbake fsl-image-gui

However, I'm receiving the following error:

Pseudo is not present but is required, building this first before the main build

Loading cache: 100% |###########################################| ETA:  00:00:00

Loaded 1598 entries from dependency cache.

ERROR: No recipes available for:

  /home/vradmin/projects/MOCUPort/YOCTO/rootfs_builder/sources/meta-fsl-arm/recipes-core/udev/udev_173.bbappend

ERROR: Command execution failed: Exited with 1

Summary: There were 2 ERROR messages shown, returning a non-zero exit code.


Do you know what might be causing this error?





Seems like adding:

BBMASK = "udev_.*\.bbappend$"

to end of conf/local.conf fixes works around this error.

Yes; I will fix it. The master doesn't need to force udev anymore.

I sent the patch to the mailing list (meta-freescale).

The patches are now merged and it should just work.

I also seem to fail on


source ./setup-environment build

bash: ./setup-environment: No such file or directory

Is there something else that I need to install

You need to be under "rootfs_builder", if you´re following exactly the directory approach from tutorial.

If you:

$ cd rootfs_builder

$ ls

You must see setup-environment as a text file (and repo and README and directory sources)

./repo sync -j2

error: Exited sync due to gc errors

I only see a repo file and a .repo directory.

So, your problem is during sync.

Are you under a proxy? Can you reach https or only http?

Hi I also have the same issue i.e

./repo sync -j2

error: Exited sync due to gc errors


and my proxy settings are as fllows:

faisal@faisal-desktop:~$ set | grep -i proxy

            url proxy fetch push mirror skipDefaultUpdate

        core.gitProxy

        http.proxy

                COMPREPLY=($( compgen -W "$opts --percent --force                 --test --replacepkgs --replacefiles --root                 --excludedocs --includedocs --noscripts --ignorearch                 --dbpath --prefix --ignoreos --nodeps --allfiles                 --ftpproxy --ftpport --justdb --httpproxy --httpport                 --noorder --relocate --badreloc --notriggers                 --excludepath --ignoresize --oldpackage                 --queryformat --repackage --nosuggests" -- "$cur" ));

                            COMPREPLY=($( compgen -W "$opts --ftpport --ftpproxy                         --httpport --httpproxy" -- "$cur" ));

        PreferredAuthentications Protocol ProxyCommand \

faisal@faisal-desktop:~$


I just tried on my machine and it does work over here.

You can try this:

repo init -u http://github.com/Freescale/fsl-community-bsp-platform -b master


instead of https.


Could you, please, try again?

I've found that on ubuntu there could be problem with git which causes this error.

To resolve :

sudo apt-add-repository ppa:git-core/ppa

sudo apt-get update

sudo apt-get install git

After that there is no matter are you using https or http.


Hi.... I am running into this basic error.. Looks like repo cannot find the web page.

root@LinuxRig:/home/wintu/YOCTO# repo init -u http://github.com/Freescale/fsl-community-bsp-platform -b danny

... A new repo command ( 1.18) is available.

... You should upgrade soon:

    cp /home/wintu/YOCTO/.repo/repo/repo /bin/repo

fatal: http://github.com/Freescale/fsl-community-bsp-platform/info/refs download error - The requested URL returned error: 403

fatal: http://github.com/Freescale/fsl-community-bsp-platform/info/refs download error - The requested URL returned error: 403

  Any help....

I just tried it over here and it does work.

Could you, please, test the same again? If you face the error again, try to reach the web page using your browser.

Make sure your proxy allow this operation. (double check if you´re using http or https proxy)

Besides the tests Daiane has asked you please give more details about your host system:

* distribution

* version

Hi Daiane,

    I tried same thing again.. Even i tried with https:// and still same issue.

And when i try it from browser too i get same mesage. ( attached screen shot)

Screenshot.png

I'm from india... So is that web page not accessible from india ??

Regards,

Winston

Hi OtavioSalvador,

      I m using Ubuntu 9.04 Jaunty. with kernel 2.6.28-11-generic.

  I guess that web address not accessible in india.

Regards,

  Winston

Hello,

I just did a new test here:

~/test% repo init -u https://github.com/Freescale/fsl-community-bsp-platform -b danny

Get https://gerrit.googlesource.com/git-repo/clone.bundle

Get https://github.com/Freescale/fsl-community-bsp-platform

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current

                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:--  0:00:09 --:--:--     0

curl: (22) The requested URL returned error: 404 Not Found

Server does not provide clone.bundle; ignoring.

WARNING: gnome-keyring:: couldn't connect to: /run/user/otavio/keyring-q0sd1e/pkcs11: No such file or directory

remote: Counting objects: 69, done.

remote: Compressing objects: 100% (63/63), done.

remote: Total 69 (delta 21), reused 53 (delta 5)

Unpacking objects: 100% (69/69), done.

From https://github.com/Freescale/fsl-community-bsp-platform

* [new branch]      danny      -> origin/danny

* [new branch]      denzil     -> origin/denzil

* [new branch]      master     -> origin/master

* [new tag]         1.2        -> 1.2

Your identity is: Otavio Salvador <otavio@ossystems.com.br>

If you want to change this, please re-run 'repo init' with --config-name

repo initialized in /home/otavio/test

So it is clearly something at your side. I once had a problem due curl issues. 'repo' uses curl to fetch some stuff (as git does as well) so maybe you might try to upgrade curl and give it a new try?

Does anyone have any tips for booting the sdcard. I've tried the uboot that comes with it and I've tried known good commands/ similar commands to an ltib generated sd card. However, no luck so far.

I'll I get is a stall at loading uImage, when I run the card (directly burned).

Any thoughts?

Also is there any issue with working off the master branch?

Or is that the most buggy version?

P.S. My board is a SabreSDP, IMX6.

The easiest way of making it to work is to dd the tmp/deploy/images/<image>.sdcard file directly onto your device.

To dd the u-boot.imx binary you should avoid the skip=2 (as the u-boot.imx has no padding).

Hi Otavio,

Thanks for answering.

I followed the instruction above.

"sudo dd if=rootfs_builder/build/tmp/deploy/images/fsl-image-test.sdcard of=/dev/sdb"

It just doesn't seem to boot. Before that I've had no problem getting my ltib images and the ubuntu RFS up.

This is my first foray into Yocto. So I was hoping that I didn't miss anything.

Hum; what is the revision of your board?

I'll have to get back to you on that one. I do know that the box has images on the outside, where the earlier SDP's did not have the box images.

I know that doesn't help much, but I'll have a better answer for you later in the day. I as far as I know it's quite new.

If it is the revision C it might be the problem; I am backporting the fix of U-Boot mainline to the 2012.10 and will post a heads-up when it is done.

Hello,

So I did the porting of need changes. Could you please give this a try?

Do:

$: git clone --branch patches-2012.10 git://github.com/Freescale/u-boot-imx.git u-boot-imx

Apply the patches:

http://download.ossystems.com.br/~otavio/u-boot-patches/2012.10/0001-COMMON-Add-__stringify-function...

http://download.ossystems.com.br/~otavio/u-boot-patches/2012.10/0002-mx6-Disable-Power-Down-Bit-of-w...

http://download.ossystems.com.br/~otavio/u-boot-patches/2012.10/0003-Backport-environment-changes-fr...

And setup your toolchain. Build: u-boot.imx and put it in a sdcard. I hope it works. If you confirms it to me I will be able to push it so we fix it in danny.    

The Revision is: REV C2

I will try this out and get an update back to you.

I'm having difficulties setting up the tool-chain using Yocto. Any advice would be helpful.

Please, create a new topic with your question and some log.

setup tool-chain on yocto is easy, but it´s not trivial, so I believe a new discussion will be more organized for any other person looking for it.

Now the patches otavio posted is already integrated, so if you repo sync your danny branch you will be able to take the patches and test it with no additional steps.

If you create a new topic, please, share it with me

I performed the repo sync

Then I performed a bitbake fsl-image-test

Then wrote the card.

The below log shows a series of boots. With different outcomes.

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

reading uImage

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

reading uImage

Error reading cluster

** Unable to read "uImage" from mmc 0:1 **

Booting from net ...

FEC Waiting for PHY auto negotiation to complete......... TIMEOUT !

BOOTP broadcast 1

BOOTP broadcast 2

BOOTP broadcast 3

BOOTP broadcast 4

BOOTP broadcast 5

Retry count exceeded; starting again

FEC Waiting for PHY auto negotiation to complete......... TIMEOUT !

BOOTP broadcast 1

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

bad MBR sector signature 0x055a

** Partition 1 not valid on device 0 **

** Unable to use mmc 0:1 for fatload **

Booting from net ...

FEC Waiting for PHY auto negotiation to complete......... TIMEOUT !

BOOTP broadcast 1

BOOTP broadcast 2

BOOTP broadcast 3

BOOTP broadcast 4

BOOTP broadcast 5

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

reading uImage

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

reading uImage

Error reading cluster

** Unable to read "uImage" from mmc 0:1 **

Booting from net ...

FEC Waiting for PHY auto negotiation to complete......... TIMEOUT !

BOOTP broadcast 1

BOOTP broadcast 2

BOOTP broadcast 3

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

reading uImage

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

reading boot.scr

** Unable to read "boot.scr" from mmc 0:1 **

reading uImage

U-Boot 2012.10-00994-g7e6c682 (Feb 22 2013 - 09:15:52)

CPU:   Freescale i.MX6Q rev1.2 at 792 MHz

Reset cause: POR

Board: MX6Q-SabreSD

DRAM:  1 GiB

WARNING: Caches not enabled

MMC:   FSL_SDHC: 0

*** Warning - bad CRC, using default environment

In:    serial

Out:   serial

Err:   serial

Net:   FEC [PRIME]

Warning: FEC using MAC address from net device

Hit any key to stop autoboot:  0

mmc0 is current device

** No partition table - mmc 0 **

** No partition table - mmc 0 **

Booting from net ...

FEC Waiting for PHY auto negotiation to complete......... TIMEOUT !

BOOTP broadcast 1

BOOTP broadcast 2

BOOTP broadcast 3

BOOTP broadcast 4

BOOTP broadcast 5

Retry count exceeded; starting again

I haver successfully built the in both master and danny using "LinuxMint-14" as a host os in virtualbox as well as natively on laptop. It would be *nice* to add that as a validated build system. Linux Mint (mate desktop) is a much more productive environment vs some of the "other" popular desktops - and much lighter weight!

I think it's a great idea! Thanks a lot.

Could you, please, share how was you able to achieve it in your side?

The list of validated distros are the ones the active developers use so they keep testing it; I'll bring you the discussion about adding MINT as a valid one as it is based in Ubuntu and thus share most core components (toolchain and like).

Do you think you'll be an active user of Yocto or you're just playing with it for curiosity?

Sorry, but also i trivial problem, probably:

$ repo init -u https://github.com/Freescale/fsl-community-bsp-platform -b danny

Get https://gerrit.googlesource.com/git-repo/clone.bundle

$

...but nothing is fetched. The repo init commands just outputs the line and exits.

So...:

$ repo sync

error: command 'sync' requires repo to be installed first.

        Use "repo init" to install it here.

$

Same result id http:// is used instead of https:// - in the command, as well as in the REPO_URL inside the repo script.

Sorry I'm no git expert - is there supposed to be a file named "clone.bundle" in the referenced git-repo? I don't see it...

I´m downloading it over here.

Could you, please, try again?

Same result.

But in the meantime I tried at home, on my own computer and network: No problem (or not this problem, at least :smileyhappy:).

So the problem is definitely in "my" end. Differences: At work, with the problem, we have CentOS5 + addons, and firewall/proxy. At home: CentOS6 and no proxy. (Needed to install a newer git than the one provided with CentOS6).

Think I tried everything to get the proxy stuff correct; I *was* able to fetch "repo" with curl over https. And also tried git config.... I will investigate further; guess it's hard to figure out from your place what's wrong here!

The build at home ran for most of the night, then bailed out... I'll raise that as a separate question.

And... tnx for you prompt answer!

Trying to build fsl-image-gui. The build runs fine for some time (some hours - does more than 3000 of the app. 6100 tasks, and eats >40GB of disk space!). Then:

WARNING: Failed to fetch URL http://gpe.linuxtogo.org/download/source/xserver-common-1.34.tar.gz, attempting MIRRORS if available

ERROR: Fetcher failure: Fetch command failed with exit code 4, no output

ERROR: Function failed: Fetcher failure for URL: 'http://gpe.linuxtogo.org/download/source/xserver-common-1.34.tar.gz'. Unable to fetch URL from any source.

ERROR: Logfile of failure stored in: /home/hj/yocto/rootfs_builder/build/tmp/work/all-poky-linux/xserver-common-1.34-r8/temp/log.do_fetch.24584

ERROR: Task 5488 (/home/hj/yocto/rootfs_builder/sources/meta-openembedded/meta-oe/recipes-graphics/xserver-common/xserver-common_1.34.bb, do_fetch) failed with exit code '1'

NOTE: Tasks Summary: Attempted 3517 tasks of which 3515 didn't need to be rerun and 1 failed.

Waiting for 0 running tasks to finish:

Summary: 1 task failed:

/home/hj/yocto/rootfs_builder/sources/meta-openembedded/meta-oe/recipes-graphics/xserver-common/xserver-common_1.34.bb, do_fetch

Summary: There was 1 WARNING message shown.

Summary: There were 2 ERROR messages shown, returning a non-zero exit code.


(This is the output from an attempt to restart the build).

"File not found", it seems... does the recipe need update - or other suggestions?

Seems to be a proxy problem in connection with the "repo" script.

Hacked the script; the clone.bundle file is created with the content: <HTML></HTML>

clone.bundle is created by the _DownloadBundle function in "repo". It uses urllib to retrieve the data.

With wireshark I can see that the proxy server is accessed with "GET https://gerrit.googlesource.com./(...)", but there is no encrypted session started.

Maybe bad Python version? (It's 2.6).

I always face failed to fetch, then when I try again everything works. I think it´s the network somehow.

Failed to fetch is bitbake trying to download the package from server provider and not being able to complete it.

Due to local firewall restrictions on the use of the git protocol I am experiencing a error during do_fetch for danny udev_173. Removing the bbappend reverts to getting a tar over http but file is missing (the reason why there is a bbappend to change to git I suppose)

Fedora has a copy and this patch seems to resolve the problem:

--- a/meta-fsl-arm/recipes-core/udev/udev_173.bbappend    2013-04-04 22:31:22.006040965 -0700
+++ b/meta-fsl-arm/recipes-core/udev/udev_173.bbappend    2013-04-05 00:09:54.327713016 -0700
@@ -1,8 +1,5 @@
-PRINC := "${@int(PRINC) + 2}"
+PRINC := "${@int(PRINC) + 3}"

-# Switch to git source
-# 173 tag
-SRCREV = "ad667dff51711fed763a23283d973486de3cd6b5"
+# Switch to fedora source
SRC_URI := "${@oe_filter_out('${KERNELORG_MIRROR}/linux/utils/kernel/hotplug/udev-${PV}.tar.bz2', '${SRC_URI}', d)}"
-SRC_URI_prepend = "git://git.kernel.org/pub/scm/linux/hotplug/udev.git;protocol=git "
-S = "${WORKDIR}/git"
+SRC_URI_prepend = "http://pkgs.fedoraproject.org/repo/pkgs/udev/udev-173.tar.bz2/91a88a359b60bbd074b024883cc0dbde/udev-... "

Yes; this is the reason why we moved to the GIT. However I think you do need to fix your firewall as many recipes are using GIT to fetch the sources and you'll have a huge problem to workaround it for every case.    

I will try to have the corporate firewall policy changed but I am only a small cog...

In practice the absence of the git protocol does not seem to be a huge problem. I found no other errors for a minimal core image build and only 2 errors when running 'bitbake -c fetchall fsl-image-test'. These were fixed by adding ;protocol=http to the end of the url in the fio_2.0.5 recipe and changing to http://linuxtv.org/downloads/v4l-utils/v4l-utils-0.8.8.tar.bz2 for the v4l-utils_0.8.8 recipe

I am experiencing an error during do_compile of perf_3.4

util/include/linux/compiler.h:8:0: error: "__attribute_const__" redefined

There appears to be a patch available to resolve this problem at https://lists.yoctoproject.org/pipermail/yocto/2012-October/012625.html but it does not seem to have been applied to meta-fsl-arm. Can someone explain to me a possible reason why I am seeing this problem (when I assume others are not). Should I apply the patch or may there be a different cause of the problem

I see the same compile problem with perf. Decided to silently await that someone fixes it :smileyhappy:

Ok I will try adding meta-fsl-arm/recipes-kernel/perf/files/define-attribute-const.patch and meta-fsl-arm/recipes-kernel/perf/perf_3.4.bbappend with the content from Chunrong Guo and see if this resolves it

Version history
Revision #:
1 of 1
Last update:
‎11-28-2012 10:40 AM
Updated by: