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: <20190621235955.GK26519@linux.ibm.com>
Date:   Fri, 21 Jun 2019 16:59:55 -0700
From:   "Paul E. McKenney" <paulmck@...ux.ibm.com>
To:     Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Cc:     Scott Wood <swood@...hat.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Steven Rostedt <rostedt@...dmis.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Juri Lelli <juri.lelli@...hat.com>,
        Clark Williams <williams@...hat.com>,
        linux-rt-users@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH RT 4/4] rcutorture: Avoid problematic critical
 section nesting

On Fri, Jun 21, 2019 at 06:38:21PM +0200, Sebastian Andrzej Siewior wrote:
> On 2019-06-20 14:18:26 [-0700], Paul E. McKenney wrote:
> > > Example #1:
> > > 
> > > 1. preempt_disable()
> > > 2. local_bh_disable()
> > > 3. preempt_enable()
> > > 4. local_bh_enable()
> > > 
> > > Example #2:
> > > 
> > > 1. rcu_read_lock()
> > > 2. local_irq_disable()
> > > 3. rcu_read_unlock()
> > > 4. local_irq_enable()
> > > 
> > > Example #3:
> > > 
> > > 1. preempt_disable()
> > > 2. local_irq_disable()
> > > 3. preempt_enable()
> > > 4. local_irq_enable()
> > 
> > OK for -rt, but as long as people can code those sequences without getting
> > their wrists slapped, RCU needs to deal with it.  So I cannot accept
> > this in mainline at the current time.  Yes, I will know when it is safe
> > to accept it when rcutorture's virtual wrist gets slapped in mainline.
> 
> All three examples are not symmetrical so if people use this mainline
> then they should get their wrists slapped. Since RT trips over each one
> of those I try to get rid of them if I notice something like that.
> 
> In example #3 you would lose a scheduling event if TIF_NEED_RESCHED gets
> set between step 1 and 2 (as local schedule requirement) because the
> preempt_enable() would trigger schedule() which does not happen due to
> IRQ-off.

I have no objection to the outlawing of a number of these sequences in
mainline, but am rather pointing out that until they really are outlawed
and eliminated, rcutorture must continue to test them in mainline.
Of course, an rcutorture running in -rt should avoid testing things that
break -rt, including these sequences.

							Thanx, Paul

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ