Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp2302427imm; Wed, 3 Oct 2018 01:30:35 -0700 (PDT) X-Google-Smtp-Source: ACcGV62/MUnTjpbnSby3uhOtNPcvldQK4+JvtyheRqbzWlOjRLOMw44eHLW+s9FkXcaA9Ig5uMeE X-Received: by 2002:a63:e818:: with SMTP id s24-v6mr381630pgh.90.1538555435465; Wed, 03 Oct 2018 01:30:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538555435; cv=none; d=google.com; s=arc-20160816; b=epB4hvRGPe6rS1Y5rE54j7a81bYsqe5ujV57qTvUCNKLpdIxJjqWl6AGTsieXxDiQT 0LujrtbLP0qNHVCnW2RsvdPQ5VxcDHfLwrtLQlIIaTtFgQ1MSiCj0yThr9TTJdsHeUQ5 4X6Wsw1dU6QDYWsA/S4LKCNC9vXZT1iiIfOt+TFGYAhEJfh6kxl7SL6TX8rxgJ99HLQr Tff2b8CjcvaloqhmfFYrC17Qzc58cXrBpjFRrL+MtsrciU2jY2LGIZJd2pocAvUFVPE2 tPhcXoo2e2drIALxptGyB6WDehhiKJ3h/JLyf/QVKEpzh5GFZu9+pq+k3OvFe963xgxf u7FA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=Qnw4RO6D0sADF7cBf/kD2/lFJbRGPLk7ONwpLrB5ZvA=; b=0rsZalcGs0HCnklxezVL4QOESVy9jPgsZLA2X2kCWC+PbF6v0lfyd71pRjMuln7uP1 OBVnTWbK9sSr3xriAdXTZ4GWzkLVOgJHJxW/61UrOSyJwxTrhMrS4wC+TGnAaMf6n7jO sNBrw+dcHM9JUgW3CKJtGhV4X1xl/saPAZWD0l8NhXe2VJIj9ShET6IKnFYwJOJTYVfj kIXacnHD+5zQnyoXOGbX5+ZWLP8fhPG0P4fJDKxiY+60H4o+bK+ak4eQRxVOhvK/RTKi rawB4M3U+GG9SLYH681o5MNfrDQ06VG0RwD8Xy4HLksdSx6mU7s0ysZoxgkYaWZSnvEL oAdQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@blackhole.kfki.hu header.s=20151130 header.b="KIvgpaJ/"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=blackhole.kfki.hu Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a7-v6si843943plp.9.2018.10.03.01.30.20; Wed, 03 Oct 2018 01:30:35 -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; dkim=pass header.i=@blackhole.kfki.hu header.s=20151130 header.b="KIvgpaJ/"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=blackhole.kfki.hu Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727486AbeJCPRY (ORCPT + 99 others); Wed, 3 Oct 2018 11:17:24 -0400 Received: from smtp1.kfki.hu ([148.6.0.26]:37208 "EHLO smtp1.kfki.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727357AbeJCPRY (ORCPT ); Wed, 3 Oct 2018 11:17:24 -0400 Received: from localhost (localhost [127.0.0.1]) by smtp1.kfki.hu (Postfix) with ESMTP id CDDBB3C8008F; Wed, 3 Oct 2018 10:30:00 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= blackhole.kfki.hu; h=mime-version:user-agent:references :message-id:in-reply-to:from:from:date:date:received:received :received; s=20151130; t=1538555398; x=1540369799; bh=Qnw4RO6D0s ADF7cBf/kD2/lFJbRGPLk7ONwpLrB5ZvA=; b=KIvgpaJ/ZAHECeME4e8PUGG0Z3 waRZuX5jzh40w/tZGTWZo8kQsvfHLxgeFsShfvMDWlxsP07eLDI95f4SOGGoEuGI P0tf9ybV2qzHlslh2RYUzslJ4SUN6qRbIi5qRS4nq0xJlYiyStVed/yusYaLKbLw ECn93FQrehmOATkOQ= X-Virus-Scanned: Debian amavisd-new at smtp1.kfki.hu Received: from smtp1.kfki.hu ([127.0.0.1]) by localhost (smtp1.kfki.hu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP; Wed, 3 Oct 2018 10:29:58 +0200 (CEST) Received: from blackhole.kfki.hu (blackhole.szhk.kfki.hu [148.6.240.2]) by smtp1.kfki.hu (Postfix) with ESMTP id 6A4273C80026; Wed, 3 Oct 2018 10:29:58 +0200 (CEST) Received: by blackhole.kfki.hu (Postfix, from userid 1000) id 0698624A6D; Wed, 3 Oct 2018 10:29:57 +0200 (CEST) Date: Wed, 3 Oct 2018 10:29:57 +0200 (CEST) From: Jozsef Kadlecsik To: Lance Roy cc: linux-kernel@vger.kernel.org, "Paul E. McKenney" , Pablo Neira Ayuso , Florian Westphal , "David S. Miller" , netfilter-devel@vger.kernel.org, coreteam@netfilter.org, netdev@vger.kernel.org Subject: Re: [PATCH 14/16] netfilter: Replace spin_is_locked() with lockdep In-Reply-To: <20181003053902.6910-15-ldr709@gmail.com> Message-ID: References: <20181003053902.6910-1-ldr709@gmail.com> <20181003053902.6910-15-ldr709@gmail.com> User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2 Oct 2018, Lance Roy wrote: > lockdep_assert_held() is better suited to checking locking requirements, > since it won't get confused when someone else holds the lock. This is > also a step towards possibly removing spin_is_locked(). > > Signed-off-by: Lance Roy > Cc: Pablo Neira Ayuso > Cc: Jozsef Kadlecsik > Cc: Florian Westphal > Cc: "David S. Miller" > Cc: > Cc: > Cc: > --- > net/netfilter/ipset/ip_set_hash_gen.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Acked-by: Jozsef Kadlecsik Best regards, Jozsef > diff --git a/net/netfilter/ipset/ip_set_hash_gen.h b/net/netfilter/ipset/ip_set_hash_gen.h > index 8a33dac4e805..e287da68d5fa 100644 > --- a/net/netfilter/ipset/ip_set_hash_gen.h > +++ b/net/netfilter/ipset/ip_set_hash_gen.h > @@ -15,7 +15,7 @@ > > #define __ipset_dereference_protected(p, c) rcu_dereference_protected(p, c) > #define ipset_dereference_protected(p, set) \ > - __ipset_dereference_protected(p, spin_is_locked(&(set)->lock)) > + __ipset_dereference_protected(p, lockdep_is_held(&(set)->lock)) > > #define rcu_dereference_bh_nfnl(p) rcu_dereference_bh_check(p, 1) > > -- > 2.19.0 > > - E-mail : kadlec@blackhole.kfki.hu, kadlecsik.jozsef@wigner.mta.hu PGP key : http://www.kfki.hu/~kadlec/pgp_public_key.txt Address : Wigner Research Centre for Physics, Hungarian Academy of Sciences H-1525 Budapest 114, POB. 49, Hungary