Received: by 2002:a05:6358:5282:b0:b5:90e7:25cb with SMTP id g2csp3406009rwa; Tue, 23 Aug 2022 04:21:43 -0700 (PDT) X-Google-Smtp-Source: AA6agR5OTvWi6JyKM06b93vSRGPH7MNIgJNHUM6D0b+l7y8P/Yyr/c0xCPdj0h4+Mqd38Fo50eBj X-Received: by 2002:a17:902:ef4f:b0:173:353:3f6c with SMTP id e15-20020a170902ef4f00b0017303533f6cmr2029396plx.6.1661253703288; Tue, 23 Aug 2022 04:21:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661253703; cv=none; d=google.com; s=arc-20160816; b=TpnIyLNrYQqHAptb+QqQh7ZBn/o/QY+wMZtsjt3dR2WIpTc8dFICQqUaRpgarUkQiG Oyk+zUjMAjrw+nGcETDit0+8uz++OkTrWcJARlaCwjhkI9PaMJHHoLfdhTK0wNyv368e UAnVFr4Pd6FuOkkjTr+i/EYLwzyG6tGdN4atv+mEXFLBX/GC2RLftNTRSYYu6eGK9fHB OvE+MSN7Y+GKDyrygdZ0DHbLHuD7KTQedmwVSkNTBQvqDlIhSC6sqrxokxZnZBh/kNa9 8qMIap1e1KplqEdjDbCut9jSCWvcRNy7/ot2v+DcTAdR6Sl9TdxBa3ZO1bIY/8A5jIIY Hzbg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=l4LgJ/TF1ye7f9JZCOXVmB1tRONkEq52Q0iWQkQRzcE=; b=RUbkf2AZFal/hff7ZkaLE/yRjwAaUvASdci2iNYHT+omyGySGCi23dgAKFCapu7Rqe gvsxfEzBDMRLsLDC+ZUyMm0Qe2ijAWhj/fQzyTWwrJXCLsQEMI325h1PqG73bKuKU9xA zMYk2jx2Hs6IMz4LWaJ3K8y6LOey/RA288k4agsQCohmSqD13y8tj0y7SWP9L+YthC0l W/sbOQBrY0iplxnz53y7YVVuD3dwpNRz2NLzgXMuyj5/Gt+rfG3Ky4pt5Fnkukb5Wa9H zJTvl6Hc+YUF5LqF8aOyJrzeYdgCl9BJ0i94ELqjv+7t1A8586vo9htqB5ZR+Tz+H1Ac WwuA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=oZddiK43; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b14-20020a056a000a8e00b0052edbdb0910si8618088pfl.128.2022.08.23.04.21.31; Tue, 23 Aug 2022 04:21:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=oZddiK43; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243434AbiHWJzK (ORCPT + 99 others); Tue, 23 Aug 2022 05:55:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42276 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240126AbiHWJvo (ORCPT ); Tue, 23 Aug 2022 05:51:44 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A8D746E2E8; Tue, 23 Aug 2022 01:46:04 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 81326B81C39; Tue, 23 Aug 2022 08:46:04 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C45F7C433D6; Tue, 23 Aug 2022 08:46:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1661244363; bh=bBnAC7qyUS/FWZNSAMQLXtwhOege26wsptCan8PXqi8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oZddiK43ueX4dx/aZUTvKOtgtOllbKTZ1Q8Kdt5yt2AyMq5zfSw6xB1psz/5UJZeW HSHyA7zd1rvN1zlgm3QYXcTIsqN/R6cs8GD/0gvqNt+XWJ2n8DskAslJ1Eshdtqkhh /dUX8RhijKbPQjLJ+P2hXHzaTxA0WRUVZAqnckPk= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, kernel test robot , Florian Westphal , Jakub Kicinski Subject: [PATCH 5.15 079/244] plip: avoid rcu debug splat Date: Tue, 23 Aug 2022 10:23:58 +0200 Message-Id: <20220823080101.686057284@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220823080059.091088642@linuxfoundation.org> References: <20220823080059.091088642@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Florian Westphal commit bc3c8fe3c79bcdae4d90e3726054fac5cca8ac32 upstream. WARNING: suspicious RCU usage 5.2.0-rc2-00605-g2638eb8b50cfc #1 Not tainted drivers/net/plip/plip.c:1110 suspicious rcu_dereference_check() usage! plip_open is called with RTNL held, switch to the correct helper. Fixes: 2638eb8b50cf ("net: ipv4: provide __rcu annotation for ifa_list") Reported-by: kernel test robot Signed-off-by: Florian Westphal Link: https://lore.kernel.org/r/20220807115304.13257-1-fw@strlen.de Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/plip/plip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/plip/plip.c +++ b/drivers/net/plip/plip.c @@ -1107,7 +1107,7 @@ plip_open(struct net_device *dev) /* Any address will do - we take the first. We already have the first two bytes filled with 0xfc, from plip_init_dev(). */ - const struct in_ifaddr *ifa = rcu_dereference(in_dev->ifa_list); + const struct in_ifaddr *ifa = rtnl_dereference(in_dev->ifa_list); if (ifa != NULL) { memcpy(dev->dev_addr+2, &ifa->ifa_local, 4); }