All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-rockchip][PATCH v4 1/5] rockchip.wks: specify offsets in sectors
@ 2024-02-22 17:04 Trevor Woerner
  2024-02-22 17:04 ` [meta-rockchip][PATCH v4 2/5] rockchip.wks: specify fstype Trevor Woerner
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Trevor Woerner @ 2024-02-22 17:04 UTC (permalink / raw)
  To: yocto; +Cc: Quentin Schulz

In WIC, size arguments can be optionally specified using one of a variety
of suffixes (e.g. K, M, G, etc.) thanks to sizetype(). One such suffix being
"s/S" for handling sector sizes which are assumed to be 512 bytes, rather than
the other size suffixes which are multiples of 1024 bytes.

Using the s/S sizetype allows the definition to match the documentation.
Unfortunately we can not use the s/S suffix for --fixed-size.

Reviewed-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>
Signed-off-by: Trevor Woerner <twoerner@gmail.com>
---
changes in v4:
- add Quentin's tag

changes in v3:
- new
---
 wic/rockchip.wks | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/wic/rockchip.wks b/wic/rockchip.wks
index fac0b8f70112..804e84ceb316 100644
--- a/wic/rockchip.wks
+++ b/wic/rockchip.wks
@@ -5,8 +5,7 @@
 # short-description: Create a disk image suitable for booting Rockchip from SD-card
 # long-description: Creates a disk image partitioned using GPT, suitable for Rockchip
 # Disk layout
-# Note that the reference documentation refers to 512 byte disk sectors, but
-# wic uses 1KB blocks. The following table uses 512 byte sectors:
+# See: https://opensource.rock-chips.com/wiki_Partitions
 #
 #   Partition   Start Sector    Number of Sectors
 #   loader1     64              8000        (idbloader / U-Boot SPL)
@@ -17,12 +16,12 @@
 #   boot        32768           229376
 #   root        262144          -           (suggested)
 
-part loader1    --offset 32     --fixed-size 4000K            --source rawcopy                                                 --sourceparams="file=${SPL_BINARY}"
-part reserved1  --offset 4032   --fixed-size 64K
-part reserved2  --offset 4096   --fixed-size 4096K
-part loader2    --offset 8192   --fixed-size 4096K            --source rawcopy                                                 --sourceparams="file=u-boot.${UBOOT_SUFFIX}"
-part atf        --offset 12288  --fixed-size 4096K
-part /boot      --offset 16384  --size       114688K --active --source bootimg-partition --fstype=vfat --label boot --use-uuid --sourceparams="loader=u-boot"
+part loader1    --offset 64s    --fixed-size 4000K            --source rawcopy                                                 --sourceparams="file=${SPL_BINARY}"
+part reserved1  --offset 8064s  --fixed-size 64K
+part reserved2  --offset 8192s  --fixed-size 4096K
+part loader2    --offset 16384s --fixed-size 4096K            --source rawcopy                                                 --sourceparams="file=u-boot.${UBOOT_SUFFIX}"
+part atf        --offset 24576s --fixed-size 4096K
+part /boot      --offset 32768s --size       114688K --active --source bootimg-partition --fstype=vfat --label boot --use-uuid --sourceparams="loader=u-boot"
 part /                                                        --source rootfs            --fstype=ext4 --label root --use-uuid
 
 bootloader --ptable gpt --append="console=tty1 console=${RK_CONSOLE_DEVICE},${RK_CONSOLE_BAUD}n8 rw rootfstype=ext4 init=/sbin/init"
-- 
2.43.0.76.g1a87c842ece3



^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-02-26 15:32 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-22 17:04 [meta-rockchip][PATCH v4 1/5] rockchip.wks: specify offsets in sectors Trevor Woerner
2024-02-22 17:04 ` [meta-rockchip][PATCH v4 2/5] rockchip.wks: specify fstype Trevor Woerner
2024-02-22 17:04 ` [meta-rockchip][PATCH v4 3/5] rockchip.wks: add most Rockchip partitions Trevor Woerner
2024-02-22 17:04 ` [meta-rockchip][PATCH v4 4/5] remove /boot partition Trevor Woerner
2024-02-22 17:04 ` [meta-rockchip][PATCH v4 5/5] rockchip.wks: wks file cleanup Trevor Woerner
     [not found] ` <17B63E2C73497FDA.14827@lists.yoctoproject.org>
2024-02-26 15:30   ` [yocto] [meta-rockchip][PATCH v4 2/5] rockchip.wks: specify fstype Trevor Woerner
     [not found] ` <17B63E2D2D80E632.27859@lists.yoctoproject.org>
2024-02-26 15:31   ` [yocto] [meta-rockchip][PATCH v4 3/5] rockchip.wks: add most Rockchip partitions Trevor Woerner
     [not found] ` <17B63E2DD347D0FA.14827@lists.yoctoproject.org>
2024-02-26 15:31   ` [yocto] [meta-rockchip][PATCH v4 4/5] remove /boot partition Trevor Woerner
     [not found] ` <17B63E2E80BDA052.14827@lists.yoctoproject.org>
2024-02-26 15:32   ` [yocto] [meta-rockchip][PATCH v4 5/5] rockchip.wks: wks file cleanup Trevor Woerner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.