[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFw-LpVqUbAARwV_vabE7BGD7Z=O-oNdNJhrcuz6qMuM7w@mail.gmail.com>
Date: Thu, 4 Jun 2015 09:52:34 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: George Spelvin <linux@...izon.com>
Cc: Ingo Molnar <mingo@...nel.org>,
Adrian Hunter <adrian.hunter@...el.com>,
Andi Kleen <ak@...ux.intel.com>, Peter Anvin <hpa@...or.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Andy Lutomirski <luto@...capital.net>,
Thomas Gleixner <tglx@...utronix.de>
Subject: Re: [PATCH RFC] x86, tsc: Allow for high latency in quick_pit_calibrate()
On Thu, Jun 4, 2015 at 9:38 AM, George Spelvin <linux@...izon.com> wrote:
>
> Also, you don't have to enable interrupts in the RTC to get the PF bit
> set periodically. You only program the interval (register A lsbits),
> not the IRQ (register B bit 6). In fact, disabling the interrupt is
> probably safer.
Also, I don't know what Ingo's test-code looked like, but it is
probably best to set the RTC to 8kHz, and then time a few iterations
of "count cycles between PF gets set" rather than "wait for bit to get
set after programming". With the usual "have timestamp both before the
read that shows the bit set, and after the read" so that you can
estimate how big the error window is.
Maybe that's what Ingo's jitter numbers already are, without seeing
what the test-code was it's hard to guess.
And you definitely want to disable interrupts and make sure nobody
else reads that register, since reading it will clear it. Although I
guess that during early boot there shouldn't be any other RTC
activity..
Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists