]> Projects (at) Tadryanom (dot) Me - AdrOS.git/commit
refactor: extract x86 CMOS I/O from drivers/rtc.c to HAL layer
authorTulio A M Mendes <[email protected]>
Thu, 12 Feb 2026 06:37:06 +0000 (03:37 -0300)
committerTulio A M Mendes <[email protected]>
Fri, 13 Feb 2026 02:44:55 +0000 (23:44 -0300)
commit945f4be3858ce3c98d66e1fd6cd1ff51bab0bb69
treec26a3b1f4588c5af8bee5bde46fa7522991f9076
parent1e63ba62292dd82777cdb8fcd83cc13ab3f81043
refactor: extract x86 CMOS I/O from drivers/rtc.c to HAL layer

Created include/hal/rtc.h with generic HAL RTC interface and
src/hal/x86/rtc.c with x86 CMOS port I/O implementation.

src/drivers/rtc.c is now fully architecture-agnostic: it calls
hal_rtc_read_raw() for hardware access and keeps only the generic
BCD-to-binary conversion and UNIX timestamp calculation logic.

This follows the same HAL pattern used by timer, keyboard, uart,
and video drivers.
include/hal/rtc.h [new file with mode: 0644]
src/drivers/rtc.c
src/hal/x86/rtc.c [new file with mode: 0644]