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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iLO35LxKCp+4_1bh0MiSOhZzB5N2u_10xVT5su_drDE=w@mail.gmail.com>
Date:	Tue, 30 Jun 2015 23:56:37 +0200
From:	Eric Dumazet <edumazet@...gle.com>
To:	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Ingo Molnar <mingo@...nel.org>, laijs@...fujitsu.com,
	dipankar@...ibm.com, Andrew Morton <akpm@...ux-foundation.org>,
	mathieu.desnoyers@...icios.com, josh@...htriplett.org,
	Thomas Gleixner <tglx@...utronix.de>, peterz@...radead.org,
	rostedt@...dmis.org, dhowells@...hat.com, dvhart@...ux.intel.com,
	fweisbec@...il.com, oleg@...hat.com, bobby.prani@...il.com
Subject: Re: [PATCH RFC tip/core/rcu 5/5] rcu: Limit expedited helping to
 every 10 ms or every 4th GP

On Tue, Jun 30, 2015 at 11:48 PM, Paul E. McKenney
<paulmck@...ux.vnet.ibm.com> wrote:
> From: "Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
>
> Signed-off-by: Paul E. McKenney <paulmck@...ux.vnet.ibm.com>
> ---
>  kernel/rcu/tree.c | 15 ++++++++++++---
>  1 file changed, 12 insertions(+), 3 deletions(-)
>
> diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
> index 308b6acb4260..247aa1120c4c 100644
> --- a/kernel/rcu/tree.c
> +++ b/kernel/rcu/tree.c
> @@ -3505,10 +3505,19 @@ void synchronize_sched_expedited(void)
>                            !atomic_read(&rsp->expedited_need_qs));
>
>         rcu_exp_gp_seq_end(rsp);
> -       mutex_unlock(&rnp->exp_funnel_mutex);
>         smp_mb(); /* ensure subsequent action seen after grace period. */
> -       if (rsp->gp_kthread && rcu_gp_in_progress(rsp))
> -               wake_up(&rsp->gp_wq);
> +       if (rsp->gp_kthread && rcu_gp_in_progress(rsp)) {
> +               static unsigned long nextgp;
> +               static unsigned long nextjiffy;
> +
> +               if (time_after_eq(jiffies, nextgp) ||
> +                   ULONG_CMP_GE(rsp->gpnum, nextgp)) {
> +                       nextgp = rsp->gpnum + 4;
> +                       nextjiffy = jiffies + 10;

Do you want 10 ticks or 10 ms (as stated in title) ?

> +                       wake_up(&rsp->gp_wq);
> +               }
> +       }
> +       mutex_unlock(&rnp->exp_funnel_mutex);
>
>         put_online_cpus();
>  }
> --
> 1.8.1.5
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ