[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070201194109.GA21971@suse.cz>
Date: Thu, 1 Feb 2007 20:41:09 +0100
From: Vojtech Pavlik <vojtech@...e.cz>
To: john stultz <johnstul@...ibm.com>
Cc: Jiri Bohac <jbohac@...e.cz>, Andi Kleen <ak@...e.de>,
linux-kernel@...r.kernel.org, ssouhlal@...ebsd.org,
arjan@...radead.org, tglx@...utronix.de, zippel@...ux-m68k.org,
andrea@...e.de
Subject: Re: [patch 0/9] x86_64: reliable TSC-based gettimeofday
On Thu, Feb 01, 2007 at 08:56:48AM -0800, john stultz wrote:
> On Thu, 2007-02-01 at 15:52 +0100, Jiri Bohac wrote:
> > On Thu, Feb 01, 2007 at 12:20:59PM +0100, Andi Kleen wrote:
> >>
> > > The big strategic problem is how to marry your patchkit to John Stultz's
> > > clocksources work which is also competing for merge. Any thoughts on that?
> >
> > I'll look into that next week. Sorry, I wanted to do that a long time
> > ago, but I spent weeks (over a month) fighting a nasty livelock
> > in the code. (Morale: think twice before using a spinlock inside
> > a {do .. while (read_seqretry(..))} loop)
>
> The first step here shouldn't be too difficult. Just create a _read
> function that uses your code to return monotonic TSC cycles (instead of
> nanoseconds w/ gettimeofday). Then just create a clocksource structure
> for it.
guess_mt() is more or less the function you're looking for. (With the
exception of the cpufreq and mode switching logic.)
> The harder part will be the vsyscall, as you will need extra per cpu
> data in the vsyscall read. I had some test code for this situation
> awhile back, so if you get the first part functioning correctly (just a
> clocksource w/o a vread pointer), I'll gladly help you get the vsyscall
> bits working.
>
> thanks
> -john
>
>
--
Vojtech Pavlik
Director SuSE Labs
-
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