On Tue, Feb 18, 2025 at 09:43:16PM +0100, Emile `iMil' Heitor wrote: > On Tue, 18 Feb 2025, Emile `iMil' Heitor wrote: > > > if ((mc146818_read(NULL, MC_REGD) & MC_REGD_VRT) == 0) > > return (-1); > > My bad, this test assumes the chip is replying something valid, what > we want to test is that bits 0 to 6 are set to 0, so in startrtclock() > it would be: > > /* RTC is present, bits 0 to 6 are 0 */ > if ((mc146818_read(NULL, MC_REGD) & 0x7f) != 0) > return;
To me it looks good. -- Manuel Bouyer <bou...@antioche.eu.org> NetBSD: 26 ans d'experience feront toujours la difference --