bootstrap_read_devfs() registers a partition with DEVFS_PARTITION_FIXED. The purpose of this flag is that the partition can't be removed later. Removing the partition is exactly what bootstrap_read_devfs() does when finished, so remove the DEVFS_PARTITION_FIXED flag which doesn't make sense here. Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> --- lib/bootstrap/devfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/bootstrap/devfs.c b/lib/bootstrap/devfs.c index 603e6744f2..3d5b1278fb 100644 --- a/lib/bootstrap/devfs.c +++ b/lib/bootstrap/devfs.c @@ -88,8 +88,7 @@ void* bootstrap_read_devfs(char *devname, bool use_bb, int offset, struct cdev *cdev, *partition; char *partname = "x"; - partition = devfs_add_partition(devname, offset, max_size, - DEVFS_PARTITION_FIXED, partname); + partition = devfs_add_partition(devname, offset, max_size, partname); if (IS_ERR(partition)) { bootstrap_err("%s: failed to add partition (%ld)\n", devname, PTR_ERR(partition)); -- 2.39.2