[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: PCF8563 once more

> From: Pieter Grimmerink [mailto:mailinglists@xxxxxxx.nl] 
> Sent: den 25 juni 2003 11:06
> To: dev-etrax@xxxxxxx.com
> Subject: PCF8563 once more
> pcf8563_readreg shouldn't convert the month, which is kept as 
> [1..12] by the 
> rtc, to [0..11].
> The kernel (in time.c) calls mktime() with the values returned by 
> pcf8563_readreg, and mktime expects the month to be numbered [1..12]

It looks like you're right (again). 

The confusing part may be that the kernel mktime() numbers the months [1..12] while the user space mktime() (and other stuff using struct tm) uses [0.11].