On Thu, Feb 13, 2025 at 06:39:06AM +0100, Emile `iMil' Heitor wrote: > > Currently in sys/arch/x86/isa/clock.c startrtclock(), the function > continues to call tc_init() even when mc146818_read(NULL, NVRAM_DIAG) > fails. This causes the system to hang on qemu/microvm when rtc=on is > not specified. > > My proposal is to return if RTC BIOS diagnostic fails:
I think it's not right: mc146818_read(NULL, NVRAM_DIAG) returning a non--0 value doens't means that is fails. Usually the RTC BIOS diagnostic has some error because the chip lost track of date/time (maybe because of a bad battery). In this case you still want to use the RTC. Did you check what value is returned in your case ? -- Manuel Bouyer <bou...@antioche.eu.org> NetBSD: 26 ans d'experience feront toujours la difference --