]> Projects (at) Tadryanom (dot) Me - AdrOS.git/commit
feat: unified FAT12/16/32 RW driver replacing read-only FAT16
authorTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 04:54:13 +0000 (01:54 -0300)
committerTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 04:54:13 +0000 (01:54 -0300)
commit7d294e1e6e853981feed35dd3e1d57aa22585ed1
treeb285507ad97d466fd8f36d27225dea66ce29d316
parent3d74635da63d5a36b967333edf713a77b0fb9499
feat: unified FAT12/16/32 RW driver replacing read-only FAT16

- New fat.c: unified FAT driver with auto-detection (FAT12/16/32) based on
  cluster count per Microsoft FAT spec
- Full RW support: file read/write, create, delete, truncate, mkdir, rmdir,
  rename, readdir, finddir — all wired to VFS callbacks
- FAT table access for all three variants (12-bit, 16-bit, 32-bit entries)
- Cluster chain management: alloc, extend, free
- Subdirectory support (cluster-based dirs + fixed root for FAT12/16)
- 8.3 filename conversion (to/from human-readable lowercase)
- fat16.h retained as backward-compat wrapper redirecting to fat.h
- Old read-only fat16.c removed

Fix: BSS collision with ACPI temp VA window
- BSS grew past 0xC0202000 with lwIP memp pools + FAT statics
- Moved ACPI temp VA: 0xC0202000 -> 0xC0300000
- Moved DMA PRDT VA: 0xC0220000 -> 0xC0320000
- Moved DMA bounce VA: 0xC0221000 -> 0xC0321000

Build: clean, cppcheck: clean, smoke: 19/19 pass
include/fat.h [new file with mode: 0644]
include/fat16.h
src/arch/x86/acpi.c
src/hal/x86/ata_dma.c
src/kernel/fat.c [new file with mode: 0644]
src/kernel/fat16.c [deleted file]