From: Russell King <rmk+lkml@arm.linux.org.uk>
To: Andrew Victor <andrew@sanpeople.com>
Cc: linux-kernel@vger.kernel.org, alessandro.zummo@towertech.it,
akpm@osdl.org
Subject: Re: [PATCH[ RTC: Add rtc_year_days() to calculate tm_yday
Date: Wed, 7 Jun 2006 20:33:11 +0100 [thread overview]
Message-ID: <20060607193311.GH13165@flint.arm.linux.org.uk> (raw)
In-Reply-To: <1149704768.20154.95.camel@fuzzie.sanpeople.com>
On Wed, Jun 07, 2006 at 08:26:09PM +0200, Andrew Victor wrote:
> RTC: Add exported function rtc_year_days() to calculate the tm_yday
> value.
Is there a good reason for this? I ask the question because the x86
/dev/rtc driver says:
* Only the values that we read from the RTC are set. We leave
* tm_wday, tm_yday and tm_isdst untouched. Note that while the
* RTC has RTC_DAY_OF_WEEK, we should usually ignore it, as it is
* only updated by the RTC when initially set to a non-zero value.
So it seems the established modus operandi for RTC interfaces is "don't
trust wday, yday and isdst".
--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: 2.6 Serial core
next prev parent reply other threads:[~2006-06-07 19:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-06-07 18:26 [PATCH[ RTC: Add rtc_year_days() to calculate tm_yday Andrew Victor
2006-06-07 19:33 ` Russell King [this message]
2006-06-07 22:48 ` H. Peter Anvin
2006-06-08 6:43 ` Andrew Victor
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060607193311.GH13165@flint.arm.linux.org.uk \
--to=rmk+lkml@arm.linux.org.uk \
--cc=akpm@osdl.org \
--cc=alessandro.zummo@towertech.it \
--cc=andrew@sanpeople.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox