element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Members
    Members
    • Benefits of Membership
    • Achievement Levels
    • Members Area
    • Personal Blogs
    • Feedback and Support
    • What's New on element14
  • Learn
    Learn
    • Learning Center
    • eBooks
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Dev Tools
    • Manufacturers
    • Raspberry Pi
    • RoadTests & Reviews
    • Avnet Boards Community
    • Product Groups
  • Store
    Store
    • Visit Your Store
    • Choose Another Store
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
RIoTboard
  • Products
  • Dev Tools
  • Single-Board Computers
  • RIoTboard
  • More
  • Cancel
RIoTboard
Blog Riotboard Yocto  : Part3 : Build Kernel using Yocto
  • Blog
  • Forum
  • Documents
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
RIoTboard requires membership for participation - click to join
Blog Post Actions
  • Subscribe by email
  • More
  • Cancel
  • Share
  • Subscribe by email
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: tusharp
  • Date Created: 29 Sep 2014 4:03 PM Date Created
  • Views 441 views
  • Likes 0 likes
  • Comments 0 comments
  • tusharp
  • yocto
  • image
  • bitbake
  • freescale
  • imx6
  • riotboard
  • embedded
  • setup
  • riot
  • cortex-a9
  • kernel
  • poky
  • bsp
  • arm9
  • linux
Related
Recommended

Riotboard Yocto  : Part3 : Build Kernel using Yocto

tusharp
tusharp
29 Sep 2014

Contents:
Part1 : Environment setup and initial build
Part2 : Build u-boot using Yocto
Part3 : Build Kernel using Yocto     <-- You are here
Part4 : Package Development using Yocto
Part5 : Application Development using ADT

 

In the previous blog we have build uboot for Riotboard.

 

The blog will walkthrough the process of fetch,configure,compile and build kernel for i.MX6 Riotboard  using yocto bitbake tool .

 

Setting up yocto for Riotboard:

~$ cd fsl-arm-yocto-bsp

~/fsl-arm-yocto-bsp$  MACHINE=riotboard source fsl-setup-release.sh -b build -e fb

~/fsl-arm-yocto-bsp/build$

 

All the commands henceforth are executed from build directory after above MACHINE configuration.

 

Locating available riotboard specific recipes:

~/fsl-arm-yocto-bsp/build$ bitbake -s | grep linux

2eq8k03.jpg

 

we will select the first one : linux-riotboard (3.10.17 version)

 

 

Kernel source directory :

/build/tmp/work/riotboard-poky-linux-gnueabi/linux-riotboard/3.10.17-r0/git

 

 

Kernel recipe location :

/sources/meta-fsl-arm-extra/recipes-kernel/linux/linux-riotboard_3.10.17.bb

 

 

Configuring the Kernel :

~/fsl-arm-yocto-bsp/build$ bitbake -c menuconfig linux-riotboard

 

Generate Kernel Image

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard

 

the newly build kernel uImage:

/build/tmp/deploy/images/riotboard

2s6am1f.jpg

 

Along with the uImage we got a  uImage-imx6solo_RIoTboard.dtb  device tree blob.

More information on DTB here and here.

 

We will build kernel stepwise while going through the yocto build system.

I am aggregating the  build steps here, for detailed info plz check Yocto Documentation.

 

 

Getting list of all task  to-be-executed  during  kernel build:

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c listtasks

vf8dxs.jpg

 

From the yocto website we can execute below tasks for kernel build.

28nn7n.jpg

 

clean up build directory: (not everytime)

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c clean -f

 

fetch linux tarball:

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c fetch -f

 

from the kernel receipe linux-riotboard_3.10.17.bb, its clear it pulls from embest github repo.

wgvwbr.jpg

 

With the Riotboard patches being pushed to mainline kernel, you can configure it to get mainline support.

kernel.org/pub/linux/kernel/git/stable/linux-stable.git

 

if you have a local source the SRC_URI can be changed to :

SRC_URI = "file://<CUSTOM_LINUX_TARBALL>"

 

unpack the source :

This will populate the git folder “tmp/work/riotboard-poky-linux-gnueabi/linux-riotboard/3.10.17-r0/git” with kernel source code.

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c unpack -f

 

Configure kernel :

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c menuconfig -f

a new window will pop-up and you can Configure kernel by enable/disable various options available.

106cyv6.jpg

 

Compile the kernel.

This will generate kernel image, modules and dtb.

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c compile -f

 

Now Deploy only the kernel.

~/fsl-arm-yocto-bsp/build$ bitbake linux-riotboard -c deploy -f

 

you will find the below newly created files in tmp/deploy/images/riotboard

 

2ugoqc2.jpg

 

Okay that's all for now , Next time we build a simple package using the yocto platform .

  • Sign in to reply
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2023 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • Facebook
  • Twitter
  • linkedin
  • YouTube