From 5432e4a8642c8e844a69eb94105370fcb6b51d86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20=C5=A0tetiar?= Date: Sat, 27 Jun 2026 05:47:35 +0200 Subject: [PATCH] ci: testbed: labgrid: restore lcm_data cleanup dropped by FEAT-29 flow MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The FEAT-29 update_prpl conversion switched both the Freedom (wnc-freedom) and OSPv2 (mxl25641-hdk-6) eMMC flash flows to erase only the rootfs_data overlay, and in doing so dropped the lcm_data partition cleanup that PPW-718 had introduced. The persistent /lcm (lcm_data) partition is not cleared between CI runs, so stale containers from a previous test survive the reboot/flash procedure and make the LCM cram suite non-idempotent. So lets restore the cleanup by erasing the first 0x400 blocks (the eMMC erase-group size, i.e. just the ext4 filesystem metadata, not the whole multi-GiB partition) of lcm_data right after the rootfs_data erase, so every refresh starts from a clean /lcm. The offsets are taken from each board's current prpl Standard Flash Layout GPT, verified live in U-Boot: Freedom (IPQ9574#): 28 0x00134022 0x00534021 "lcm_data" 29 0x00534022 0x00574021 "rootfs_data" OSPv2 (Lightning #): 14 0x00086c00 0x00096bff "rootfs_data" 16 0x000a6c00 0x006a6bff "lcm_data" Fixes: CI-2 References: 78b11d2d5b3d ("ci: testbed: labgrid: flash OSPv2 and Freedom via FEAT-29 update_prpl") References: PPW-718 Assisted-by: claude:opus-4-8:1m-context Signed-off-by: Petr Štetiar --- .testbed/labgrid/default.yaml | 6 ++++-- .testbed/labgrid/testbed-02.yaml | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.testbed/labgrid/default.yaml b/.testbed/labgrid/default.yaml index a4e91c8a72..97c7b1c303 100644 --- a/.testbed/labgrid/default.yaml +++ b/.testbed/labgrid/default.yaml @@ -131,7 +131,8 @@ targets: - setenv img_smd - setenv update_rescue_bank yes - mmc dev 0 - - mmc erase 0x534022 0x40000 + - mmc erase 0x534022 0x40000 # rootfs_data + - mmc erase 0x134022 0x400 # lcm_data - run update_prpl boot_command: run bootcmd UBootStrategy: {} @@ -173,7 +174,8 @@ targets: - setenv img_smd - setenv update_rescue_bank yes - mmc dev 0 - - mmc erase 0x86c00 0x10000 + - mmc erase 0x86c00 0x10000 # rootfs_data + - mmc erase 0xa6c00 0x400 # lcm_data - run update_prpl boot_command: run bootcmd UBootStrategy: {} diff --git a/.testbed/labgrid/testbed-02.yaml b/.testbed/labgrid/testbed-02.yaml index 10977f704a..d625ba0b1b 100644 --- a/.testbed/labgrid/testbed-02.yaml +++ b/.testbed/labgrid/testbed-02.yaml @@ -165,7 +165,8 @@ targets: - setenv img_smd - setenv update_rescue_bank yes - mmc dev 0 - - mmc erase 0x534022 0x40000 + - mmc erase 0x534022 0x40000 # rootfs_data + - mmc erase 0x134022 0x400 # lcm_data - run update_prpl boot_command: run bootcmd UBootStrategy: {} @@ -207,7 +208,8 @@ targets: - setenv img_smd - setenv update_rescue_bank yes - mmc dev 0 - - mmc erase 0x86c00 0x10000 + - mmc erase 0x86c00 0x10000 # rootfs_data + - mmc erase 0xa6c00 0x400 # lcm_data - run update_prpl boot_command: run bootcmd UBootStrategy: {}