Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752744AbbERNne (ORCPT ); Mon, 18 May 2015 09:43:34 -0400 Received: from smtprelay0184.hostedemail.com ([216.40.44.184]:33542 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750854AbbERNn0 (ORCPT ); Mon, 18 May 2015 09:43:26 -0400 X-Session-Marker: 726F737465647440676F6F646D69732E6F7267 X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,rostedt@goodmis.org,:::::::::::::::::::::::::::::::::::::,RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2393:2553:2559:2562:2899:3138:3139:3140:3141:3142:3353:3622:3865:3866:3867:3868:3870:3871:3872:3873:3874:4605:5007:6261:6742:7875:8531:8957:9010:9121:10004:10400:10848:10967:11026:11232:11658:11914:12296:12517:12519:12663:12740:13069:13138:13161:13229:13231:13311:13357:14096:14097:21067:21080,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0 X-HE-Tag: start30_57cbd0959885a X-Filterd-Recvd-Size: 2746 Date: Mon, 18 May 2015 09:43:21 -0400 From: Steven Rostedt To: NeilBrown Cc: Patrick Marlier , "Paul E. McKenney" , linux-kernel@vger.kernel.org, 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, dhowells@redhat.com, edumazet@google.com, dvhart@linux.intel.com, fweisbec@gmail.com, oleg@redhat.com, bobby.prani@gmail.com, wangyun@linux.vnet.ibm.com Subject: Re: [PATCH tip/core/rcu 3/4] md/bitmap: Fix list_entry_rcu usage Message-ID: <20150518094321.2012a66a@gandalf.local.home> In-Reply-To: <20150518120647.0c3cecd8@notabene.brown> References: <20150512224603.GA4531@linux.vnet.ibm.com> <1431470787-4702-1-git-send-email-paulmck@linux.vnet.ibm.com> <1431470787-4702-3-git-send-email-paulmck@linux.vnet.ibm.com> <20150512223853.55e0ed90@grimm.local.home> <20150513125839.371ef677@notabene.brown> <5557819E.1060001@gmail.com> <20150518120647.0c3cecd8@notabene.brown> X-Mailer: Claws Mail 3.11.1 (GTK+ 2.24.25; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1434 Lines: 47 On Mon, 18 May 2015 12:06:47 +1000 NeilBrown wrote: > > struct mddev { > > ... > > struct list_head disks; > > ...} > > > > struct list_head { > > struct list_head *next, *prev; > > }; > > > > The tricky thing is that "list_entry_rcu" before and after the patch is > > reading the same thing. > > No it isn't. > Before the patch it is passed the address of the 'next' field. After the > patch it is passed the contents of the 'next' field. Right. > > > > > > However in your case, the change I proposed is probably wrong I trust > > you on this side. :) What's your proposal to fix it with the rculist patch? > > What needs fixing? I don't see anything broken. > > Maybe there is something in this "rculist patch" that I'm missing. Can you > point me at it? > Probably some debugging tool like sparse notices that the assignment isn't a true list entry and complains about it. In other words, I think the real fix is to fix the debugging tool to ignore this, because the code is correct, and this is a false positive failure, and is causing more harm than good, because people are sending out broken patches due to it. -- Steve -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/