no way to create images with a GPT alignment of 1
Bug #1621151 reported by
Oliver Grawert
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu Image |
Fix Released
|
High
|
Barry Warsaw |
Bug Description
since it is very wasteful to create binary blob partitions for a fastboot/android based boot with a big alignment the former (ubuntu-
description: | updated |
Changed in ubuntu-image: | |
importance: | Medium → High |
Changed in ubuntu-image: | |
milestone: | none → 0.13 |
Changed in ubuntu-image: | |
milestone: | 0.13 → 0.14 |
Changed in ubuntu-image: | |
milestone: | 0.14 → 0.15 |
Changed in ubuntu-image: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
The current behavior uses an alignment of 1MiB because, as explained in the sgdisk manpage description of this option:
This alignment value is necessary to obtain optimum performance with Western Digital Advanced Format and similar drives with larger physical than logical sector sizes, with some types of RAID arrays, and with SSD devices.
Is it possible that any of these performance issues might apply to the dragonboard use case as well? Is it possible that the sizes of any of these files might have to change in a future release of the gadget snap?
And for the record, the total wasted space, across 7 partitions, by using 1MiB-aligned partitions currently instead of sector-aligned partitions, is about 3.5MiB. The current gadget snap wastes another 1MiB all on its own, by allocating a 2MiB partition for sdappsboot.mbn when this file fits in 1MiB. So I don't think this is "very wasteful" currently
That said, there's no fundamental reason for us not to allow differently-aligned partitions, for gadgets that request this; this should be under the full control of the gadget author, provided there is any sensible reason to ever deviate from this default. But it's more than just the sgdisk arguments that have to be changed, if you look through the ubuntu-image code you'll see several places that a 1MiB alignment has been assumed initially during development (always with the intent of changing this later).