]> git.ipfire.org Git - thirdparty/util-linux.git/commit
libfdisk: ignore 33553920 byte optimal I/O size
authorRyan Finnie <ryan@finnie.org>
Sun, 27 Dec 2020 18:01:26 +0000 (10:01 -0800)
committerRyan Finnie <ryan@finnie.org>
Sun, 27 Dec 2020 18:07:27 +0000 (10:07 -0800)
commitbbb66067c523176c6bbe8e1c7164469be4c6ad60
tree0717a333b6688a785ec7c93b12a64695ee340816
parent7ed579523b556b1270f28dbdb7ee07dee310f157
libfdisk: ignore 33553920 byte optimal I/O size

33553920 byte optimal I/O size arises from badly-implemented USB SATA
adapters reporting 0xffff 512 byte sectors (32 MiB - 512).  Commit
acb7651f8897ae73d0f45dd75bc87630001c61b9 indirectly addresses this by
ignoring the optimal I/O size if it's not a multiple of the physical
sector size.  That works if the physical sector size is 4096, but
33553920 optimal is allowed for 512 physical.

This commit explicitly ignores 33553920, as there is no legitimate
situation where this number would be the real optimal I/O size.

Signed-off-by: Ryan Finnie <ryan@finnie.org>
Closes: https://github.com/karelzak/util-linux/issues/1221
libfdisk/src/alignment.c