Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932394AbaJNOVp (ORCPT ); Tue, 14 Oct 2014 10:21:45 -0400 Received: from mail-wg0-f41.google.com ([74.125.82.41]:43813 "EHLO mail-wg0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932121AbaJNOVo (ORCPT ); Tue, 14 Oct 2014 10:21:44 -0400 Date: Tue, 14 Oct 2014 16:21:38 +0200 From: Richard Cochran To: Mike Surcouf Cc: Thomas Shao , Dan Carpenter , "tglx@linutronix.de" , "gregkh@linuxfoundation.org" , "linux-kernel@vger.kernel.org" , "devel@linuxdriverproject.org" , "olaf@aepfle.de" , "apw@canonical.com" , "jasowang@redhat.com" , KY Srinivasan Subject: Re: [PATCH 2/2] hyperv: Implement Time Synchronization using host time sample Message-ID: <20141014142138.GA6469@localhost.localdomain> References: <1413285078-7027-1-git-send-email-huishao@microsoft.com> <20141014111915.GV23154@mwanda> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 14, 2014 at 02:16:34PM +0100, Mike Surcouf wrote: > What is your expected value for TICK_USEC? I cant make the arithmetic work. > You double the check time if you are close but you never reduce the > check time if you are not. > Adjusting the tick count is a coarse adjustment of the clock. You > will end up chasing the host time but never stabilizing it. We should not be putting hardcoded servos into random drivers. Instead, why not export the time offset to the guest as a series of PPS samples, or the like? Then, a user space program in the guest can decide whether it will use the information and how to filter the signal. > Regarding the comment we have NTP for this I agree that would be > better than this implementation and I think Thomas agrees (as he said > NTP is the preferred option) > In order for this to be a good source of time for RTP and other time > sensitive stuff . you will have to have to re-implement parts of NTP > such as adjusting the clock frequency decreasing the check period when > error becomes too great etc. etc.. No, lets not re-implement NTP. That would be a waste of effort. Thanks, Richard -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/