generic: deny write to uImage.FIT sub-image partitions
Set policy bit to force read-only mode on uImage.FIT filesystem sub-images mapped as block partitions by the FIT partition parser. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
This commit is contained in:
@@ -230,7 +230,7 @@ int parse_fit_partitions(struct parsed_partitions *state, u64 fit_start_sector,
|
||||
strlcat(state->pp_buf, tmp, PAGE_SIZE);
|
||||
|
||||
state->parts[*slot].has_info = true;
|
||||
|
||||
state->parts[*slot].flags |= ADDPART_FLAG_READONLY;
|
||||
if (config_loadables && !strcmp(image_name, config_loadables)) {
|
||||
printk(KERN_DEBUG "FIT: selecting configured loadable \"%s\" to be root filesystem\n", image_name);
|
||||
state->parts[*slot].flags |= ADDPART_FLAG_ROOTDEV;
|
||||
|
||||
Reference in New Issue
Block a user