From patchwork Tue Aug 7 14:34:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexander Aring X-Patchwork-Id: 10558755 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3C1111057 for ; Tue, 7 Aug 2018 14:34:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 29FE428D49 for ; Tue, 7 Aug 2018 14:34:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1D91429A13; Tue, 7 Aug 2018 14:34:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8FD5128D49 for ; Tue, 7 Aug 2018 14:34:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389361AbeHGQt1 (ORCPT ); Tue, 7 Aug 2018 12:49:27 -0400 Received: from mail-it0-f67.google.com ([209.85.214.67]:38303 "EHLO mail-it0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389085AbeHGQt0 (ORCPT ); Tue, 7 Aug 2018 12:49:26 -0400 Received: by mail-it0-f67.google.com with SMTP id v71-v6so23251212itb.3 for ; Tue, 07 Aug 2018 07:34:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mojatatu-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=Mex+PDA0QotlbK8UGzqjd4wkdGg5d8YBlDvigiU2d00=; b=Oky5S2Yy8en7+aTU/si0ge/GSGRM271IzZipzf2kE91IBVJ9Ei+YqqQRFR/r2MnslO XEeYQMGfGb7iM25i3NJqdGSAs/mWaMmCFcirKG/pE17dvmgS4G8c6FQvLbtNzdLLYn20 Lc1E2E8ilPO9/k2WCi0DzvvB5lvyXyPlpBbbEcPsJXm7oBIEXGrV4WZa3evT+iC/pzbD W7sVzqUpDK/eKuqJCNF3lLo0Dr49GL2MlFqaDvH2bNuvSfioZQnaHYVru+8coBe8XphM O3w/cpVb3Z9fChtyXac6ec+pZlUHvfp9fmnDEUJu7Upv1tVqZCPoSnv6QLP16cYAcHKC 4kVg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=Mex+PDA0QotlbK8UGzqjd4wkdGg5d8YBlDvigiU2d00=; b=b0SCWRlzNAEbq2va+3IwojrxPBTkdRfVhb0vO6AEn2hPDvDLPv0Qbft1Bv5gWMRaYY pKrLdrmnFCzwWyQOWnrNwOy9C2UawS7zsGRatJVkis7idZSeKl8CvGPOkhUGM4c1+yeO dioObZmWKJ1JIDcdQcJte/FYMjMAUlgOdkVYgPHKPGQLFzGSd+e06Q15Z0pkly3zm+S8 oOkIq7l3gTTQi22RUVqJ6c8VsAVOOI0l6ra1fcT5buVy4HUe1R+920lLEmkYWRUJmVaS 2V/Q8uRO0/XNC+OkEZi7HbYzIjF9UzHSODXfjEFZYqf7a98jzy0nEqPmsyreInnTh/ML RIhw== X-Gm-Message-State: AOUpUlErfBNAYiOmmD0Hl2JEewMgfaHzGdSwN3K2wB9S1809MYNA7+fq W8mAf8DudgfLGz80EUQ0DZdpqw== X-Google-Smtp-Source: AAOMgpc0/LFxAF1VPwaA1+YSzjsJjXVIX3he0G/FHQieHPh6EnhmNtw3TYsIELodo5Qozwn9NfpVZA== X-Received: by 2002:a02:8ac6:: with SMTP id i6-v6mr16821729jal.122.1533652489854; Tue, 07 Aug 2018 07:34:49 -0700 (PDT) Received: from x220t.lan ([64.26.149.125]) by smtp.gmail.com with ESMTPSA id p70-v6sm1170057itb.3.2018.08.07.07.34.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 07 Aug 2018 07:34:49 -0700 (PDT) From: Alexander Aring To: netdev@vger.kernel.org Cc: linux-wpan@vger.kernel.org, kernel@mojatatu.com, Alexander Aring , Stefan Schmidt Subject: [PATCH net-next] ieee802154: hwsim: fix rcu address annotation Date: Tue, 7 Aug 2018 10:34:44 -0400 Message-Id: <20180807143444.32224-1-aring@mojatatu.com> X-Mailer: git-send-email 2.11.0 Sender: linux-wpan-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wpan@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch fixes the following sparse warning about mismatch rcu attribute for address space annotation: ... error: incompatible types in comparison expression (different modifiers) error: incompatible types in comparison expression (different address spaces) ... Some __rcu annotation was at non-pointers list head structures and one was missing in edge information which is used by rcu_assign_pointer() to update edge setting information. Cc: Stefan Schmidt Fixes: f25da51fdc38 ("ieee802154: hwsim: add replacement for fakelb") Signed-off-by: Alexander Aring Signed-off-by: Stefan Schmidt --- Hopefully I did it right now. Sorry again. drivers/net/ieee802154/mac802154_hwsim.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ieee802154/mac802154_hwsim.c b/drivers/net/ieee802154/mac802154_hwsim.c index 1982308b9b1c..f4e92054f7df 100644 --- a/drivers/net/ieee802154/mac802154_hwsim.c +++ b/drivers/net/ieee802154/mac802154_hwsim.c @@ -36,7 +36,7 @@ MODULE_LICENSE("GPL"); static LIST_HEAD(hwsim_phys); static DEFINE_MUTEX(hwsim_phys_lock); -static __rcu LIST_HEAD(hwsim_ifup_phys); +static LIST_HEAD(hwsim_ifup_phys); static struct platform_device *mac802154hwsim_dev; @@ -68,7 +68,7 @@ struct hwsim_edge_info { struct hwsim_edge { struct hwsim_phy *endpoint; - struct hwsim_edge_info *info; + struct hwsim_edge_info __rcu *info; struct list_head list; struct rcu_head rcu; @@ -81,7 +81,7 @@ struct hwsim_phy { struct hwsim_pib __rcu *pib; bool suspended; - struct list_head __rcu edges; + struct list_head edges; struct list_head list; struct list_head list_ifup;