]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
media: venus: place extern venus_fw_debug on a header file
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 1 Sep 2020 10:33:20 +0000 (12:33 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 3 Sep 2020 09:09:54 +0000 (11:09 +0200)
Sparse warns about this symbol:

drivers/media/platform/qcom/venus/hfi_venus.c:133:5:  warning: symbol 'venus_fw_debug' was not declared. Should it be static?

Because hfi_venus.c doesn't include a header file with the
extern. So, move it to core.h, with is included by both
hfi_venus.c and dbgfs.c.

This way, if something changes with it, warnings or errors
will be produced.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/platform/qcom/venus/core.h
drivers/media/platform/qcom/venus/dbgfs.c

index 8e75a199f9f7c84d5fad19ae81ed29a097e171b8..1a7aee7ee628fed7a6647ecf1d20ae02e6692bf3 100644 (file)
@@ -24,6 +24,8 @@
 #define VIDC_VCODEC_CLKS_NUM_MAX       2
 #define VIDC_PMDOMAINS_NUM_MAX         3
 
+extern int venus_fw_debug;
+
 struct freq_tbl {
        unsigned int load;
        unsigned long freq;
index 782d54ac1b8f6170d771b29349211c76fe100168..52de47f2ca8893d7b154665cd2a3468ed40fd166 100644 (file)
@@ -7,8 +7,6 @@
 
 #include "core.h"
 
-extern int venus_fw_debug;
-
 void venus_dbgfs_init(struct venus_core *core)
 {
        core->root = debugfs_create_dir("venus", NULL);