[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LFD.2.00.1005261631550.2995@localhost.localdomain>
Date: Wed, 26 May 2010 16:41:06 +0200 (CEST)
From: Thomas Gleixner <tglx@...utronix.de>
To: Dan Magenheimer <dan.magenheimer@...cle.com>
cc: Brian Bloniarz <bmb@...enacr.com>,
john stultz <johnstul@...ibm.com>,
"H. Peter Anvin" <hpa@...or.com>, Ingo Molnar <mingo@...e.hu>,
Peter Zijlstra <peterz@...radead.org>,
Andi Kleen <andi@...stfloor.org>,
Arjan van de Ven <arjan@...radead.org>,
Venkatesh Pallipadi <venki@...gle.com>, chris.mason@...cle.com,
linux-kernel@...r.kernel.org
Subject: RE: [PATCH] x86: Export tsc related information in sysfs
On Wed, 26 May 2010, Dan Magenheimer wrote:
> > From: Thomas Gleixner [mailto:tglx@...utronix.de]
> >
> > Arch independent solution is to provide information about the current
> > clock source in general. This is _NOT_ a TSC specific problem, you
> > have the same trouble with any other clocksource which gets calibrated
> > and does not take it's frequency as a constant value from boot loader,
> > configuration or some CPU/chipset register. The only missing piece is
> > a frequency member in struct clocksource which needs to be filled in
> > by the arch/machine specific code.
>
> Actually there is already a frequency in struct clocksource except
> it's represented by the two components: mult and shift. Maybe
> it would be best to expose these instead of khz (for all clocksources)
> so as to limit abuse by naive users.
You mean the TSC user space ones ?
> So, Thomas and John, if Brian's patch is modified to provide:
>
> /sys/devices/system/clocksource/clocksource0/current_mult
> /sys/devices/system/clocksource/clocksource0/current_shift
> and/or
> /sys/devices/system/clocksource/clocksource0/current_khz
>
> is that an acceptable arch-independent patch? (And which do
> you prefer?)
I'd rather prefer the frequency interface for a simple reason. It
allows to add a commandline option which provides the NTP folks with a
sensible solution to their calibration problem as I don't see that a
longer calibration time will reliably fix it.
So we'd get a "clocksource_freq=XXX" option which would be applied to
the clocksource which is selected on the command line with
"clocksource=NNN".
John ?
Thanks,
tglx
--
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