Steps to Configure JFFS2 Boot - 2020.2 English

PetaLinux Tools Documentation Reference Guide (UG1144)

Document ID
Release Date
2020.2 English
  1. Set the root file system type to JFFS2. For more information, see Root File System Type Configuration.
  2. Set Primary Flash as boot device and boot images storage. For more information, see Boot Images Storage Configuration and Primary Flash Partition Configuration.
  3. Build the system image. For more information, see Build System Image.
  4. Boot a PetaLinux Image on hardware with JTAG, see Boot a PetaLinux Image on Hardware with an SD Card.
  5. Make sure you have configured TFTP server in host.
  6. Set the server IP address to the host IP address using the following command at U-Boot prompt.
    ZynqMP> setenv serverip <HOST IP ADDRESS>;
    1. Detect Flash Memory.
      ZynqMP> sf probe 0 0 0
    2. Erase Flash Memory.
      ZynqMP> sf erase 0 0x5000000
    3. Read images onto Memory and write into Flash.
      • Read BOOT.BIN.
        ZynqMP> tftpboot 0x80000 BOOT.BIN
      • Write BOOT.BIN.
        ZynqMP> sf write 0x80000 0 <size of boot.bin>

        Example: sf write 0x80000 0 0x10EF48

      • Read image.ub.
        ZynqMP> tftpboot 0x80000 image.ub
      • Write image.ub.
        ZynqMP>sf write 0x80000 <loading address of kernel> <size of image.ub>

        Example: sf write 0x80000 0x580000 0x6cb0e4

      • Read rootfs.jffs2.
        ZynqMP> tftpboot 0x80000 rootfs.jffs2
      • Write rootfs.jffs2.
        ZynqMP> sf write 0x80000 <loading address of rootfs.jffs2> <size of rootfs.jffs2>

        Example: sf write 0x80000 0x1980000 0x7d4000

      Note: Check loading addresses for kernel and root file system inside system.dts.
      • Read boot.scr
        ZynqMP> tftpboot 0x80000 boot.scr
      • Write boot.scr
        ZynqMP> sf write 0x80000 <loading address of boot.scr> < size of boot.scr>

        Example: sf write 0x80000 0x7F80000 0x80000

        Note: Check the addresses in <plnx-proj-root>/project-spec/meta-user/recipes-bsp/u-boot/u-boot-zynq-scr/boot.cmd.default.initrd. If they do not match, the process may fail in the U-Boot prompt.
  7. Enable QSPI flash boot mode on board.
  8. Reset the board (booting starts from flash).