[openwrt/openwrt] bcm53xx: use -ENOENT error for TRX parser workaround patch
LEDE Commits
lede-commits at lists.infradead.org
Sun Nov 9 03:59:13 PST 2025
ansuel pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/231bbe528d3f6ae4a43117b38c41a2f62896ce4e
commit 231bbe528d3f6ae4a43117b38c41a2f62896ce4e
Author: Christian Marangi <ansuelsmth at gmail.com>
AuthorDate: Sun Nov 9 12:55:18 2025 +0100
bcm53xx: use -ENOENT error for TRX parser workaround patch
Change return value from -EINVAL to -ENOENT for the TRX parser
workaround patch as it's better suited and it's the common exit error
for parser failing parsing for expected condition (partition not init,
zero partition found in the schema, magic values not matching)
Also this is needed for a pending upstream patch that will permit parser
to fail and be skipped for subpartitions only with the -ENOENT error.
Signed-off-by: Christian Marangi <ansuelsmth at gmail.com>
---
.../140-mtd-parsers-trx-parse-firmware-MTD-partitions-only.patch | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/linux/bcm53xx/patches-6.6/140-mtd-parsers-trx-parse-firmware-MTD-partitions-only.patch b/target/linux/bcm53xx/patches-6.6/140-mtd-parsers-trx-parse-firmware-MTD-partitions-only.patch
index e1933e75c7..dbf4569b4e 100644
--- a/target/linux/bcm53xx/patches-6.6/140-mtd-parsers-trx-parse-firmware-MTD-partitions-only.patch
+++ b/target/linux/bcm53xx/patches-6.6/140-mtd-parsers-trx-parse-firmware-MTD-partitions-only.patch
@@ -36,7 +36,7 @@ Signed-off-by: Rafał Miłecki <rafal at milecki.pl>
+ /* Don't parse any failsafe / backup partitions */
+ if (strcmp(mtd->name, "firmware"))
-+ return -EINVAL;
++ return -ENOENT;
+
parts = kcalloc(TRX_PARSER_MAX_PARTS, sizeof(struct mtd_partition),
GFP_KERNEL);
More information about the lede-commits
mailing list