[RFC PATCH t-kristo-pm] HID: hid_prog_ops can be static

From: kernel test robot
Date: Sat Dec 04 2021 - 08:05:59 EST


drivers/hid/hid-bpf.c:151:27: warning: symbol 'hid_prog_ops' was not declared. Should it be static?
drivers/hid/hid-bpf.c:184:31: warning: symbol 'hid_verifier_ops' was not declared. Should it be static?

Fixes: 1995666cad0e ("HID: initial BPF implementation")
Reported-by: kernel test robot <lkp@xxxxxxxxx>
Signed-off-by: kernel test robot <lkp@xxxxxxxxx>
---
hid-bpf.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/hid/hid-bpf.c b/drivers/hid/hid-bpf.c
index 8792cb5eacd20..fd12a2059d66f 100644
--- a/drivers/hid/hid-bpf.c
+++ b/drivers/hid/hid-bpf.c
@@ -148,7 +148,7 @@ static int hid_bpf_prog_query(struct hid_device *hdev, const union bpf_attr *att

}

-const struct bpf_prog_ops hid_prog_ops = {
+static const struct bpf_prog_ops hid_prog_ops = {
};

static const struct bpf_func_proto *
@@ -181,7 +181,7 @@ static bool hid_is_valid_access(int off, int size,
return true;
}

-const struct bpf_verifier_ops hid_verifier_ops = {
+static const struct bpf_verifier_ops hid_verifier_ops = {
.get_func_proto = hid_func_proto,
.is_valid_access = hid_is_valid_access
};