From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from Galois.linutronix.de ([146.0.238.70]:36152 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726393AbeK3JsK (ORCPT ); Fri, 30 Nov 2018 04:48:10 -0500 Date: Thu, 29 Nov 2018 23:41:03 +0100 (CET) From: Thomas Gleixner Subject: Re: [PATCH v2 04/28] kernel: Add masks support for Raw and NTP time In-Reply-To: <20181129170530.37789-5-vincenzo.frascino@arm.com> Message-ID: References: <20181129170530.37789-1-vincenzo.frascino@arm.com> <20181129170530.37789-5-vincenzo.frascino@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-arch-owner@vger.kernel.org List-ID: To: Vincenzo Frascino Cc: linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Catalin Marinas , Will Deacon , Arnd Bergmann , Russell King , Ralf Baechle , Paul Burton , Daniel Lezcano , Mark Salyzyn , Peter Collingbourne Message-ID: <20181129224103.lnEPwAxEd4mSJJMxMx1aphHrXEdL1RJKLCeb9Z_h6kc@z> On Thu, 29 Nov 2018, Vincenzo Frascino wrote: > Depending on the clocksource selected there can be supported a > different resolution hence we require a mask to be applied to the > time calculation. > > This patch exposes the mask in the datapage for Raw and NTP adjusted > clock. > > Cc: Arnd Bergmann > Signed-off-by: Vincenzo Frascino > --- > include/vdso/datapage.h | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/include/vdso/datapage.h b/include/vdso/datapage.h > index d50a108afaed..0a7bdccf5773 100644 > --- a/include/vdso/datapage.h > +++ b/include/vdso/datapage.h > @@ -34,6 +34,8 @@ struct vdso_data { > __u64 wtm_clock_nsec; > __u64 btm_nsec; /* Monotonic to boot time */ > __u64 tai_sec; /* International Atomic Time */ > + __u64 cs_mono_mask; /* NTP-adjusted clocksource mask */ > + __u64 cs_raw_mask; /* Raw clocksource mask */ And why would they be different? The core timekeeper has them duplicated purely for access pattern optimization and simplicity. Thanks, tglx