Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp583423pxj; Thu, 13 May 2021 11:49:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwcGjcj7nnWAvoUXfF3OtGw0vwqHsPWi1XvBJeOQDDVAEoMAVyKmmHK2fjaGZcm5CMwcXjD X-Received: by 2002:a9d:6f03:: with SMTP id n3mr9785267otq.6.1620931792929; Thu, 13 May 2021 11:49:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620931792; cv=none; d=google.com; s=arc-20160816; b=YNh00U3wP8WIxebXhOBkcn+iDe8PYay5gJCxwhqYdf1QQdPEDbl4v44XX41eeTxwtP sFA/VAmr+TX1nkWRReV840xLxecqtMKJLPGX/U4+lOmrsswuY/AZZo7xogWjU0ItOSsQ a1ZT0AklR2+0ztI1U+6qCjfKNMAonYIfHrjVemjXYGOJ+Y6FgZCTWVOgBvvGj1p+WYIs BdznTWMv4poB4GYUiriDej0BHBTSDSQZ+q8FET8Kio3Y6anCK7eEfiBNvaMExMvSeX+o 0RG+ENS18oJoVkKbBG0/IrTIO/n6XBpxokylfskHzET3vznulV6RSfGjq15d09QColJs 38rQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=viCC58y2gJkN73DCwzzTp4cS9y0Teil8fH/dtD2ASwg=; b=fv9o3SkXe7juaUGpnOBtA5z48EBEwxQjflGMGaHLrGUeKcgQan5y0Qz3050L8tSipD UQRtuOTgXFsihnNB98FbG3/dxvoI94mbSoEl/wJo4PTYsJZZGcxgxFRzl6hCfE4Zd6+5 oY5xZEmpuXbX/vQYI37wCySz2y5H+BrC6rFl2++bowmXENdJaIjN7NL4umm6KvkdF2hW VLlOj5pOMgStGdOMmwPWkiWtz3UN+RmwxdE/8NMsFbUPPXY70qrfhsUznN1eF1EuWHmr 7Au/zT27OjaMcCGgwd0Gy/ya56lv1OWDTvJ5mT7nAcp4P+vvg6E8I4qpu/NAh29DILTU AFHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=yWCKSgOo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k16si4202717otp.29.2021.05.13.11.49.38; Thu, 13 May 2021 11:49:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=yWCKSgOo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S233131AbhEML1t (ORCPT + 99 others); Thu, 13 May 2021 07:27:49 -0400 Received: from mail.kernel.org ([198.145.29.99]:41394 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232340AbhEML1l (ORCPT ); Thu, 13 May 2021 07:27:41 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 6BD71613DE; Thu, 13 May 2021 11:26:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1620905190; bh=eXSAetXGIYK5LnUNOnxaqqmbAirQeIHFyQvJIrjRgRE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=yWCKSgOoKhNC2z+tE0cB2g0gLWejzEQKbWtzsAfkIMOUfUxZFLPqT2MDVCVdEVyBb Q5Cf16R02c7tz92SIgd+t+5SmtcRB6kaJwmyoZSNuSzMqNpvsgXnP+A2x1cmQCcIhn LHfdx9pHG4ul35SzCczpUGZMS3nd2JgJRSKqMjI4= Date: Thu, 13 May 2021 13:26:28 +0200 From: Greg Kroah-Hartman To: Ruiqi Gong Cc: Wang Weiyang , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH -next] drivers/base/node.c: make CACHE_ATTR define static DEVICE_ATTR_RO Message-ID: References: <20210513110716.25791-1-gongruiqi1@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210513110716.25791-1-gongruiqi1@huawei.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 13, 2021 at 07:07:16PM +0800, Ruiqi Gong wrote: > The Sparse tool reports as follows: > > drivers/base/node.c:239:1: warning: > symbol 'dev_attr_line_size' was not declared. Should it be static? > drivers/base/node.c:240:1: warning: > symbol 'dev_attr_indexing' was not declared. Should it be static? > > These symbols (and several others) are defined by DEVICE_ATTR_RO(name) in > CACHE_ATTR(name, fmt), and all of them are not used outside of node.c. So let's > mark DEVICE_ATTR_RO(name) static to solve these complains from Sparse. Why not fix them all at once? Why only one here? thanks, greg k-h