lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 1 Mar 2010 13:43:08 +0300
From:	Alexander Gordeev <lasaine@....cs.msu.su>
To:	Rodolfo Giometti <giometti@...eenne.com>
Cc:	linux-kernel@...r.kernel.org, linuxpps@...enneenne.com,
	"Nikita V. Youshchenko" <yoush@...msu.su>, stas@....cs.msu.su,
	john stultz <johnstul@...ibm.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Alan Cox <alan@...rguk.ukuu.org.uk>,
	Ingo Molnar <mingo@...e.hu>,
	Bernhard Schiffner <bernhard@...iffner-limbach.de>,
	Rik van Riel <riel@...hat.com>,
	Thomas Gleixner <tglx@...utronix.de>,
	Martin Schwidefsky <schwidefsky@...ibm.com>
Subject: Re: [PATCHv2 1/6] ntp: add hardpps implementation

On Mon, 1 Mar 2010 09:14:59 +0100
Rodolfo Giometti <giometti@...eenne.com> wrote:

> On Wed, Feb 24, 2010 at 03:28:12PM +0300, Alexander Gordeev wrote:
> > This commit adds hardpps() implementation based upon the original one
> > from the NTPv4 reference kernel code from David Mills. However, it is
> > highly optimized towards very fast syncronization and maximum stickness
> > to PPS signal. The typical error is less then a microsecond.
> > To make it sync faster I had to throw away exponential phase filter so
> > that the full phase offset is corrected immediately. Then I also had to
> > throw away median phase filter because it gives a bigger error itself
> > if used without exponential filter.
> > Maybe we will find an appropriate filtering scheme in the future but
> > it's not necessary if the signal quality is ok.
> > 
> > Signed-off-by: Alexander Gordeev <lasaine@....cs.msu.su>
> > ---
> >  drivers/pps/Kconfig   |    1 +
> >  include/linux/timex.h |    1 +
> >  kernel/time/Kconfig   |    7 +
> >  kernel/time/ntp.c     |  420 +++++++++++++++++++++++++++++++++++++++++++++++--
> >  4 files changed, 414 insertions(+), 15 deletions(-)
> > 
> > diff --git a/drivers/pps/Kconfig b/drivers/pps/Kconfig
> > index cc2eb8e..2bd4f65 100644
> > --- a/drivers/pps/Kconfig
> > +++ b/drivers/pps/Kconfig
> > @@ -7,6 +7,7 @@ menu "PPS support"
> >  config PPS
> >  	tristate "PPS support"
> >  	depends on EXPERIMENTAL
> > +	select NTP_PPS
> >  	---help---
> >  	  PPS (Pulse Per Second) is a special pulse provided by some GPS
> >  	  antennae. Userland can use it to get a high-precision time
> > diff --git a/include/linux/timex.h b/include/linux/timex.h
> > index e6967d1..5a93cd3 100644
> > --- a/include/linux/timex.h
> > +++ b/include/linux/timex.h
> > @@ -274,6 +274,7 @@ extern u64 tick_length;
> >  extern void second_overflow(void);
> >  extern void update_ntp_one_tick(void);
> >  extern int do_adjtimex(struct timex *);
> > +extern void hardpps(const struct timespec *, const struct timespec *);
> >  
> >  /* Don't use! Compatibility define for existing users. */
> >  #define tickadj	(500/HZ ? : 1)
> > diff --git a/kernel/time/Kconfig b/kernel/time/Kconfig
> > index 95ed429..2da4900 100644
> > --- a/kernel/time/Kconfig
> > +++ b/kernel/time/Kconfig
> > @@ -27,3 +27,10 @@ config GENERIC_CLOCKEVENTS_BUILD
> >  	default y
> >  	depends on GENERIC_CLOCKEVENTS || GENERIC_CLOCKEVENTS_MIGR
> >  
> > +config NTP_PPS
> > +	bool "PPS kernel consumer support"
> > +	depends on PPS
> > +	help
> > +	  This option adds support for direct in-kernel time
> > +	  syncronization using an external PPS signal.
> > +
> 
> This patch is both PPS and NTP related but I suppose is better moving
> this setting into drivers/pps directory since people whose want to use
> thise supports can go into same place and find whetever they want...

OK, I don't mind moving it. In fact I don't remember why I put it
here. :)
Thanks for the note!

-- 
  Alexander

Download attachment "signature.asc" of type "application/pgp-signature" (490 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ