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!

如何取得petalinux中u-boot和linux的source code

回复
Visitor
发帖数: 1
注册日期: ‎05-16-2018

如何取得petalinux中u-boot和linux的source code

[ 已编辑 ]

我們已利用petalinux提供的tool將u-boot及linux kernel images產生出來

alex@alex-H110M-S2PH:~/enet7035-20170828-hdf$ ls
build  components  config.project  images  plnx.sh  project-spec

alex@alex-H110M-S2PH:~/enet7035-20170828-hdf$ cd images/linux

alex@alex-H110M-S2PH:~/enet7035-20170828-hdf/images/linux$ ls
BOOT.BIN       image.ub     rootfs.cpio.gz  system.dtb        u-boot.bin  vmlinux  zynq_fsbl.elf
enet_bist.bit  rootfs.cpio  rootfs.jffs2    System.map.linux  u-boot.elf  zImage

請問如何取得這些image的原始碼?

Highlighted
Xilinx Employee
发帖数: 55
注册日期: ‎02-16-2012

回复: 如何取得petalinux中u-boot和linux的source code

2.1 Add the following two lines to project-spec\meta-user\conf\etalinux_bsp.conf
RM_WORK_EXCLUDE += "linux-xlnx"
RM_WORK_EXCLUDE += "u-boot-xlnx"

2.2 屏蔽build/conf/local.conf下的下列行
INHERIT += "rm_work"

变为
#INHERIT += "rm_work"

2.3: U-Boot source code directory:
/build/tmp/work/plnx_aarch64-xilinx-linux/u-boot-xlnx/v2017.01-xilinx-v2017.2+gitAUTOINC+5290eb544b-r0/git

2.4: U-Boot config file:
build/tmp/work/plnx_aarch64-xilinx-linux/u-boot-xlnx/v2017.01-xilinx-v2017.2+gitAUTOINC+5290eb544b-r0/build

2.5:
copy U-Boot config file to U-Boot source code directory, then compilation is done successully.

2.6: Linux source code directory:
build/tmp/work-shared/plnx_aarch64/kernel-source

2.7: Linux config file:
build/tmp/work/plnx_aarch64-xilinx-linux/linux-xlnx/4.9-xilinx-v2017.2+gitAUTOINC+5d029fdc25-r0/linux-plnx_aarch64-standard-build/.config

2.8:
copy Linux config file 5.1 to Linux source code directory, then compilation is done successully.

Visitor
发帖数: 6
注册日期: ‎01-07-2016

回复: 如何取得petalinux中u-boot和linux的source code

U-Boot就在Xilinx原厂得Github上啦

 

参考 github.com/xilinx 就好

 

 

Best Regards
Luke Liu (刘振宇)
Xilinx Employee
发帖数: 40
注册日期: ‎03-27-2013

回复: 如何取得petalinux中u-boot和linux的source code

前面两位说的都对,我补充下,如果要在PetaLinux下自己管理Linux和u-boot的source code。

可以尝试使用UG1144中的Configuring Out-of-tree Build章节的配置,选择ext-local-src,自己指定source的路径。

在指定路径下下载并管理的source code,PetaLinux编译就会使用该目录下的source code

Best Regards,
Jason
-----------------------------------------------------------------------------------------------
Please mark the Answer as "Accept as solution" if the information provided is helpful.

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