<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/scripts/lib/wic, branch zeus-next2</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=zeus-next2</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=zeus-next2'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2020-01-28T11:51:03+00:00</updated>
<entry>
<title>wic/filemap: If FIGETBSZ iotctl fail, failback to os.stat</title>
<updated>2020-01-28T11:51:03+00:00</updated>
<author>
<name>Kalle Lampila</name>
<email>kalle.lampila@lempea.com</email>
</author>
<published>2019-12-31T15:10:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=88448accde35fc6ffd39091617acb904cfbae6d1'/>
<id>urn:sha1:88448accde35fc6ffd39091617acb904cfbae6d1</id>
<content type='text'>
Some file systems don't support fetching the block size (notably the
file system Docker uses for containers), so if iotctl() fail, try to use
failback via os.stat() to get block size.

(From OE-Core rev: 996013b4e5d3cd1c054e87539ac1a8d95581a87f)

Signed-off-by: Kalle lampila &lt;kalle.lampila@lempea.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit e219f5175177a640dd62833082ea19adc1c13d42)
Signed-off-by: Armin Kuster &lt;akuster808@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic/engine: use 'linux-swap' for swap file system</title>
<updated>2019-10-29T09:08:18+00:00</updated>
<author>
<name>Chee Yang Lee</name>
<email>chee.yang.lee@intel.com</email>
</author>
<published>2019-10-22T05:27:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b3d7793ccd90c724db2c96016956102907b9e89f'/>
<id>urn:sha1:b3d7793ccd90c724db2c96016956102907b9e89f</id>
<content type='text'>
[YOCTO #13312]
see https://bugzilla.yoctoproject.org/show_bug.cgi?id=13312

wic/engine.Disk._get_part_image was looking at variable fstypes for
supported fstype which is 'swap' but image build with 'linux-swap'.
supported fstype should be 'linux-swap'.

(From OE-Core rev: 759a37e315d72e462a617f1cda326b8f198e3d4e)

Signed-off-by: Chee Yang Lee &lt;chee.yang.lee@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 7e6da22fe4faf841bcec02e55f376b4dae04d6a8)
Signed-off-by: Armin Kuster &lt;akuster808@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic/rawcopy: Support files in sub-directories</title>
<updated>2019-10-29T09:08:17+00:00</updated>
<author>
<name>Eugene Smirnov</name>
<email>eu.smirnoff@gmail.com</email>
</author>
<published>2019-10-18T11:16:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=6fb5afb65de3a2f94d705e93ebdbc1f46299e885'/>
<id>urn:sha1:6fb5afb65de3a2f94d705e93ebdbc1f46299e885</id>
<content type='text'>
If the source file is located in a subdirectory of DEPLOY_DIR
rawcopy will currently fail in sparse_copy function on
open(dst_fname, 'wb'), as the parent directory for destination
file does not exist.

This patch helps to avoid that by recursively creating
parent directories.

(From OE-Core rev: 03796926046e5b5b57349d66de6bb009a34d2cb2)

Signed-off-by: Eugene Smirnov &lt;evgenii.smirnov@here.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 073c435644091c2801e45c6d02afa917de575082)
Signed-off-by: Armin Kuster &lt;akuster808@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic/direct: Partition numbering is broken for MBR primary partition #4</title>
<updated>2019-10-08T10:22:24+00:00</updated>
<author>
<name>Michael Cooper</name>
<email>michaelcooper81@gmail.com</email>
</author>
<published>2019-10-03T15:36:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=7a1d68d136c9746242d2243c7e9959758437a3fa'/>
<id>urn:sha1:7a1d68d136c9746242d2243c7e9959758437a3fa</id>
<content type='text'>
When wks describes extra partitions that aren't in the partition
table (e.g. boot loader) and exactly four primary MBR partitions, the
last partition gets added to fstab as partition #5 instead of #4.

[YOCTO #13560]

(From OE-Core rev: 7537580b3dd21bd512fb26e56e92b6553c549fa8)

Signed-off-by: Michael Cooper &lt;michaelcooper81@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic: Using the right rootfs size during prepare_rootfs</title>
<updated>2019-09-27T12:02:16+00:00</updated>
<author>
<name>Alessio Igor Bogani</name>
<email>alessio.bogani@elettra.eu</email>
</author>
<published>2019-09-26T09:35:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b404c0cd3c12958e705f666c29920816912c2d56'/>
<id>urn:sha1:b404c0cd3c12958e705f666c29920816912c2d56</id>
<content type='text'>
The commit 8e48b4d6c4 makes wic ignores IMAGE_ROOTFS_SIZE for rootfs
size and makes it uses the computed one only. Re-add support for
IMAGE_ROOTFS_SIZE variable and compute roots size only if the former
is not defined. Moreover the size of a provided directory with
--rootfs-dir="" in the .wks file should always be computed on the fly,
else every partition will be constrained to be the same size as what
ever value was in ROOTFS_SIZE.

(From OE-Core rev: 0217a0392b8cc534fcc0d760b7663a1845b306f5)

Signed-off-by: Alessio Igor Bogani &lt;alessio.bogani@elettra.eu&gt;
Signed-off-by: Jason Wessel &lt;jason.wessel@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>qemuriscv: Generate a wic rootFS with a larger filesystem</title>
<updated>2019-09-03T08:55:50+00:00</updated>
<author>
<name>Alistair Francis</name>
<email>alistair.francis@wdc.com</email>
</author>
<published>2019-08-30T15:41:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b8c25750029cbc560bcaa00717a6895216b9cb81'/>
<id>urn:sha1:b8c25750029cbc560bcaa00717a6895216b9cb81</id>
<content type='text'>
This allows us to generate a rootFS with a large filesystem for use with
QEMU.

(From OE-Core rev: e06439200e44999c1e2f88d7d6c651da13698ca7)

Signed-off-by: Alistair Francis &lt;alistair.francis@wdc.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic: Make disk partition size consistently computed</title>
<updated>2019-08-12T15:23:57+00:00</updated>
<author>
<name>Jason Wessel</name>
<email>jason.wessel@windriver.com</email>
</author>
<published>2019-08-08T20:23:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=7365a605ae5aa1207a9a06604c8189cd422ac604'/>
<id>urn:sha1:7365a605ae5aa1207a9a06604c8189cd422ac604</id>
<content type='text'>
When using different root directories with a wks file wic is using the
value from the original ROOTFS_SIZE which is not correct.  Example:

Number  Start   End     Size    File system  Name       Flags
 1      20.5kB  318MB   318MB   fat16        otaefi     legacy_boot, msftdata
 2      318MB   636MB   318MB   ext4         otaboot
 3      636MB   1709MB  1074MB  ext4         otaroot
 4      1709MB  2027MB  318MB   ext4         otaboot_b
 5      2027MB  3101MB  1074MB  ext4         otaroot_b
 6      3101MB  5249MB  2147MB  ext4         fluxdata

The partitions 1, 2, and 3 incorrectly inherit the size, instead of using
a computed size.  With the patch applied it is working properly:

Number  Start   End     Size    File system  Name       Flags
 1      20.5kB  14.5MB  14.5MB  fat16        otaefi     legacy_boot, msftdata
 2      14.5MB  65.3MB  50.8MB  ext4         otaboot
 3      65.3MB  1139MB  1074MB  ext4         otaroot
 4      1139MB  1190MB  50.8MB  ext4         otaboot_b
 5      1190MB  2264MB  1074MB  ext4         otaroot_b
 6      2264MB  4411MB  2147MB  ext4         fluxdata

As for the removal of the bb.warn, if the size is not specified, it is
not something to warn the end user about.  Some of my default images
make use of the head room + a computed directory size or while generating
images.

(From OE-Core rev: 8e48b4d6c4d0ed213089a7449fea63aa0656e786)

Signed-off-by: Jason Wessel &lt;jason.wessel@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic: Add partition type for msdos partition tables</title>
<updated>2019-08-12T15:23:57+00:00</updated>
<author>
<name>Jason Wessel</name>
<email>jason.wessel@windriver.com</email>
</author>
<published>2019-08-08T20:23:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=351a10ccd6f197ff105b207ea25d936c3e12044d'/>
<id>urn:sha1:351a10ccd6f197ff105b207ea25d936c3e12044d</id>
<content type='text'>
In order to create a msdos partition table disk image that can auto
expand after the image is copied to an SD card, wic needs the ability
to have a primary partition as the last entry.  The desired use case
is to be able to create an A/B update partition image scheme with a
/var volume that can be auto expanded to the remainder of the SD card
at run time.

The typical .wks file will look similar to the following:

bootloader --ptable msdos
part / --source rawcopy --sourceparams="file=u-boot.imx" \
   --ondisk mmcblk --no-table --align 1 --size 1
part /boot --source bootimg-partition \
   --ondisk mmcblk --fstype=vfat --label boot --active --align 4 --size 16
part / --source rawcopy --sourceparams="file=imx6_boot.otaimg" \
   --ondisk mmcblk --fstype=ext4 --label otaboot --align 4 --type logical
part / --source rawcopy --sourceparams="file=imx6.otaimg" \
   --ondisk mmcblk --fstype=ext4 --label otaroot --align 4 --type logical
part / --source rawcopy --sourceparams="file=imx6_boot.otaimg" \
   --ondisk mmcblk --fstype=ext4 --label otaboot_b --align 4 --type logical
part / --source rawcopy --sourceparams="file=imx6.otaimg" \
   --ondisk mmcblk --fstype=ext4 --label otaroot_b --align 4 --type logical
part /var --source rawcopy --sourceparams="file=imx6_var.otaimg" \
    --ondisk mmcblk --fstype=ext4 --label fluxdata --align 4

Without the patch applied, wic will generate an SD card image that looks like:

Disk boot.img: 890940s
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags:

Number  Start    End      Size     Type      File system  Flags
 1      2056s    48001s   45946s   primary   fat16        lba
 2      48008s   132467s  84460s   primary   ext4
 3      132472s  454467s  321996s  primary   ext4
 4      454471s  890939s  436469s  extended               lba
 5      454472s  538931s  84460s   logical   ext4
 6      538936s  860931s  321996s  logical   ext4
 7      860936s  890939s  30004s   logical   ext4         boot

With the patch applied a primary partition can be created at the end
of the image which can be expanded to fill the free space on the media
where the image has been copied, which looks like:

Disk boot.img: 890940s
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags:

Number  Start    End      Size     Type      File system  Flags
 1      2056s    48001s   45946s   primary   fat16        lba
 2      48007s   860931s  812925s  extended               lba
 5      48008s   132467s  84460s   logical   ext4
 6      132472s  454467s  321996s  logical   ext4
 7      454472s  538931s  84460s   logical   ext4
 8      538936s  860931s  321996s  logical   ext4
 3      860936s  890939s  30004s   primary   ext4         boot

(From OE-Core rev: 56add7cc547e0113cdf980579d1421b14cc233e5)

Signed-off-by: Jason Wessel &lt;jason.wessel@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic/plugins: Source that support both EFI and BIOS</title>
<updated>2019-07-23T21:26:28+00:00</updated>
<author>
<name>William Bourque</name>
<email>wbourque@gmail.com</email>
</author>
<published>2019-07-22T20:11:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=def9b64e27974e3bcf0356e76a8d0aa8f01cdc5c'/>
<id>urn:sha1:def9b64e27974e3bcf0356e76a8d0aa8f01cdc5c</id>
<content type='text'>
Add a source plugin that support both EFI and legacy PC-Bios.
While using this plugin, both bootloaders configurations reside
in the same /boot partitions.
This plugin has very little code : to avoid code duplication,
we simply re-import bootimg-pcbios and bootmg-efi source and
call both their SourcePlugin methods.

(From OE-Core rev: c8545d54139c6c48bffd1dd1d39d79891626c6f7)

Signed-off-by: William Bourque &lt;wbourque@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>wic: Fix (again) partition files UIDs on multi rootfs images</title>
<updated>2019-07-19T07:41:40+00:00</updated>
<author>
<name>Ricardo Ribalda Delgado</name>
<email>ricardo@ribalda.com</email>
</author>
<published>2019-07-18T13:13:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=58589bc5382b5c77825bc963a1c84a4e8f54498f'/>
<id>urn:sha1:58589bc5382b5c77825bc963a1c84a4e8f54498f</id>
<content type='text'>
Commit 450335ba5e73a375eb9932b4c4cf37979640dbfc copies the pseudo
database to the working directory in order to have ownership information
when the filesystem is generated.

Unfortunately this does not work anymore. The filenames on the database
are absolute and there is no information about the new directory.

Instead of fixing the database, we could redo a bit the way we patch the
fstab file. Now I am saving the old contents of fstab, modifying the
file and then reverting the changes on exit.

This is faster than the previous approach, although it can cause
indeterminism if the application is killed before finishing.

(From OE-Core rev: dcbf7b864dd1713b54a172d8714ce1508482f086)

Signed-off-by: Ricardo Ribalda Delgado &lt;ricardo@ribalda.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
