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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 12 May 2021 21:18:15 +0800
From:   Feng Tang <feng.tang@...el.com>
To:     "Paul E. McKenney" <paulmck@...nel.org>
Cc:     tglx@...utronix.de, linux-kernel@...r.kernel.org,
        john.stultz@...aro.org, sboyd@...nel.org, corbet@....net,
        Mark.Rutland@....com, maz@...nel.org, kernel-team@...com,
        neeraju@...eaurora.org, ak@...ux.intel.com,
        zhengjun.xing@...el.com,
        Xing Zhengjun <zhengjun.xing@...ux.intel.com>
Subject: Re: [PATCH v14 clocksource 4/6] clocksource: Reduce clocksource-skew
 threshold for TSC

Hi Paul,

On Tue, May 11, 2021 at 08:51:56PM -0700, Paul E. McKenney wrote:
> On Wed, May 12, 2021 at 10:18:49AM +0800, Feng Tang wrote:
> > Hi Paul,
> > 
> > On Tue, May 11, 2021 at 04:34:53PM -0700, Paul E. McKenney wrote:

[SNIP]
> > >  	 * Ensure clocksources that have large 'mult' values don't overflow
> > >  	 * when adjusted.
> > > diff --git a/kernel/time/jiffies.c b/kernel/time/jiffies.c
> > > index a492e4da69ba..b3f608c2b936 100644
> > > --- a/kernel/time/jiffies.c
> > > +++ b/kernel/time/jiffies.c
> > > @@ -49,13 +49,14 @@ static u64 jiffies_read(struct clocksource *cs)
> > >   * for "tick-less" systems.
> > >   */
> > >  static struct clocksource clocksource_jiffies = {
> > > -	.name		= "jiffies",
> > > -	.rating		= 1, /* lowest valid rating*/
> > > -	.read		= jiffies_read,
> > > -	.mask		= CLOCKSOURCE_MASK(32),
> > > -	.mult		= TICK_NSEC << JIFFIES_SHIFT, /* details above */
> > > -	.shift		= JIFFIES_SHIFT,
> > > -	.max_cycles	= 10,
> > > +	.name			= "jiffies",
> > > +	.rating			= 1, /* lowest valid rating*/
> > > +	.uncertainty_margin	= TICK_NSEC,
> > 
> > 'jiffies' is known to be very bad as a watchdog ("worse bandaid" in
> > Thomas' words :)), and TICK_NSEC just turns to 1ms for HZ=1000 case. 
> > Maybe we should give it a bigger margin, like the 32ms margin for 
> > 'tsc-early'?
> > 
> > Other than this, it looks good to me, thanks!
> 
> As in the fixup diff below?

Yep, thanks,

> 
> Would you be willing to provide an ack or tested-by for the rest
> of the series?  (I have your ack on 1/6.)

I haven't figured out a way to check 5/6 patch yet, but feel free
to add my ack for the first 4 patches (1/6 ~ 4/6) 

	Acked-by: Feng Tang <feng.tang@...el.com>

Thanks,
Feng

> 
> 						Thanx, Paul
> 
> ------------------------------------------------------------------------
> 
> diff --git a/kernel/time/jiffies.c b/kernel/time/jiffies.c
> index b3f608c2b936..01935aafdb46 100644
> --- a/kernel/time/jiffies.c
> +++ b/kernel/time/jiffies.c
> @@ -51,7 +51,7 @@ static u64 jiffies_read(struct clocksource *cs)
>  static struct clocksource clocksource_jiffies = {
>  	.name			= "jiffies",
>  	.rating			= 1, /* lowest valid rating*/
> -	.uncertainty_margin	= TICK_NSEC,
> +	.uncertainty_margin	= 32 * NSEC_PER_MSEC,
>  	.read			= jiffies_read,
>  	.mask			= CLOCKSOURCE_MASK(32),
>  	.mult			= TICK_NSEC << JIFFIES_SHIFT, /* details above */

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ