mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Russell King <rmk@arm.linux.org.uk>
To: mdharm-kernel@one-eyed-alien.net (Matthew Dharm)
Cc: Andries.Brouwer@cwi.nl, linux-kernel@vger.kernel.org
Subject: Re: set_rtc_mmss: can't update from 0 to 59
Date: Mon, 18 Dec 2000 08:46:23 +0000 (GMT)	[thread overview]
Message-ID: <200012180846.eBI8kNY20521@flint.arm.linux.org.uk> (raw)
In-Reply-To: <20001217194737.C11947@one-eyed-alien.net> from "Matthew Dharm" at Dec 17, 2000 07:47:37 PM

Matthew Dharm writes:
> Ahh... I think I see.  While the math says "if the diference between the
> real time and the cmos time is less than 30 min", it doesn't recognize that
> the time difference between 2:59 and 3:00 is only 1 min.

Which is intentional.

> True enough...  but, the question is, how do we fix this?

Why do you think it needs fixing?

Think about what happens when the current time according to the CMOS is
2:59:00 and Linux thinks its 3:01:20.  We only write the minutes and
seconds, so if we did write, the CMOS clock then becomes 2:01:20.
Oops, we just lost an hour.  Next time you reboot, you'll find the
time out by an hour or more depending on how many corrections of this
type have been done.

So, why don't we update the hours and be done with it?  We would have to
play the same game with the days of the month vs hours.  Also, we don't
know if the CMOS clock is programmed for UTC time or not (the kernel's
idea of time is UTC.  Your CMOS may be programmed for EST for instance).
   _____
  |_____| ------------------------------------------------- ---+---+-
  |   |         Russell King        rmk@arm.linux.org.uk      --- ---
  | | | | http://www.arm.linux.org.uk/personal/aboutme.html   /  /  |
  | +-+-+                                                     --- -+-
  /   |               THE developer of ARM Linux              |+| /|\
 /  | | |                                                     ---  |
    +-+-+ -------------------------------------------------  /\\\  |
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

  reply	other threads:[~2000-12-18 10:34 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-12-17 20:54 Andries.Brouwer
2000-12-18  3:47 ` Matthew Dharm
2000-12-18  8:46   ` Russell King [this message]
2000-12-19 21:13     ` Oliver Xymoron
2000-12-19 22:25       ` Russell King
2000-12-19 22:53         ` Oliver Xymoron
2000-12-21  9:28   ` Paul Gortmaker
2000-12-21 10:07     ` Russell King
  -- strict thread matches above, loose matches on Subject: below --
2000-12-18 13:10 Andries.Brouwer
2000-12-18 16:48 ` Matthew Dharm
2000-12-17 20:32 Matthew Dharm
2000-12-18 13:11 ` Matthias Andree

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=200012180846.eBI8kNY20521@flint.arm.linux.org.uk \
    --to=rmk@arm.linux.org.uk \
    --cc=Andries.Brouwer@cwi.nl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mdharm-kernel@one-eyed-alien.net \
    /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

all inboxes | Powered by JetHome®