UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Observer winston
Observer
819 Views
Registered: ‎06-06-2018

How to build modified kernel

Jump to solution

Hi all,

     I worked with petalinux 2018.1, here I am using ZCU102's BSP, and I did some modification in kernel i2c driver and I am used  petalinux-build command to build, but I did not get any modification in log after boot the board. Any one help me to give the steps to  modify and build the kernel.

 

 

Thanks.

0 Kudos
1 Solution

Accepted Solutions
Xilinx Employee
Xilinx Employee
976 Views
Registered: ‎02-07-2018

Re: How to build modified kernel

Jump to solution

Hi Wiston,

 

You can do this by two methods

Method1:

1. Download same kernel tag from repository

2. modify your changes and create patch using git

3. follow the steps mentioned in this link :http://www.wiki.xilinx.com/PetaLinux+Yocto+Tips section "Patching the Linux Kernel of a PetaLinux Project "

4. petalinux-build

 

 

Method 2:

You can build kernel as External kernel source option

Build steps for External source using petalinux:
1. petalinux-config and go to -> Linux Components Selection ---> linux-kernel (ext-local-src)
External linux-kernel local source settings --->/aravind_working_dir/source_code/my_xlnx (EXternal linux-kernel local source path)

2. Go to -> Auto Config Settings and select Specify a manual device tree include directory and enter the path to the new kernel include directory.

Auto Config Settings ---> [*] Specify a manual device tree include directory
(/aravind_working_dir/source_code/my_xlnx/arch/arm64/boot/dts/include) Manual device tree include directory

3. Save and exit petalinux-config

4. Do a petalinux-build

 

 

Thanks & regards

Aravind

 

----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
----------------------------------------------------------------------------------------------

 

0 Kudos
3 Replies
Xilinx Employee
Xilinx Employee
977 Views
Registered: ‎02-07-2018

Re: How to build modified kernel

Jump to solution

Hi Wiston,

 

You can do this by two methods

Method1:

1. Download same kernel tag from repository

2. modify your changes and create patch using git

3. follow the steps mentioned in this link :http://www.wiki.xilinx.com/PetaLinux+Yocto+Tips section "Patching the Linux Kernel of a PetaLinux Project "

4. petalinux-build

 

 

Method 2:

You can build kernel as External kernel source option

Build steps for External source using petalinux:
1. petalinux-config and go to -> Linux Components Selection ---> linux-kernel (ext-local-src)
External linux-kernel local source settings --->/aravind_working_dir/source_code/my_xlnx (EXternal linux-kernel local source path)

2. Go to -> Auto Config Settings and select Specify a manual device tree include directory and enter the path to the new kernel include directory.

Auto Config Settings ---> [*] Specify a manual device tree include directory
(/aravind_working_dir/source_code/my_xlnx/arch/arm64/boot/dts/include) Manual device tree include directory

3. Save and exit petalinux-config

4. Do a petalinux-build

 

 

Thanks & regards

Aravind

 

----------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
----------------------------------------------------------------------------------------------

 

0 Kudos
Observer winston
Observer
709 Views
Registered: ‎06-06-2018

Re: How to build modified kernel

Jump to solution
Hi aravindb,
Thanks for give this information this is very much helpful for me. And I solved this problem.

Regards
Winston
0 Kudos
Visitor charlie0611
Visitor
463 Views
Registered: ‎08-02-2018

Re: How to build modified kernel

Jump to solution

Hi Aravind,

 

Can you give any examples of how to create the external kernel source for Method 2. I'm assuming that I need to checkout a kernel tree, but what about the device tree include directory? How do I create that?

0 Kudos