]> Projects (at) Tadryanom (dot) Me - AdrOS.git/commit
refactor: VFS file_operations dispatch layer
authorTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 21:05:14 +0000 (18:05 -0300)
committerTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 21:05:14 +0000 (18:05 -0300)
commit5d67181a22714626f6ec4b22e382cf688a03c98a
tree220ed19d814dca63d8a53cb7c0e733767938b01b
parent565486e98cfaa572cfac794bd98aa5d5ee393c47
refactor: VFS file_operations dispatch layer

Add struct file_operations to fs.h with all VFS callback signatures.
Add const struct file_operations* f_ops to fs_node_t.

Update all VFS dispatch points (fs.c wrappers + syscall.c direct
dispatch for poll, readdir, ioctl, mmap) to check f_ops first,
then fall back to legacy per-node function pointers.

This enables incremental migration: filesystems can adopt f_ops
one at a time while legacy pointers continue to work.

20/20 smoke tests pass.
include/fs.h
src/kernel/fs.c
src/kernel/syscall.c