diff options
Diffstat (limited to 'scripts/lib/wic/plugins/source')
| -rw-r--r-- | scripts/lib/wic/plugins/source/bootimg-efi.py | 7 | ||||
| -rw-r--r-- | scripts/lib/wic/plugins/source/bootimg-pcbios.py | 6 |
2 files changed, 11 insertions, 2 deletions
diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py b/scripts/lib/wic/plugins/source/bootimg-efi.py index 2cfdc10ecd..05e8471116 100644 --- a/scripts/lib/wic/plugins/source/bootimg-efi.py +++ b/scripts/lib/wic/plugins/source/bootimg-efi.py | |||
| @@ -277,6 +277,13 @@ class BootimgEFIPlugin(SourcePlugin): | |||
| 277 | logger.debug("Added %d extra blocks to %s to get to %d total blocks", | 277 | logger.debug("Added %d extra blocks to %s to get to %d total blocks", |
| 278 | extra_blocks, part.mountpoint, blocks) | 278 | extra_blocks, part.mountpoint, blocks) |
| 279 | 279 | ||
| 280 | # required for compatibility with certain devices expecting file system | ||
| 281 | # block count to be equal to partition block count | ||
| 282 | if blocks < part.fixed_size: | ||
| 283 | blocks = part.fixed_size | ||
| 284 | logger.debug("Overriding %s to %d total blocks for compatibility", | ||
| 285 | part.mountpoint, blocks) | ||
| 286 | |||
| 280 | # dosfs image, created by mkdosfs | 287 | # dosfs image, created by mkdosfs |
| 281 | bootimg = "%s/boot.img" % cr_workdir | 288 | bootimg = "%s/boot.img" % cr_workdir |
| 282 | 289 | ||
diff --git a/scripts/lib/wic/plugins/source/bootimg-pcbios.py b/scripts/lib/wic/plugins/source/bootimg-pcbios.py index f2639e7004..32e47f1831 100644 --- a/scripts/lib/wic/plugins/source/bootimg-pcbios.py +++ b/scripts/lib/wic/plugins/source/bootimg-pcbios.py | |||
| @@ -186,8 +186,10 @@ class BootimgPcbiosPlugin(SourcePlugin): | |||
| 186 | # dosfs image, created by mkdosfs | 186 | # dosfs image, created by mkdosfs |
| 187 | bootimg = "%s/boot%s.img" % (cr_workdir, part.lineno) | 187 | bootimg = "%s/boot%s.img" % (cr_workdir, part.lineno) |
| 188 | 188 | ||
| 189 | dosfs_cmd = "mkdosfs -n boot -i %s -S 512 -C %s %d" % \ | 189 | label = part.label if part.label else "boot" |
| 190 | (part.fsuuid, bootimg, blocks) | 190 | |
| 191 | dosfs_cmd = "mkdosfs -n %s -i %s -S 512 -C %s %d" % \ | ||
| 192 | (label, part.fsuuid, bootimg, blocks) | ||
| 191 | exec_native_cmd(dosfs_cmd, native_sysroot) | 193 | exec_native_cmd(dosfs_cmd, native_sysroot) |
| 192 | 194 | ||
| 193 | mcopy_cmd = "mcopy -i %s -s %s/* ::/" % (bootimg, hdddir) | 195 | mcopy_cmd = "mcopy -i %s -s %s/* ::/" % (bootimg, hdddir) |
