On Fri, Oct 19, 2012 at 11:44 PM, H. Peter Anvin <hpa@xxxxxxxxx> wrote: > What I'm saying is that you should also set the century byte (byte 0x32); > there should also be a pointer to it in the ACPI FADT, but 0x32 is the > standard location. I did not want to get into messing with the FADT (ACPI always gives me hives :-) but if 0x32 is a good enough convention that works for me. > > The statement "The CMOS standard is time since 2000" is rather misleading; > RTC byte 0x09 is simply the low two BCD digits of the Gregorian year, and > the century byte (normally 0x32) is the high two BCD digits. > > So the right thing is something like: > > year = tm->tm_year + 1900; > > case RTC_YEAR: > ioport__write8(data, bin2bcd(year % 100)); > break; > > case RTC_CENTURY: > ioport__write8(data, bin2bcd(year / 100)); > break; Thanks for clearing that up, I will rework the patch and see if the kernel is happier this time. ron -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html