backport blkid: allow up to 64k erofs block sizes
This is a backport of [1], which should help us use EROFS in live
media on ppc64le [2].
[1] ff0ac0f27d
[2] https://github.com/coreos/fedora-coreos-tracker/issues/1877
This commit is contained in:
parent
3e60999497
commit
cd951d5e56
2 changed files with 36 additions and 0 deletions
33
0001-blkid-allow-up-to-64k-erofs-block-sizes.patch
Normal file
33
0001-blkid-allow-up-to-64k-erofs-block-sizes.patch
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
From ff0ac0f27dc3de7d250b2a69f6452bfeec104f8c Mon Sep 17 00:00:00 2001
|
||||
From: Eric Sandeen <sandeen@redhat.com>
|
||||
Date: Fri, 24 Jan 2025 08:37:12 -0600
|
||||
Subject: [PATCH] blkid: allow up to 64k erofs block sizes
|
||||
|
||||
Today, mkfs.erofs defaults to page size for block size, but blkid
|
||||
does not recognize this. Increase the limit to 64k.
|
||||
|
||||
Reviewed-by: Gao Xiang <xiang@kernel.org>
|
||||
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
|
||||
Signed-off-by: Karel Zak <kzak@redhat.com>
|
||||
---
|
||||
libblkid/src/superblocks/erofs.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/libblkid/src/superblocks/erofs.c b/libblkid/src/superblocks/erofs.c
|
||||
index 05822460b..57fd80220 100644
|
||||
--- a/libblkid/src/superblocks/erofs.c
|
||||
+++ b/libblkid/src/superblocks/erofs.c
|
||||
@@ -73,8 +73,8 @@ static int probe_erofs(blkid_probe pr, const struct blkid_idmag *mag)
|
||||
if (!sb)
|
||||
return errno ? -errno : BLKID_PROBE_NONE;
|
||||
|
||||
- /* EROFS is restricted to 4KiB block size */
|
||||
- if (sb->blkszbits > 31 || (1U << sb->blkszbits) > 4096)
|
||||
+ /* block size must be between 512 and 64k */
|
||||
+ if (sb->blkszbits < 9 || sb->blkszbits > 16)
|
||||
return BLKID_PROBE_NONE;
|
||||
|
||||
if (!erofs_verify_checksum(pr, mag, sb))
|
||||
--
|
||||
2.48.1
|
||||
|
||||
|
|
@ -111,6 +111,9 @@ Patch0: login-lastlog-create.patch
|
|||
# https://github.com/coreos/console-login-helper-messages/issues/60
|
||||
Patch1: login-default-motd-file.patch
|
||||
|
||||
# Backport better support for erofs on ppc64le
|
||||
Patch2: 0001-blkid-allow-up-to-64k-erofs-block-sizes.patch
|
||||
|
||||
%description
|
||||
The util-linux package contains a large variety of low-level system
|
||||
utilities that are necessary for a Linux system to function. Among
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue