From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756383Ab1ALUz3 (ORCPT ); Wed, 12 Jan 2011 15:55:29 -0500 Received: from e2.ny.us.ibm.com ([32.97.182.142]:52357 "EHLO e2.ny.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756070Ab1ALUz1 (ORCPT ); Wed, 12 Jan 2011 15:55:27 -0500 Subject: Re: [PATCH V8 02/13] ntp: add ADJ_SETOFFSET mode bit From: john stultz To: "Kuwahara,T." <6vvetjsrt26xsrzlh1z0zn4d2grdah@gmail.com> Cc: Richard Cochran , linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, netdev@vger.kernel.org, Alan Cox , Arnd Bergmann , Christoph Lameter , David Miller , Krzysztof Halasa , Peter Zijlstra , Rodolfo Giometti , Thomas Gleixner In-Reply-To: References: <20110108175028.GA22308@riccoc20.at.omicron.at> <1294678145.3068.6.camel@work-vm> <1294693597.3068.12.camel@work-vm> <1294779309.3441.66.camel@work-vm> Content-Type: text/plain; charset="UTF-8" Date: Wed, 12 Jan 2011 12:55:17 -0800 Message-ID: <1294865717.7696.17.camel@work-vm> Mime-Version: 1.0 X-Mailer: Evolution 2.30.3 Content-Transfer-Encoding: 7bit X-Content-Scanned: Fidelis XPS MAILER Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2011-01-13 at 05:39 +0900, Kuwahara,T. wrote: > On Wed, Jan 12, 2011 at 5:55 AM, john stultz wrote: > > So the kernel handles leap second insertion via a timer. Thus at the end > > of 23:59:59, it will inject a leapsecond by setting the time back by one > > second (back to 23:59:59) and setting the TIME_OOP flag. > > > > This timer is an absolute timer, so if someone moves the clock forward > > across the 23:59:59 boundary, the adjustment will still be made. > > > > The patch is not broken, nor useless. > > It takes into account only one upcoming leap second, but ignores all > the others. That's not sufficient for arbitrary adjustments. If an application wants to manage the full historical table of leapseconds and compensate appropriately, then that's fine. The interface proposed still functions in a reasonable manner. Again, I agree that leapseconds are annoying to deal with. It would be great if time() was defined as TAI time instead of UTC. I'm actually hoping to provide a CLOCK_TAI clockid someday. thanks -john From mboxrd@z Thu Jan 1 00:00:00 1970 From: john stultz Subject: Re: [PATCH V8 02/13] ntp: add ADJ_SETOFFSET mode bit Date: Wed, 12 Jan 2011 12:55:17 -0800 Message-ID: <1294865717.7696.17.camel@work-vm> References: <20110108175028.GA22308@riccoc20.at.omicron.at> <1294678145.3068.6.camel@work-vm> <1294693597.3068.12.camel@work-vm> <1294779309.3441.66.camel@work-vm> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: Richard Cochran , linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Alan Cox , Arnd Bergmann , Christoph Lameter , David Miller , Krzysztof Halasa , Peter Zijlstra , Rodolfo Giometti , Thomas Gleixner To: "Kuwahara,T." <6vvetjsrt26xsrzlh1z0zn4d2grdah-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Return-path: In-Reply-To: Sender: linux-api-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: netdev.vger.kernel.org On Thu, 2011-01-13 at 05:39 +0900, Kuwahara,T. wrote: > On Wed, Jan 12, 2011 at 5:55 AM, john stultz wrote: > > So the kernel handles leap second insertion via a timer. Thus at the end > > of 23:59:59, it will inject a leapsecond by setting the time back by one > > second (back to 23:59:59) and setting the TIME_OOP flag. > > > > This timer is an absolute timer, so if someone moves the clock forward > > across the 23:59:59 boundary, the adjustment will still be made. > > > > The patch is not broken, nor useless. > > It takes into account only one upcoming leap second, but ignores all > the others. That's not sufficient for arbitrary adjustments. If an application wants to manage the full historical table of leapseconds and compensate appropriately, then that's fine. The interface proposed still functions in a reasonable manner. Again, I agree that leapseconds are annoying to deal with. It would be great if time() was defined as TAI time instead of UTC. I'm actually hoping to provide a CLOCK_TAI clockid someday. thanks -john