Skip to content

The split NOR layout for every board whose kernel has it; no fixed-slot package - #265

Merged
openipc-ai merged 1 commit into
masterfrom
split-layout-overflowing-devices
Nov 21, 2026
Merged

openipc-ai merged 1 commit into
masterfrom
split-layout-overflowing-devices

Conversation

@openipc-ai

@openipc-ai openipc-ai commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

The split layout is the NOR layout from here on. This moves every builder board that can boot it, and drops the fixed-slot package everywhere.

Boards

Still on fixed slots, because firmware has no split kernel for them: xm530 (2), s3l (1), ak3918ev300 (1), and the two unbuilt gk7102ca profiles. gk7205v200_rubyfpv_generic is left alone, since #262 deletes it.

Upgrades. customizer.sh keeps writing <device>-nor.tgz into upgrade. sysupgrade turns that into <device>-nor-split.tgz when it exists, and the manifest resolver falls back to nor_split. The last fixed package already on latest/nightly is never deleted by this repo's CI, so a camera whose sysupgrade predates the layout installs that one first and then moves to the split package.

CI: the workflow comments are reworded, which widens this PR to the full matrix. ci-matrix.py --self-test and check-firmware-drift.py --self-test pass.

Verified on ssc338q_wfbng: a local build against #279's kernel, booted in qemu-bench -M ssc338q under the published U-Boot, gives split NOR layout, kernel 0x50000-0x250000, rootfs 0x250000-0xa60000, mounts the split rootfs and reaches login.

@qodo-free-for-open-source-projects

qodo-free-for-open-source-projects Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

PR Summary by Qodo

Enable split NOR packages for five overflowing 8 MB boards

🐞 Bug fix ⚙️ Configuration changes 🕐 10-20 Minutes

Grey Divider

AI Description

• Enable split NOR packaging for five boards whose firmware exceeds fixed flash slots.
• Continue publishing fixed-layout packages when they fit, preserving upgrades for existing
 installations.
• Reuse the split-layout support already selected by these boards’ kernel configurations.
Merge Risk 🟡 Medium

Blast radius 🔴 High 💥 2 capabilities

  • 2 affected capabilities span independent functional scopes: OpenIPC board firmware build-and-upgrade integration, OpenIPC camera firmware upgrade and boot integration.
  • The changed defconfigs select the packaging behavior and the workflow discovers and publishes the resulting archive.
  • These are producer and publication hops of the same board firmware delivery behavior, not separate capabilities.
  • The kernel partition map and upgrade archive are producer/consumer hops in one end-to-end firmware upgrade behavior.
  • They affect bootability and firmware replacement, not independent application features.
Sources

devices/common/br-ext-chip-goke/configs/gk7205v200_wfbng_defconfig[64-64]

BR2_ROOTFS_POST_IMAGE_SCRIPT="$(BR2_EXTERNAL_GENERAL_PATH)/scripts/post-image-split.sh"

devices/gk7202v300_lite_xg521/br-ext-chip-goke/board/gk7205v200/gk7202v300.generic.config[887-892]

CONFIG_MTD=y
CONFIG_MTD_ROOTFS_ROOT_DEV=y
CONFIG_MTD_SPLIT_FIRMWARE=y
CONFIG_MTD_SPLIT_FIRMWARE_NAME="firmware"
CONFIG_MTD_SPLIT_SQUASHFS_ROOT=y
CONFIG_MTD_SPLIT_UIMAGE_FW=y

devices/t21_lite_wansview-q5-1080p/br-ext-chip-ingenic/board/t21/t21.generic.config[596-597]

CONFIG_MTD=y
CONFIG_MTD_SPLIT_LAYOUT=y
Behavioral complexity 🟡 Medium 🧩 Compatibility cases, Interacting branches

  • Before: converted profiles could request a fixed-slot NOR package, while split-capable profiles and sysupgrade naming were handled separately.
  • After: the same board family may produce either a plain NOR archive or a -split archive, and the workflow selects and renames the available result.
  • New correctness condition: the selected post-image layout, archive suffix, bootloader partition expectations, CI publication name, and the camera's stored upgrade URL must agree across old and newly built images.
  • The branch in CI is existing infrastructure, but this PR materially changes which branch is reachable for many profiles.
Sources

devices/common/br-ext-chip-goke/configs/gk7205v200_wfbng_defconfig[64-64]

BR2_ROOTFS_POST_IMAGE_SCRIPT="$(BR2_EXTERNAL_GENERAL_PATH)/scripts/post-image-split.sh"
Potential damage 🔴 High 🩹 Critical loss

  • The plausible worst case is loss of boot and normal firmware-upgrade capability after a wrongly interpreted MTD layout causes an upgrade write to the wrong region.
  • Reverting the source configuration does not repair a device already flashed with the wrong partition interpretation; recovery requires a known-good image and a supported low-level recovery path.
  • This is a concrete firmware capability consequence, not a claim that every consumer of MTD is affected.
  • Potentially recoverable through bootloader, serial, TFTP or external flash recovery if the hardware exposes one; otherwise the device can remain inaccessible.
  • Code rollback alone does not restore damaged flash contents.
Sources

devices/gk7202v300_lite_xg521/br-ext-chip-goke/board/gk7205v200/gk7202v300.generic.config[887-892]

CONFIG_MTD=y
CONFIG_MTD_ROOTFS_ROOT_DEV=y
CONFIG_MTD_SPLIT_FIRMWARE=y
CONFIG_MTD_SPLIT_FIRMWARE_NAME="firmware"
CONFIG_MTD_SPLIT_SQUASHFS_ROOT=y
CONFIG_MTD_SPLIT_UIMAGE_FW=y

devices/t21_lite_wansview-q5-1080p/br-ext-chip-ingenic/board/t21/t21.generic.config[596-597]

CONFIG_MTD=y
CONFIG_MTD_SPLIT_LAYOUT=y
Assessed commit 4fed5b6
Diagram

graph TD
  CFG["Five board configs"] --> SCRIPT["Split image script"] --> SPLIT["Split NOR package"]
  SCRIPT --> CHECK{"Fixed slots fit?"}
  CHECK -->|Yes| FIXED["Fixed NOR package"]
  CHECK -->|No| SPLIT
Loading
High-Level Assessment

Reusing the existing split-image script and optional fixed-package setting is the appropriate approach: these boards already select compatible kernel configurations, and the same configuration is used by comparable boards. Changing partition sizes or adding new packaging logic would duplicate established support.

Files changed (5) +10 / -0

Bug fix (5) +10 / -0
hi3516ev200_lte_defconfigEnable split NOR packaging for hi3516ev200 LTE +2/-0

Enable split NOR packaging for hi3516ev200 LTE

• Selects the split post-image script and enables a fixed-layout compatibility package when it fits. This addresses fixed-slot overflow on the 8 MB board.

devices/common/br-ext-chip-hisilicon/configs/hi3516ev200_lte_defconfig

hi3516ev300_lte_defconfigEnable split NOR packaging for hi3516ev300 LTE +2/-0

Enable split NOR packaging for hi3516ev300 LTE

• Selects the split post-image script and enables a fixed-layout compatibility package when it fits. This addresses fixed-slot overflow on the 8 MB board.

devices/common/br-ext-chip-hisilicon/configs/hi3516ev300_lte_defconfig

gk7202v300_lite_generic-w7_defconfigEnable split NOR packaging for gk7202v300 generic-w7 +2/-0

Enable split NOR packaging for gk7202v300 generic-w7

• Selects the split post-image script and enables a fixed-layout compatibility package when it fits. This addresses fixed-slot overflow on the 8 MB board.

devices/gk7202v300_lite_generic-w7/br-ext-chip-goke/configs/gk7202v300_lite_generic-w7_defconfig

t31_lite_chinatelecom-y4h-50_defconfigEnable split NOR packaging for t31 Chinatelecom Y4H-50 +2/-0

Enable split NOR packaging for t31 Chinatelecom Y4H-50

• Selects the split post-image script and enables a fixed-layout compatibility package when it fits. This addresses fixed-slot overflow on the 8 MB board.

devices/t31_lite_chinatelecom-y4h-50/br-ext-chip-ingenic/configs/t31_lite_chinatelecom-y4h-50_defconfig

t31_lite_tp-link-tapo-tc70-v3_defconfigEnable split NOR packaging for t31 Tapo TC70 v3 +2/-0

Enable split NOR packaging for t31 Tapo TC70 v3

• Selects the split post-image script and enables a fixed-layout compatibility package when it fits. This addresses fixed-slot overflow on the 8 MB board.

devices/t31_lite_tp-link-tapo-tc70-v3/br-ext-chip-ingenic/configs/t31_lite_tp-link-tapo-tc70-v3_defconfig

@qodo-free-for-open-source-projects

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Tip of the day
💡 Did you know, you can add REVIEW.md to your repo root and Qodo follows it on every PR

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

…ot package

The split layout is the NOR layout from here on. Every builder board whose
SoC family has a split kernel now builds firmware.bin and ships only
<device>-nor-split.tgz:

- 78 boards on fixed slots gain post-image-split.sh; nine of them carry their
  own kernel config, which now has firmware's mtdsplit options
  (CONFIG_MTD_SPLIT_LAYOUT on Ingenic, the MTD_SPLIT_FIRMWARE set on
  HiSilicon and Goke).
- the 18 infinity6e boards (ssc338q, ssc30kq, ssc30kd) too, on the kernel
  support OpenIPC/linux and OpenIPC/firmware add for that family.
- BR2_OPENIPC_NOR_FIXED_PACKAGE goes from all 48 defconfigs that had it.

sysupgrade turns the <device>-nor.tgz URL customizer.sh writes into
<device>-nor-split.tgz itself, and the manifest falls back to the split
package, so neither needs the fixed one. The last fixed package stays in the
release as the bridge for cameras whose sysupgrade predates the layout.

Still fixed, as firmware has no split kernel for them: xm530, s3l,
ak3918ev300, and the two unbuilt gk7102ca profiles.
@openipc-ai
openipc-ai force-pushed the split-layout-overflowing-devices branch from a7eea54 to 4fed5b6 Compare November 21, 2026 06:06
@openipc-ai openipc-ai changed the title Five 8 MB boards that outgrew their fixed slots: the split NOR layout The split NOR layout for every board whose kernel has it; no fixed-slot package Nov 21, 2026
@openipc-ai
openipc-ai merged commit 068ed05 into master Nov 21, 2026
272 of 291 checks passed
@openipc-ai
openipc-ai deleted the split-layout-overflowing-devices branch November 21, 2026 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant