[Concept,00/15] ext4l: Infrastructure and fixes for write support (part K)

Message ID 20251230234134.906477-1-sjg@u-boot.org
Headers
Series ext4l: Infrastructure and fixes for write support (part K) |

Message

Simon Glass Dec. 30, 2025, 11:41 p.m. UTC
  From: Simon Glass <simon.glass@canonical.com>

This series adds infrastructure and bug fixes needed for ext4l write
support. It includes:

- kmem_cache implementation controlled by CONFIG_LIB_KMEM_CACHE
- Bit operation functions imported from Linux (find_bit, fns)
- Little-endian bit operations for ext4 bitmaps
- Buffer I/O infrastructure for write operations
- Folio and buffer head fixes for U-Boot's malloc'd buffers
- Inode handling fixes (i_mode, i_blocks, iput eviction)
- Journal cleanup detection in bh_cache_clear()
- Various bug fixes for clang warnings and multi-word bit operations


Simon Glass (15):
  lib: Add CONFIG_LIB_KMEM_CACHE for full kmem_cache support
  ext4l: Add journal_head detection in bh_cache_clear
  bitops: linux: Add fns() to find N'th set bit
  lib: linux: Add find_bit from Linux
  ext4l: Implement little-endian bit operations
  ext4l: Adjust folio offset and mapping operations
  ext4l: Implement buffer write I/O and allocation
  ext4l: Fix inode_init_owner to set i_mode
  ext4l: Add ext4_commit_super() declaration
  ext4l: Fix dquot functions to update i_blocks
  ext4l: Return boot-relative time from ktime_get_real_seconds()
  ext4l: Implement iput() to evict deleted inodes
  ext4l: Use percpu_counter initialized field
  ext4l: Fix bit operations for bits beyond first word
  ext4l: Fix cmpxchg macro warning with clang

 fs/ext4l/ext4_uboot.h  |  95 +++++++++-------
 fs/ext4l/stub.c        |  47 +++++++-
 fs/ext4l/support.c     | 246 ++++++++++++++++++++++++++++++++++++++---
 include/linux/bitops.h |  13 +++
 include/linux/find.h   | 176 +++++++++++++++++++++++++++++
 include/linux/slab.h   |  27 +++--
 lib/Kconfig            |   8 ++
 lib/Makefile           |   2 +
 lib/find_bit.c         | 142 ++++++++++++++++++++++++
 lib/kmem_cache.c       |  20 ++++
 10 files changed, 704 insertions(+), 72 deletions(-)
 create mode 100644 include/linux/find.h
 create mode 100644 lib/find_bit.c
 create mode 100644 lib/kmem_cache.c