zynq-mpsoc系列之用petalinux生成BOOT.bin文件
来源:互联网 发布:linux 终端快捷键 编辑:程序博客网 时间:2024/05/17 04:00
zynq-mpsoc系列之用petalinux生成zcu102的BOOT.bin文件
作者:卢浩
时间:2017.2.28
转载请注明出处
首先我们来了解一下petalinux-package的用法
Usage:
petalinux-package --boot [options]
Options for boot image package:
-h|--help Display help messages
--force Force overwrite the boot binary image
--format <FORMAT> Avaiable formats:
For Zynq:
* BIN (default): generate BIN file to be put to
Flash or SD for Zynq to boot from it.
For MicroBlaze:
* MCS: generate MCS file
--fsbl <FSBL_ELF> Path to FSBL ELF image location.
For Zynq:
Default is images/linux/zynq_fsbl.elf
For ZynqMP:
Default is images/linux/zynqmp_fsbl.elf
For MicroBlaze:
Default is images/linux/fs-boot.elf
Please use "--fsbl none" for no fsbl if required.
--fpga <BITSTREAM> Path to FPGA bitstream image location
Default is: images/linux/*.bit (The one copied from the HDF)
--atf [<ATF_IMG>] ZynqMP only. Path to ATF
--pmufw [<PMUFW_ELF>] Path to the PMUFW ELF location
Optional and applicable only for ZynqMP.
* path to the PMUFW ELF image
default: <PROJECT>/prebuilt/linux/images/pmufw.elf
* By default, pre-built pmufw is packed without specifying this option.
To skip packing pmufw use --pmufw no
--u-boot [<U_BOOT_IMG>] Path to the u-boot image location.
Not valid for DOWNLOAD.BIT
For Zynq:
* path to the u-boot ELF image
default: <PROJECT>/images/linux/u-boot.elf
For MicroBlaze:
* path to the u-boot-s.bin image
default: <PROJECT>/images/linux/u-boot-s.bin
--kernel [<KERNEL_ING>] Path to the kernel image location
Not valid for DOWNLOAD.BIT
Default: <PROJECT>/images/linux/image.ub
--add <DATA_FILE> Path to the data to add
--offset <OFFSET> offset of previously specified data file, u-boot
, or kernel image.
--bmm <BMM_FILE> Bitstream BMM file. Valid for MicroBlaze only.
It will be used to generate the download.bit with
bootloader in the bram. Default will be the BMM
file in the same directory as the FPGA bitstream.
This is deprecated and an MMI file should be used instead.
--mmi <MMI_FILE> Bitstream MMI file. Valid for MicroBlaze only.
It will be used to generate the download.bit with
bootloader in the bram. Default will be the MMI
file in the same directory as the FPGA bitstream.
--flash-size <FLASH_SIZE> Flash size in MBytes of the PROM device is targeted.
It must be power of 2.
Only valid for MicroBlaze MCS format.
If this value is not specified. It will auto detect
the system flash configured from system config.
If it is parallel flash, it will auto detect flash
size.
If it is SPI flash, the default is 16 Mbytes.
--flash-intf <INTERFACE> Flash interface. Available options:
Only valid for MicroBlaze MCS
* SERIALx1
* SPIx1
* SPIx2
* SPIx4
* BPIx8
* BPIx16
* SMAPx8
* SMAPx16
* SMAPx32
If not specified, it will auto detect the system
flash configured from system config.
If it is parallel flash, it will auto detect flash
width. If it is SPI flash, the default will be SPIx1.
-o, --output <PKGNAME> Generated boot image name
-p, --project <PROJECT> PetaLinux SDK project location.
Default is the working project.
--cpu <DESTINATE CPU> ZynqMP only. destination CPU of the data file
--file-attribute <DATA File ATTR> Zynq/ZynqMP only. data file file-attribute
--bif-attribute <ATTRIBUTE> Zynq/ZynqMP only. name of BIF attribute
--bif-attribute-value <VALUE> Zynq/ZynqMP only. value of the attribute specified by
--attribute argument
--fsblconfig <BIF FSBL CONFIG> Zynq/ZynqMP only. BIF fsbl config value
--bif <BIF> Zynq/ZynqMP only. BIF file. It overrides all
other settings:
--fsbl, --fpga, --u-boot, --add, --fsblconfig,
--file-attribute, --bif-attribute and
--bif-attribute-value.
--boot-device <BOOT_DEV> valid for BIN for Zynq and ZynqMP only.
sd | flash
default will be the one selected from system select menu
of boot image settings
EXAMPLES:
Package BOOT.BIN for ZynqMP:
$ petalinux-package --boot --fsbl <FSBL_ELF> --fpga <BITSTREAM> --u-boot --pmufw <PMUFW_ELF>
It will generate a BOOT.BIN in your working directory with:
* specified <BITSTREAM>
* specified <FSBL_ELF>
* specified < PMUFW_ELF > *
* newly built u-boot image which is <PROJECT>/images/linux/u-boot.elf
petalinux-package --boot [options]
Options for boot image package:
-h|--help Display help messages
--force Force overwrite the boot binary image
--format <FORMAT> Avaiable formats:
For Zynq:
* BIN (default): generate BIN file to be put to
Flash or SD for Zynq to boot from it.
For MicroBlaze:
* MCS: generate MCS file
--fsbl <FSBL_ELF> Path to FSBL ELF image location.
For Zynq:
Default is images/linux/zynq_fsbl.elf
For ZynqMP:
Default is images/linux/zynqmp_fsbl.elf
For MicroBlaze:
Default is images/linux/fs-boot.elf
Please use "--fsbl none" for no fsbl if required.
--fpga <BITSTREAM> Path to FPGA bitstream image location
Default is: images/linux/*.bit (The one copied from the HDF)
--atf [<ATF_IMG>] ZynqMP only. Path to ATF
--pmufw [<PMUFW_ELF>] Path to the PMUFW ELF location
Optional and applicable only for ZynqMP.
* path to the PMUFW ELF image
default: <PROJECT>/prebuilt/linux/images/pmufw.elf
* By default, pre-built pmufw is packed without specifying this option.
To skip packing pmufw use --pmufw no
--u-boot [<U_BOOT_IMG>] Path to the u-boot image location.
Not valid for DOWNLOAD.BIT
For Zynq:
* path to the u-boot ELF image
default: <PROJECT>/images/linux/u-boot.elf
For MicroBlaze:
* path to the u-boot-s.bin image
default: <PROJECT>/images/linux/u-boot-s.bin
--kernel [<KERNEL_ING>] Path to the kernel image location
Not valid for DOWNLOAD.BIT
Default: <PROJECT>/images/linux/image.ub
--add <DATA_FILE> Path to the data to add
--offset <OFFSET> offset of previously specified data file, u-boot
, or kernel image.
--bmm <BMM_FILE> Bitstream BMM file. Valid for MicroBlaze only.
It will be used to generate the download.bit with
bootloader in the bram. Default will be the BMM
file in the same directory as the FPGA bitstream.
This is deprecated and an MMI file should be used instead.
--mmi <MMI_FILE> Bitstream MMI file. Valid for MicroBlaze only.
It will be used to generate the download.bit with
bootloader in the bram. Default will be the MMI
file in the same directory as the FPGA bitstream.
--flash-size <FLASH_SIZE> Flash size in MBytes of the PROM device is targeted.
It must be power of 2.
Only valid for MicroBlaze MCS format.
If this value is not specified. It will auto detect
the system flash configured from system config.
If it is parallel flash, it will auto detect flash
size.
If it is SPI flash, the default is 16 Mbytes.
--flash-intf <INTERFACE> Flash interface. Available options:
Only valid for MicroBlaze MCS
* SERIALx1
* SPIx1
* SPIx2
* SPIx4
* BPIx8
* BPIx16
* SMAPx8
* SMAPx16
* SMAPx32
If not specified, it will auto detect the system
flash configured from system config.
If it is parallel flash, it will auto detect flash
width. If it is SPI flash, the default will be SPIx1.
-o, --output <PKGNAME> Generated boot image name
-p, --project <PROJECT> PetaLinux SDK project location.
Default is the working project.
--cpu <DESTINATE CPU> ZynqMP only. destination CPU of the data file
--file-attribute <DATA File ATTR> Zynq/ZynqMP only. data file file-attribute
--bif-attribute <ATTRIBUTE> Zynq/ZynqMP only. name of BIF attribute
--bif-attribute-value <VALUE> Zynq/ZynqMP only. value of the attribute specified by
--attribute argument
--fsblconfig <BIF FSBL CONFIG> Zynq/ZynqMP only. BIF fsbl config value
--bif <BIF> Zynq/ZynqMP only. BIF file. It overrides all
other settings:
--fsbl, --fpga, --u-boot, --add, --fsblconfig,
--file-attribute, --bif-attribute and
--bif-attribute-value.
--boot-device <BOOT_DEV> valid for BIN for Zynq and ZynqMP only.
sd | flash
default will be the one selected from system select menu
of boot image settings
EXAMPLES:
Package BOOT.BIN for ZynqMP:
$ petalinux-package --boot --fsbl <FSBL_ELF> --fpga <BITSTREAM> --u-boot --pmufw <PMUFW_ELF>
It will generate a BOOT.BIN in your working directory with:
* specified <BITSTREAM>
* specified <FSBL_ELF>
* specified < PMUFW_ELF > *
* newly built u-boot image which is <PROJECT>/images/linux/u-boot.elf
首先我来介绍生成一个简单的BOOT.bin文件,包含fsbl,u-boot.elf,bl31.elf;
输入如下命令:
$ petalinux-package --boot --fsbl images/linux/zynqmp_fsbl.elf --u-boot=images/linux/u-boot.elf --pmufw no --atf --force
下面是输入命令之后的打印信息:
INFO: File in BOOT BIN: "/home/luhao/xilinx/peta_project/xilinx-zcu102-2016.4/images/linux/zynqmp_fsbl.elf"
INFO: File in BOOT BIN: "/home/luhao/xilinx/peta_project/xilinx-zcu102-2016.4/images/linux/bl31.elf"
INFO: File in BOOT BIN: "/home/luhao/xilinx/peta_project/xilinx-zcu102-2016.4/images/linux/u-boot.elf"
INFO: Generating zynq binary package BOOT.BIN...
INFO: Binary is ready.
INFO: File in BOOT BIN: "/home/luhao/xilinx/peta_project/xilinx-zcu102-2016.4/images/linux/zynqmp_fsbl.elf"
INFO: File in BOOT BIN: "/home/luhao/xilinx/peta_project/xilinx-zcu102-2016.4/images/linux/bl31.elf"
INFO: File in BOOT BIN: "/home/luhao/xilinx/peta_project/xilinx-zcu102-2016.4/images/linux/u-boot.elf"
INFO: Generating zynq binary package BOOT.BIN...
INFO: Binary is ready.
petalinux-package --boot 用来生成一个BOOT.bin目标文件;
--fsbl images/linux/zynqmp_fsbl.elf 代表着fsbl的路径;
--u-boot=images/linux/u-boot.elf 代表着u-boot.elf的路径;
--pmufw no 表示禁用pmufw,如果不加no,默认路径就是image/linux/pmufw.elf;
--force是覆盖之前生成的BOOT.bin文件;
bl31.elf是atf文件,arm加密固件;
如果需要加入bit文件,请加入如下选项
--fpga images/linux/design_1_wrapper.bit
0 0
- zynq-mpsoc系列之用petalinux生成BOOT.bin文件
- zynq-mpsoc系列之相关启动文件的讲解
- zynq-mpsoc系列之千兆以太网的性能测试
- zynq学习笔记三:生成BOOT.BIN
- zynq-mpsoc系列之zcu102的linux完整启动log信息
- zynq之petalinux安装和编译
- Zynq UltraScale+ MPSoC
- ZYNQ跑系统 系列(二) petalinux方式移植linux
- MPSOC之2——ubuntu环境配置及petalinux安装
- zynq 之u-boot
- Xilinx ZYNQ-7z020 Platform 生成boot.bin自动从SPI Flash加载程序
- Zynq UltraScale+ MPSoC新鲜出炉
- zynq petalinux userspace IO
- [zynq] zynq7000开发流程之Petalinux (linux开发)
- Zynq-Linux移植学习笔记之九-petalinux
- zynq-7000学习笔记(五)——制作BOOT.bin文件
- zynq-7000学习笔记(五)——制作BOOT.bin文件
- zynq虐我千百遍——第1篇 Linaro之BOOT.bin
- mysql安装,mysql远程登录
- jQuery遍历
- c++指针实例说明
- 基于Angluar ui-router的权限管理
- linux 文件操作
- zynq-mpsoc系列之用petalinux生成BOOT.bin文件
- 转载--认识迅雷界面引擎
- 皮尔逊相关系数的计算(python代码版)
- 第七章 参数估计与假设检验
- 转义字符 通用字符名 字符char wchar_t
- 文件IO操作之文件锁fcntl()函数
- Spring中的事件监听机制在项目中的应用
- hdu 1059最小公倍数模板
- 1043. Is It a Binary Search Tree