Advertisement
paul-lightdeckdx

yocto-wic-issue

May 20th, 2022
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.95 KB | None | 0 0
  1. # The disk layout used is:
  2. #  - -----   ---------------- ------------------ ------ -----------------------------------
  3. # | | SPL | | rootfs-primary | rootfs-secondary | SWAP | data                              |
  4. #  - -----   ---------------- ------------------ ------ -----------------------------------
  5. # ^ ^       ^                ^                  ^      ^                                   ^
  6. # | |       |                |                  |      |                                   |
  7.  
  8. # 0 1kiB      1500M            1500M              1000M  6000M
  9. #
  10.  
  11. # NOTE: yocto adds 30% padding to the partition.
  12. #       So --size and --fixed-size settings must
  13. #       be 1/1.3 of the desired size.
  14. #
  15. # In practical terms, the option to specify this
  16. # padding is --overhead-factor, which defaults to
  17. # 1.3, if not specified.
  18. #
  19. # The specification below does not specify --overhead-factor.
  20. # This means that the 1.5G size of rootfs is actually 1.96G,
  21. # and the 1G size of swap is 1.3G. The entire disk image is
  22. # (1.5G + 1.5G +  1G + 6G)*1.3 = 13G
  23.  
  24. part SPL   --ondisk mmcblk0 --source rawcopy --sourceparams="file=SPL" --no-table --align 1
  25.  
  26. # Setup rootfs to not be fixed-size
  27. part /                 --ondisk mmcblk0 --fixed-size 1500M --align 4096 --label rootfs-primary   --fstype=ext4 --source rootfs --exclude-path=data/
  28. part rootfs-secondary  --ondisk mmcblk0 --fixed-size 1500M --align 4096 --label rootfs-secondary --fstype=ext4 --source rootfs --exclude-path=data/
  29.  
  30. # Use --size instead of --fixed-size for swap as mkswap
  31. # appears to require this option.  This option acts as
  32. # a fixed size and shouldn't be resizeable.
  33. part swap              --ondisk mmcblk0 --size 1000M       --align 4096 --label swap             --fstype=swap
  34.  
  35. # Setup data partition to be variable sized
  36. # to expand/shrink to remaining disk
  37. part /data             --ondisk mmcblk0 --size 6000M       --align 4096 --label data             --fstype=ext4
  38.  
  39. bootloader --ptable msdos
  40.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement