From 4288cebfdb57ad76aa280058e2a6cbf8ef2e277d Mon Sep 17 00:00:00 2001 From: Maxim Paymushkin Date: Thu, 27 Mar 2025 15:41:03 +0100 Subject: [PATCH] program: add sparse attribute Signed-off-by: Maxim Paymushkin --- program.c | 1 + program.h | 1 + 2 files changed, 2 insertions(+) diff --git a/program.c b/program.c index 585cf07..e494869 100644 --- a/program.c +++ b/program.c @@ -68,6 +68,7 @@ static int load_program_tag(xmlNode *node, bool is_nand) program->label = attr_as_string(node, "label", &errors); program->num_sectors = attr_as_unsigned(node, "num_partition_sectors", &errors); program->partition = attr_as_unsigned(node, "physical_partition_number", &errors); + program->sparse = attr_as_bool(node, "sparse", &errors); program->start_sector = attr_as_string(node, "start_sector", &errors); if (is_nand) { diff --git a/program.h b/program.h index 773a343..754c46c 100644 --- a/program.h +++ b/program.h @@ -13,6 +13,7 @@ struct program { const char *label; unsigned int num_sectors; unsigned int partition; + bool sparse; const char *start_sector; unsigned int last_sector;