mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-09-30 14:01:57 -09:00
package/systemd: fix build with recent kernels
Backport a patch from upstream that adds the magic number for the bcachefs superblock. Otherwise, systemd 254.13 fails to compile with the latest kernel versions. Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
committed by
Thomas Petazzoni
parent
a8ecf73895
commit
f3c1f667dc
53
package/systemd/0002-basic-add-bcachefs-magic.patch
Normal file
53
package/systemd/0002-basic-add-bcachefs-magic.patch
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
From e5ff9b585d7dc54f50085d518d7d588c250b0690 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Chris Packham <chris.packham@alliedtelesis.co.nz>
|
||||||
|
Date: Fri, 31 May 2024 09:51:38 +1200
|
||||||
|
Subject: [PATCH] basic: Add BCACHEFS magic
|
||||||
|
|
||||||
|
Import magic.h from Linux 6.9 to get the definition of
|
||||||
|
BCACHEFS_SUPER_MAGIC. Update filesystems-gperf.gperf to add knowledge of
|
||||||
|
bcachefs.
|
||||||
|
|
||||||
|
This fixes the following error building against a bleeding edge kernel.
|
||||||
|
```
|
||||||
|
src/basic/meson.build:234:8: ERROR: Problem encountered: Unknown filesystems defined in kernel headers:
|
||||||
|
|
||||||
|
Filesystem found in kernel header but not in filesystems-gperf.gperf: BCACHEFS_SUPER_MAGIC
|
||||||
|
```
|
||||||
|
|
||||||
|
Upstream: https://github.com/systemd/systemd/commit/201148b08de65de004d10679a8c3d201cc08fb28
|
||||||
|
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
|
||||||
|
---
|
||||||
|
src/basic/filesystems-gperf.gperf | 1 +
|
||||||
|
src/basic/missing_magic.h | 7 +++++++
|
||||||
|
2 files changed, 8 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/src/basic/filesystems-gperf.gperf b/src/basic/filesystems-gperf.gperf
|
||||||
|
index 1cd66b5a5f..c82fe98227 100644
|
||||||
|
--- a/src/basic/filesystems-gperf.gperf
|
||||||
|
+++ b/src/basic/filesystems-gperf.gperf
|
||||||
|
@@ -28,6 +28,7 @@ afs, {AFS_FS_MAGIC, AFS_SUPER_MAGIC}
|
||||||
|
anon_inodefs, {ANON_INODE_FS_MAGIC}
|
||||||
|
autofs, {AUTOFS_SUPER_MAGIC}
|
||||||
|
balloon-kvm, {BALLOON_KVM_MAGIC}
|
||||||
|
+bcachefs, {BCACHEFS_SUPER_MAGIC}
|
||||||
|
bdev, {BDEVFS_MAGIC}
|
||||||
|
binder, {BINDERFS_SUPER_MAGIC}
|
||||||
|
binfmt_misc, {BINFMTFS_MAGIC}
|
||||||
|
diff --git a/src/basic/missing_magic.h b/src/basic/missing_magic.h
|
||||||
|
index 82d71c8ad1..b3d2ee9f57 100644
|
||||||
|
--- a/src/basic/missing_magic.h
|
||||||
|
+++ b/src/basic/missing_magic.h
|
||||||
|
@@ -197,3 +197,10 @@
|
||||||
|
#ifndef NTFS3_SUPER_MAGIC
|
||||||
|
#define NTFS3_SUPER_MAGIC 0x7366746e
|
||||||
|
#endif
|
||||||
|
+
|
||||||
|
+/* Added in Linux commit e2f48c48090dea172c0c571101041de64634dae5. Remove when next sync'd */
|
||||||
|
+#ifndef BCACHEFS_SUPER_MAGIC
|
||||||
|
+# define BCACHEFS_SUPER_MAGIC 0xca451a4e
|
||||||
|
+#else
|
||||||
|
+assert_cc(BCACHEFS_SUPER_MAGIC == 0xca451a4e)
|
||||||
|
+#endif
|
||||||
|
--
|
||||||
|
2.45.1
|
||||||
|
|
||||||
Reference in New Issue
Block a user