aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYu Liao <[email protected]>2023-08-02 10:26:49 +0800
committerTakashi Iwai <[email protected]>2023-08-02 09:27:39 +0200
commitd28dc3d87fe298d0bd83c33738c0c09a0e4f7bdb (patch)
tree4f0599b64ffbf47a00ed31886ae549f92d651408
parentfbeb1ec85dc6079b44766e225104bfdc8ea9fe6c (diff)
ALSA: ac97: set variables dev_attr_vendor_id to static
sparse reports sound/ac97/bus.c:465:1: sparse: sparse: symbol 'dev_attr_vendor_id' was not declared. Should it be static? This variable is only used in its defining file, so it should be static. Reported-by: kernel test robot <[email protected]> Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Signed-off-by: Yu Liao <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Takashi Iwai <[email protected]>
-rw-r--r--sound/ac97/bus.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/ac97/bus.c b/sound/ac97/bus.c
index 6067c04ce4c0..3173e9d98927 100644
--- a/sound/ac97/bus.c
+++ b/sound/ac97/bus.c
@@ -462,7 +462,7 @@ static ssize_t vendor_id_show(struct device *dev,
return sysfs_emit(buf, "%08x", codec->vendor_id);
}
-DEVICE_ATTR_RO(vendor_id);
+static DEVICE_ATTR_RO(vendor_id);
static struct attribute *ac97_dev_attrs[] = {
&dev_attr_vendor_id.attr,