1
0
mirror of https://github.com/systemd/systemd.git synced 2025-03-19 22:50:17 +03:00

repart: Log more about filesystem sector size

(cherry picked from commit 0e445aaa8553ff4ddf8330913260e5f167b1690d)
This commit is contained in:
Daan De Meyer 2024-06-28 19:36:50 +02:00 committed by Luca Boccassi
parent 86d47d63b0
commit 3c88c94432

View File

@ -2572,8 +2572,10 @@ static int context_load_partition_table(Context *context) {
/* If we found the sector size and we're operating on a block device, use it as the file
* system sector size as well, as we know its the sector size of the actual block device and
* not just the offset at which we found the GPT header. */
if (r > 0 && S_ISBLK(st.st_mode))
if (r > 0 && S_ISBLK(st.st_mode)) {
log_debug("Probed sector size of %s is %" PRIu32 " bytes.", context->node, ssz);
fs_secsz = ssz;
}
}
r = fdisk_save_user_sector_size(c, /* phy= */ 0, ssz);
@ -2637,7 +2639,7 @@ static int context_load_partition_table(Context *context) {
* larger */
grainsz = secsz < 4096 ? 4096 : secsz;
log_debug("Sector size of device is %lu bytes. Using grain size of %" PRIu64 ".", secsz, grainsz);
log_debug("Sector size of device is %lu bytes. Using filesystem sector size of %" PRIu64 " and grain size of %" PRIu64 ".", secsz, fs_secsz, grainsz);
switch (arg_empty) {