Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933291AbbKMKpm (ORCPT ); Fri, 13 Nov 2015 05:45:42 -0500 Received: from smtp.citrix.com ([66.165.176.89]:41091 "EHLO SMTP.CITRIX.COM" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932813AbbKMKpb (ORCPT ); Fri, 13 Nov 2015 05:45:31 -0500 X-IronPort-AV: E=Sophos;i="5.20,287,1444694400"; d="scan'208";a="312043189" Date: Fri, 13 Nov 2015 10:45:13 +0000 From: Stefano Stabellini X-X-Sender: sstabellini@kaball.uk.xensource.com To: David Vrabel CC: Stefano Stabellini , , , , , , John Stultz Subject: Re: [Xen-devel] [PATCH v4 7/7] xen/x86: support XENPF_settime64 In-Reply-To: <5645BE8C.6050109@citrix.com> Message-ID: References: <1447349448-22610-7-git-send-email-stefano.stabellini@eu.citrix.com> <5645BE8C.6050109@citrix.com> User-Agent: Alpine 2.02 (DEB 1266 2009-07-14) MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" X-DLP: MIA1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1347 Lines: 38 On Fri, 13 Nov 2015, David Vrabel wrote: > On 12/11/15 17:30, Stefano Stabellini wrote: > > Try XENPF_settime64 first, if it is not available fall back to > > XENPF_settime32. > > > > No need to call __current_kernel_time() when all the info needed are > > already passed via the struct timekeeper * argument. > > > > Return NOTIFY_BAD in case of errors. > [...] > > @@ -123,9 +124,13 @@ static int xen_pvclock_gtod_notify(struct notifier_block *nb, > > static struct timespec next_sync; > > > > struct xen_platform_op op; > > - struct timespec now; > > + struct timespec64 now; > > + struct timekeeper *tk = priv; > > + static bool settime64_supported = true; > > + int ret; > > > > - now = __current_kernel_time(); > > + now.tv_sec = tk->xtime_sec; > > + now.tv_nsec = (long)(tk->tkr_mono.xtime_nsec >> tk->tkr_mono.shift); > > I think you should introduce __current_kernel_time64() or make > tk_xtime() available. > > John, what do you think? We already had this discussion: http://marc.info/?l=linux-kernel&m=144717103112014&w=2 http://marc.info/?l=linux-kernel&m=144724877203864&w=2 -- 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/