From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753991AbbELVSX (ORCPT ); Tue, 12 May 2015 17:18:23 -0400 Received: from e34.co.us.ibm.com ([32.97.110.152]:56851 "EHLO e34.co.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753741AbbELVSU (ORCPT ); Tue, 12 May 2015 17:18:20 -0400 Date: Tue, 12 May 2015 14:18:14 -0700 From: "Paul E. McKenney" To: linux-kernel@vger.kernel.org Cc: mingo@kernel.org, laijs@cn.fujitsu.com, dipankar@in.ibm.com, akpm@linux-foundation.org, mathieu.desnoyers@efficios.com, josh@joshtriplett.org, tglx@linutronix.de, peterz@infradead.org, rostedt@goodmis.org, dhowells@redhat.com, edumazet@google.com, dvhart@linux.intel.com, fweisbec@gmail.com, oleg@redhat.com, bobby.prani@gmail.com Subject: [PATCH tip/core/rcu 0/4] Array-based RCU removals for 4.2 Message-ID: <20150512211814.GA31939@linux.vnet.ibm.com> Reply-To: paulmck@linux.vnet.ibm.com MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15051221-0017-0000-0000-00000ABDC838 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello! This series removes the sole use of RCU-protected array indexes. It turns out that this use is in x86 code, so smp_load_acquire() works just as well, and this allows removing a troublesome aspect of the RCU API. This removal should in turn allow compilers to better grok RCU dependency chains. For example, expressions like (x-x), (x*0), and (x%1) can result in valid array indexes, but cannot produce valid pointers. 1. Make x86's MCE code use smp_load_acuire() and READ_ONCE() in place of the RCU API members intended to handle RCU-protected array indexes. 2. Eliminates the RCU API members supporting RCU-protected array indexes, namely rcu_access_index() and rcu_dereference_index_check(). 3. Updates the RCU documentation to reflect #2 above. 4. Makes one of the modified functions be static, courtesy of Fengguang Wu. Thanx, Paul ------------------------------------------------------------------------ b/Documentation/RCU/arrayRCU.txt | 20 ++++++++++-- b/Documentation/RCU/lockdep.txt | 10 ------ b/Documentation/RCU/rcu_dereference.txt | 33 +++++++-------------- b/Documentation/RCU/whatisRCU.txt | 2 - b/arch/x86/kernel/cpu/mcheck/mce.c | 15 +++++---- b/include/linux/rcupdate.h | 50 -------------------------------- 6 files changed, 37 insertions(+), 93 deletions(-)