[Concept,24/34] ext4l: Move FMODE hash flags to linux/fs.h

Message ID 20260114225635.3407989-25-sjg@u-boot.org
State New
Headers
Series ext4l: Clean up ext4_uboot.h by moving definitions to standard headers |

Commit Message

Simon Glass Jan. 14, 2026, 10:56 p.m. UTC
  From: Simon Glass <simon.glass@canonical.com>

Move FMODE_32BITHASH and FMODE_64BITHASH flags from ext4_uboot.h to
linux/fs.h where they belong alongside other file mode flags.

Co-developed-by: Claude Opus 4.5 <noreply@anthropic.com>
Signed-off-by: Simon Glass <simon.glass@canonical.com>
---

 fs/ext4l/ext4_uboot.h | 4 +---
 include/linux/fs.h    | 4 ++++
 2 files changed, 5 insertions(+), 3 deletions(-)
  

Patch

diff --git a/fs/ext4l/ext4_uboot.h b/fs/ext4l/ext4_uboot.h
index 7b90276b2bc..4b342089489 100644
--- a/fs/ext4l/ext4_uboot.h
+++ b/fs/ext4l/ext4_uboot.h
@@ -173,9 +173,7 @@  typedef unsigned long pgoff_t;
 #define PAGE_SHIFT	12
 #endif
 
-/* File mode flags */
-#define FMODE_32BITHASH		0x00000001
-#define FMODE_64BITHASH		0x00000002
+/* FMODE_32BITHASH, FMODE_64BITHASH are in linux/fs.h */
 
 /* struct file is defined in linux/fs.h */
 
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 241711eded1..049033c0cd7 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -36,6 +36,10 @@  typedef unsigned int fmode_t;
 #define FMODE_CAN_ODIRECT	((__force fmode_t)(1 << 21))
 #define FMODE_CAN_ATOMIC_WRITE	((__force fmode_t)(1 << 22))
 
+/* Directory file mode flags - use low bits for hash mode */
+#define FMODE_32BITHASH		((__force fmode_t)0x00000001)
+#define FMODE_64BITHASH		((__force fmode_t)0x00000002)
+
 /* Seek constants */
 #ifndef SEEK_HOLE
 #define SEEK_HOLE	4