summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorBenjamin Tissoires <bentiss@kernel.org>2024-03-15 17:44:39 +0300
committerBenjamin Tissoires <bentiss@kernel.org>2024-04-10 17:37:14 +0300
commit5599f80196612efde96dbe6ef18f6ecc0cb4ba19 (patch)
tree0176fb7c39f14a4f325742deec12adcbf4c38892 /include/linux
parent4171954f56fb6da8cc8ceebf54b78b874278a198 (diff)
downloadlinux-5599f80196612efde96dbe6ef18f6ecc0cb4ba19.tar.xz
HID: bpf: export hid_hw_output_report as a BPF kfunc
We currently only export hid_hw_raw_request() as a BPF kfunc. However, some devices require an explicit write on the Output Report instead of the use of the control channel. So also export hid_hw_output_report to BPF Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-2-079c282469d3@kernel.org Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/hid_bpf.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/hid_bpf.h b/include/linux/hid_bpf.h
index 7118ac28d468..5c7ff93dc73e 100644
--- a/include/linux/hid_bpf.h
+++ b/include/linux/hid_bpf.h
@@ -103,6 +103,7 @@ struct hid_bpf_ops {
unsigned char reportnum, __u8 *buf,
size_t len, enum hid_report_type rtype,
enum hid_class_request reqtype);
+ int (*hid_hw_output_report)(struct hid_device *hdev, __u8 *buf, size_t len);
struct module *owner;
const struct bus_type *bus_type;
};