summaryrefslogtreecommitdiff
path: root/include/linux/hid_bpf.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/hid_bpf.h')
-rw-r--r--include/linux/hid_bpf.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/hid_bpf.h b/include/linux/hid_bpf.h
index 3ca85ab91325..e9afb61e6ee0 100644
--- a/include/linux/hid_bpf.h
+++ b/include/linux/hid_bpf.h
@@ -3,6 +3,7 @@
#ifndef __HID_BPF_H
#define __HID_BPF_H
+#include <linux/bpf.h>
#include <linux/spinlock.h>
#include <uapi/linux/hid.h>
@@ -138,6 +139,12 @@ struct hid_bpf {
spinlock_t progs_lock; /* protects RCU update of progs */
};
+/* specific HID-BPF link when a program is attached to a device */
+struct hid_bpf_link {
+ struct bpf_link link;
+ int hid_table_index;
+};
+
#ifdef CONFIG_HID_BPF
u8 *dispatch_hid_bpf_device_event(struct hid_device *hid, enum hid_report_type type, u8 *data,
u32 *size, int interrupt);