[syslinux] [PATCH] Mending proposals for mkdiskimage
H. Peter Anvin
hpa at zytor.com
Thu Jan 30 11:16:09 PST 2014
On 01/30/2014 10:13 AM, Thomas Schmitt wrote:
> Hi,
>
> this is the diff which i consider a halfways reasonable solution
> for the following problems with mkdiskimage:
>
> 1. Ignoring option -s if the target file is not suitable for truncate().
>
> 2. Miscalculation of truncate() size by a factor of 512.
>
> 3. The storage capacity of device files can only be measured
> for Linux block devices.
>
> 4. Long time of silent work when slow devices (e.g. USB sticks) get
> formatted without option -s.
>
> Another issue is not necessarily a problem but might leave the
> possibility of confusing firmware by e.g. an outdated GPT backup:
>
> 5. No zeroizing of eventual past-partition space.
> Such space remains e.g. if the given number of megabytes or the
> determined size of the target device is not aligned to cylinder
> size. (It also remains if the device or existing file size is
> larger than an explicitely given number of cylinders.)
>
For zeroizing a device, there are other tools, e.g. scrub/diskscrub, but
an explicit option to zeroize the device might be a good idea.
Thank you for taking this on. Single-issue patches would be great, indeed.
-hpa
More information about the Syslinux
mailing list