]> Projects (at) Tadryanom (dot) Me - AdrOS.git/commit
feat: HAL Device Driver API — driver registry with probe/init/shutdown lifecycle
authorTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 19:54:47 +0000 (16:54 -0300)
committerTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 19:54:47 +0000 (16:54 -0300)
commitbc1efbd756f16136264687ee324b0628d4b4f3c6
tree5c425fbed9f5469f69b6f637fbf2b800adbee4f9
parent8debc64b83ea1517fc3616ec281e4751dc44165a
feat: HAL Device Driver API — driver registry with probe/init/shutdown lifecycle

- Add include/hal/driver.h: struct hal_driver with type, priority, ops (probe/init/shutdown)
- Add src/kernel/driver.c: driver registry with hal_driver_register(), hal_drivers_init_all(),
  hal_drivers_shutdown_all(), hal_driver_find(), hal_driver_count()
- Drivers init in priority order (insertion sort), shutdown in reverse
- HAL_MAX_DRIVERS=32, 6 driver types: PLATFORM, CHAR, BLOCK, NET, DISPLAY, BUS
- Framework ready for existing drivers to self-register (incremental migration)

20/20 smoke, cppcheck clean
include/hal/driver.h [new file with mode: 0644]
src/kernel/driver.c [new file with mode: 0644]