diff options
author | Nick Desaulniers <ndesaulniers@google.com> | 2023-08-08 19:22:59 +0200 |
---|---|---|
committer | Richard Weinberger <richard@nod.at> | 2023-08-26 22:43:42 +0200 |
commit | b10eee784c767975d345540e5569bdad31b9aec3 (patch) | |
tree | b60374ba83914667531678306e5344de17155ceb /arch/um | |
parent | um: vector: refactor deprecated strncpy (diff) | |
download | linux-b10eee784c767975d345540e5569bdad31b9aec3.tar.xz linux-b10eee784c767975d345540e5569bdad31b9aec3.zip |
uml: audio: fix -Wmissing-variable-declarations
I'm looking to enable -Wmissing-variable-declarations behind W=1. 0day
bot spotted the following instance:
arch/um/drivers/hostaudio_kern.c:316:3: warning: no previous extern
declaration for non-static variable 'module_data'
[-Wmissing-variable-declarations]
} module_data;
^
arch/um/drivers/hostaudio_kern.c:313:1: note: declare 'static' if the
variable is not intended to be used outside of this translation unit
struct {
^
This symbol is not referenced by more than one translation unit, so give
it static storage.
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/llvm/202308081050.sZEw4cQ5-lkp@intel.com/
Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Diffstat (limited to 'arch/um')
-rw-r--r-- | arch/um/drivers/hostaudio_kern.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/um/drivers/hostaudio_kern.c b/arch/um/drivers/hostaudio_kern.c index 5b064d360cb7..c42b793bce65 100644 --- a/arch/um/drivers/hostaudio_kern.c +++ b/arch/um/drivers/hostaudio_kern.c @@ -310,7 +310,7 @@ static const struct file_operations hostmixer_fops = { .release = hostmixer_release, }; -struct { +static struct { int dev_audio; int dev_mixer; } module_data; |