i.MX Yocto Project: How can I (quickly) modify the kernel and test it?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

i.MX Yocto Project: How can I (quickly) modify the kernel and test it?

i.MX Yocto Project: How can I (quickly) modify the kernel and test it?

The edit-compile-test loop is the quickest way so can test your changes.

1. Go to the package's source code folder and edit your files.

2. Compile that particular package, e.g.

bitbake linux-imx -c compile -f

3. Deploy, e.g.

bitbake linux-imx -c deploy

4. Insert the SD card into your host, and copy the Linux kernel into the the first partition

sudo cp tmp/deploy/images/uImage /media/Boot

5. Insert the SD card into your board, boot and test your changes

6. In case you are satisfied with the results, you need to create a patch and add into the package's recipe. Check this document to execute this step.

Labels (1)
Comments

This is helpful. Thanks! Consider correcting the line

sudo cp tmp/deploy/uImage /media/Boot

to

sudo cp tmp/deploy/images/uImage /media/Boot

Corrected. Thanks!

I use (modified) wandboard linux for developing and I use this command line:

bitbake linux-wandboard -c compile -f && ./sendkernel.sh

The content of sendkernel is:

#!/bin/sh

ssh root@imx 'mount /dev/mmcblk0p1 /mnt/mmcblk0p1'

scp tmp/work/wandboard_quad-poky-linux-gnueabi/linux-wandboard/3.0.35-r0/git/arch/arm/boot/uImage root@imx:/mnt/mmcblk0p1

ssh root@imx reboot

It copies only the kernel itself without the modules and do not do "deploy" what is much slower.

Hope it helps. :smileyhappy:

Thanks. You are avoiding the deploying step. I usually execute the deploy task, because I may deploy other kernels and the link /tmp/deploy/images/uImage will point to the latest, so TFTP transfer (from u-boot) will always pick this one...

Leo

Dear Leonardo Sandoval Gonzalez,

Thanks for your document it was helpful to me.

I am having a few doubts.

My purpose:I have to boot t4240qds.

using:Ubuntu 12.04 , SDK 1.4 , created a fsl-image-core.

I have seen the information center and other references but still i am quite doubtful.

1) should I surely modify the u-boot? in the sense what can be achieved by doing so ? Also what i have to modify to boot t4240qds ?

2) can i boot from sd card ? if so then do i need a tftp server?

Can you please clarify?

Thanks

Aravind

Aravind, I am not familiar with that board. In general, for a board boot-up, you do not need yocto at this point.In the other hand, the TFTP server is commonly used for kernel development, in the sense that you recompile the kernel, move the Image to the server and reboot the board to see the changes.

Leo

Dear Leonardo Sandoval Gonzalez,

Thanks for your document.

I am having a doubt, where to excute the follow cmd?

bitbake linux-imx -c compile -f

Dear Leo,

Never mind.

Thanks for your response.

Do you have any idea for testing of mport driver ( IDT Tsi721 PCI Express SRIO Controller support ) ?

I have modified the kernel to enable the above support and also copied the images.

Any procedures or test cases for the testing will be very helpful.

Thanks

Aravind

Hi Aravind

Sorry for the delay.

1. -f means force a task to be executed. This is necessary when code is modified on tmp folder, otherwise it would not take into account all changes you have done.

2. I have no idea about the testing you need.

Dear Leo

Thanks for your response.

Aravind

On Sep 8, 2014 11:24 PM, "Leonardo Sandoval Gonzalez" <

I found the location to excute the bitbake linux-imx command.

build$

Thanks.

Dear Leo,

Thanks for your document.
Why do we use compile?
Does not compile when I use compile?

Thanks
Yasarcan
No ratings
Version history
Last update:
‎06-17-2013 02:08 PM
Updated by: