Repository navigation
hi3516ev200, hi3518ev300, hi3516dv200: the split NOR image, as on gk7205v200 - #2655
Conversation
…205v200 Their lite images sit within a few KiB of the fixed slots (rootfs 5084K, 5112K and 4808K of 5120K). The split layout lets kernel and rootfs share one budget. Lite and ultimate use general/scripts/post-image-split.sh with BR2_OPENIPC_NOR_FIXED_PACKAGE=y: the fixed-slot package as before, plus -split. The kernel configs turn on MTD_SPLIT_FIRMWARE (named "firmware"), MTD_SPLIT_UIMAGE_FW, MTD_SPLIT_SQUASHFS_ROOT and MTD_ROOTFS_ROOT_DEV (OpenIPC/linux#131; their U-Boot scans for it since OpenIPC/u-boot#48). Makefile: the split branch closed only after the UBI and initramfs packaging, so a NOR+NAND build (ultimate, BR2_TARGET_ROOTFS_UBI) shipping firmware.bin lost its NAND package. Those now run whichever NOR layout the build ships. No split board had a UBI rootfs before. hi3516ev300 is left as it is: its uImage is 2009K with the split options, over the 1983K a fixed-slot package beside a split one may use (a uImage ending in the slot's last block reads as split). It needs a smaller kernel, or to ship -split only, first. neo, dev and glibc are unchanged. Built locally with the kernel branch: - hi3516ev200_lite: uImage 1785K/1983K, squashfs 5084K/5120K, firmware.bin 6912K/7616K; -lite.tgz and -lite-split.tgz. - hi3516ev200_ultimate: firmware.bin 9024K/15808K, rootfs.ubi 16256K/24576K; nand-ultimate (fitImage, rootfs.ubifs, rootfs.ubi, as on latest), nor-ultimate and nor-ultimate-split. - hi3518ev300_lite: uImage 1877K, squashfs 5112K, firmware.bin 7040K. Tested in qemu-hisilicon (hi3516ev200, hi3518ev300; 8 and 16 MB): - the split firmware.bin under the new U-Boot: "Found RootFS at 0x00210000", root-less command line, "hi_sfc: split NOR layout, device tree partitions", root on 31:4; /init's overlay marker on rootfs_data kept across a reset; - the same under the published u-boot-hi3516ev200-nor.bin: its fixed mtdparts and root=/dev/mtdblock3 ignored, the same split; - the fixed-slot package (8 MB lite, 16 MB ultimate at 0x350000) under both: the command line's partitions, root on 31:3. Not run on hardware.
PR Summary by QodoAdd split NOR packages for three HiSilicon SoCs
AI Description
Diagram
High-Level Assessment
Files changed (9)
|
Code Review by Qodo
1. Camera boot behavior lacks hardware proof
|
…dv200 (#160) Their firmware now ships the split NOR package beside the fixed-slot one (OpenIPC/firmware#2655, on OpenIPC/linux#131), and their OpenIPC/u-boot NOR build scans for it (OpenIPC/u-boot#48), so they join `NOR_SPLIT_SOCS`: one `firmware.bin.<soc>` at 0x50000, the rest of the chip erased. They already take `u-boot-<soc>-nor.bin` (`PER_FLASH_TYPE_UBOOT`). hi3516ev300 stays on fixed slots: its uImage (2009K with the split options) fills the 2 MiB slot, over the 1983K a fixed-slot package beside a split one may use, so its firmware ships no split package. A test keeps it out even though its profile is an alias of hi3516ev200. The split package appears with the next nightly. Until the U-Boot publish workflow runs again, the published `u-boot-<soc>-nor.bin` predates #48: the split image still boots under it (the kernel ignores its fixed mtdparts, checked in QEMU), but its scan and `fwupd` for the split image come with the republished build. Not run on hardware; the firmware side was checked in qemu-hisilicon (hi3516ev200, hi3518ev300; 8 and 16 MB). `pytest tests/ --ignore=tests/fuzz`: 1084 passed. ruff and mypy are clean.
* nor-split: the Hi3516EV200 family, Hi3516EV300 split-only - nor-split-layout: Hi3516EV200, Hi3518EV300 and Hi3516DV200 ship the split package beside the fixed-slot one (OpenIPC/firmware#2655, on OpenIPC/linux#131 and OpenIPC/u-boot#48); Hi3516EV300 lite and ultimate ship the split package only, its kernel filling the 2 MiB kernel slot (neo keeps fixed slots). Going back to fixed slots lists them accordingly. - sysupgrade: `sysupgrade -k -r` installs the split layout on them. Checked in qemu-hisilicon (hi3516ev200, hi3518ev300, hi3516ev300; 8 and 16 MB). Not run on hardware. * nor-split: the GK7205V500 family GK7205V500 ships the split package beside the fixed-slot one (OpenIPC/firmware#2658, on OpenIPC/linux#137 and OpenIPC/u-boot#52). GK7205V510 and GK7205V530 install that one gk7205v500 build, as defib (OpenIPC/defib#163) and the site's installer do. Each keeps its own u-boot-<soc>-nor.bin. sysupgrade -k -r takes the split package on them too, and they go back to fixed slots the same way. Checked in qemu-hisilicon (gk7205v500 8 and 16 MB, gk7205v510/v530 16 MB). Not run on hardware. * sysupgrade: the split list is for NOR cameras, and Hi3516EV300 lite and ultimate From review: the list of SoCs whose sysupgrade -k -r installs the split package now says it is about NOR flash, and points NAND cameras to their own layout page. Hi3516EV300 is listed for lite and ultimate only: neo keeps fixed slots, as the layout page says.
Their lite images sit within a few KiB of the fixed slots (rootfs 5084K, 5112K and 4808K of 5120K). The split layout lets kernel and rootfs share one budget.
general/scripts/post-image-split.shwithBR2_OPENIPC_NOR_FIXED_PACKAGE=y: the fixed-slot package as before, plus-split.MTD_SPLIT_FIRMWARE(named "firmware"),MTD_SPLIT_UIMAGE_FW,MTD_SPLIT_SQUASHFS_ROOT,MTD_ROOTFS_ROOT_DEV(hi3516ev200 family: the split NOR layout, from the device tree linux#131). Their U-Boot scans for the layout since nor: split layout on the hi3516ev200 family u-boot#48.BR2_TARGET_ROOTFS_UBI) shippingfirmware.binwould have lost its NAND package. Those now run whichever NOR layout the build ships. No split board had a UBI rootfs before, so nothing published changes.-splitonly, first. neo, dev and glibc are unchanged.Built locally:
-lite.tgzand-lite-split.tgz.Tested in qemu-hisilicon (hi3516ev200, hi3518ev300; 8 and 16 MB):
Found RootFS at 0x00210000, root-less command line,hi_sfc: split NOR layout, device tree partitions, root on 31:4; the overlay marker kept across a reset;u-boot-hi3516ev200-nor.bin: its fixed mtdparts androot=/dev/mtdblock3ignored, the same split;Not run on hardware.