Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp2748876ybi; Sun, 2 Jun 2019 00:11:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqyhIQUTZqZ5pT+s28T0ZmWgVTevARsKZq415IgnXEcPRhcGrOBxfFY2/5fO7C6z77te/w5N X-Received: by 2002:aa7:824b:: with SMTP id e11mr20859809pfn.33.1559459467916; Sun, 02 Jun 2019 00:11:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559459467; cv=none; d=google.com; s=arc-20160816; b=xSpbNF2npO9bhMtGYJalNVulVYBzp+bwl4SDosjyXKA3NyobRA5G697GTwhuppBdeS Vh8HQXs276Rk8EX6o1Gp3X8xFpQiVryQOhOeZHHPOlPSTPYxjUOMtxYlX4cILgPwRGYS JpE61O1GmZ1vRwVXh8BBf+7KqRxAzzUtuYFHiyOZXX8wjoGBBIOJC0tZdDnJbGZvzamM pbYCRFoMbs2LDdVOZK4VzEeIR5MiGcPsrBIZjNeKCLyAxQcecNOvMyhHGSHrAvlFLZ9/ JGJMEdJRC32uTtcTbw3aKF3/kAvIreIRsyKmZd23KBQ+GBIKPRRCrgvAvQa4okxaNsl/ 3zWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=XtnoLvZ2c/cA9yL15PxsBSgAbs/ilaxDXPJ12O9xvLM=; b=vDAR2hSLxecWyeitLT3niSYWw3ka4mwh/ITEBcaW+QPILo+vTrZaofrNRMVRy9gr8e 4gUVHgb/MY6bA7vgTe/UhYweFfkuHVbZ61cPkheVbguPkgSuHoDmNnjVYJRv+FfpDhMI K27TEJjkIF6Ip8zzKhJ+2YOd3ER8iCIFC3GEoCwsZ+1ixJRpyrImK4GCoNU8TEe8NxOd AHtW8RVvSRJH35esT7Xnvip8iZKM0/daR6BkBDezbhMJTUkZmfcUEN7kJfYYnvx0W9mZ KELlLnviZRTx1JPMSRn386dDGheJoZRjvB2EYhFrDerx+/H6KIguRadSFp4h8XlPqgDc Tdaw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d26si4248125pgl.542.2019.06.02.00.10.22; Sun, 02 Jun 2019 00:11:07 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726212AbfFBHHQ (ORCPT + 99 others); Sun, 2 Jun 2019 03:07:16 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:52690 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725871AbfFBHHQ (ORCPT ); Sun, 2 Jun 2019 03:07:16 -0400 Received: by atrey.karlin.mff.cuni.cz (Postfix, from userid 512) id 09A7780353; Sun, 2 Jun 2019 09:00:04 +0200 (CEST) Date: Sun, 2 Jun 2019 09:00:14 +0200 From: Pavel Machek To: "Joel Fernandes (Google)" Cc: linux-kernel@vger.kernel.org, Alexey Kuznetsov , Bjorn Helgaas , Borislav Petkov , "David S. Miller" , edumazet@google.com, Greg Kroah-Hartman , Hideaki YOSHIFUJI , "H. Peter Anvin" , Ingo Molnar , Josh Triplett , keescook@chromium.org, kernel-hardening@lists.openwall.com, Lai Jiangshan , Len Brown , linux-acpi@vger.kernel.org, linux-pci@vger.kernel.org, linux-pm@vger.kernel.org, Mathieu Desnoyers , neilb@suse.com, netdev@vger.kernel.org, oleg@redhat.com, "Paul E. McKenney" , peterz@infradead.org, "Rafael J. Wysocki" , rcu@vger.kernel.org, Steven Rostedt , Tejun Heo , Thomas Gleixner , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" Subject: Re: [RFC 2/6] ipv4: add lockdep condition to fix for_each_entry Message-ID: <20190602070014.GA543@amd> References: <20190601222738.6856-1-joel@joelfernandes.org> <20190601222738.6856-3-joel@joelfernandes.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="u3/rZRmxL6MmkK24" Content-Disposition: inline In-Reply-To: <20190601222738.6856-3-joel@joelfernandes.org> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --u3/rZRmxL6MmkK24 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat 2019-06-01 18:27:34, Joel Fernandes (Google) wrote: > Signed-off-by: Joel Fernandes (Google) This really needs to be merged to previous patch, you can't break compilation in middle of series... Or probably you need hlist_for_each_entry_rcu_lockdep() macro with additional argument, and switch users to it. Pavel > net/ipv4/fib_frontend.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) >=20 > diff --git a/net/ipv4/fib_frontend.c b/net/ipv4/fib_frontend.c > index b298255f6fdb..ef7c9f8e8682 100644 > --- a/net/ipv4/fib_frontend.c > +++ b/net/ipv4/fib_frontend.c > @@ -127,7 +127,8 @@ struct fib_table *fib_get_table(struct net *net, u32 = id) > h =3D id & (FIB_TABLE_HASHSZ - 1); > =20 > head =3D &net->ipv4.fib_table_hash[h]; > - hlist_for_each_entry_rcu(tb, head, tb_hlist) { > + hlist_for_each_entry_rcu(tb, head, tb_hlist, > + lockdep_rtnl_is_held()) { > if (tb->tb_id =3D=3D id) > return tb; > } --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --u3/rZRmxL6MmkK24 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlzzc/4ACgkQMOfwapXb+vLLpgCfQoWBSykNcFHCJ34MeV9TE4Es /qIAn1NEzcdOi5m4WfplnoKX79226+10 =Uigu -----END PGP SIGNATURE----- --u3/rZRmxL6MmkK24--