summaryrefslogtreecommitdiff
path: root/contrib/SDL-3.2.8/src/hidapi/netbsd/README.md
diff options
context:
space:
mode:
author3gg <3gg@shellblade.net>2025-12-27 12:03:39 -0800
committer3gg <3gg@shellblade.net>2025-12-27 12:03:39 -0800
commit5a079a2d114f96d4847d1ee305d5b7c16eeec50e (patch)
tree8926ab44f168acf787d8e19608857b3af0f82758 /contrib/SDL-3.2.8/src/hidapi/netbsd/README.md
Initial commit
Diffstat (limited to 'contrib/SDL-3.2.8/src/hidapi/netbsd/README.md')
-rw-r--r--contrib/SDL-3.2.8/src/hidapi/netbsd/README.md29
1 files changed, 29 insertions, 0 deletions
diff --git a/contrib/SDL-3.2.8/src/hidapi/netbsd/README.md b/contrib/SDL-3.2.8/src/hidapi/netbsd/README.md
new file mode 100644
index 0000000..f1b12a0
--- /dev/null
+++ b/contrib/SDL-3.2.8/src/hidapi/netbsd/README.md
@@ -0,0 +1,29 @@
1Implementation Notes
2--------------------
3NetBSD maps every `uhidev` device to one or more `uhid`
4devices. Each `uhid` device only supports one report ID.
5The parent device `uhidev` creates one `uhid` device per
6report ID found in the hardware's report descriptor.
7
8In the event there are no report ID(s) found within the
9report descriptor, only one `uhid` device with a report ID
10of `0` is created.
11
12In order to remain compatible with existing `hidapi` APIs,
13all the `uhid` devices created by the parent `uhidev` device
14must be opened under the same `hid_device` instance to ensure
15that we can route reports to their appropriate `uhid` device.
16
17Internally the `uhid` driver will insert the report ID as
18needed so we must also omit the report ID in any situation
19where the `hidapi` API expects it to be included in the
20report data stream.
21
22Given the design of `uhid`, it must be augmented with extra
23platform specific APIs to ensure that the exact relationship
24between `uhidev` devices and `uhid` devices can be determined.
25
26The NetBSD implementation does this via the `drvctl` kernel
27driver. At present there is no known way to do this on OpenBSD
28for a `uhid` implementation to be at the same level as the
29NetBSD one.