Page MenuHomeFreeBSD

hid: Import iichid - I2C transport backend for HID subsystem
ClosedPublic

Authored by wulf on Jan 2 2021, 12:08 PM.

Details

Summary

This implements hid_if.m methods for HID-over-I2C protocol [1].

Following kernel options are added:

IICHID_SAMPLING - Enable support for a sampling mode as interrupt
                  resource acquisition is not always possible in a case
                  of GPIO interrupts.
IICHID_DEBUG    - Enable debug output.

The module is substantially based on Marc Priggemeyer's work (D16698).

[1] http://download.microsoft.com/download/7/d/d/7dd44bb7-2a7a-4505-ac1c-7227d3d96d5b/hid-over-i2c-protocol-spec-v1-0.docx

Diff Detail

Repository
R10 FreeBSD src repository
Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

wulf requested review of this revision.Jan 2 2021, 12:08 PM
sys/dev/iicbus/iichid.c
77

You can change:
DPRINTFN((sc), 1, VA_ARGS)
Into:
DPRINTFN(sc, 1, VA_ARGS)

At this level, the macro arguments are already comma separated.

79

please use do {} while (0) for these!

wulf marked 2 inline comments as done.
wulf added inline comments.
sys/dev/iicbus/iichid.c
77

Done

79

Done

This revision was not accepted when it landed; it landed in state Needs Review.Jan 7 2021, 11:22 PM
This revision was automatically updated to reflect the committed changes.
wulf marked 2 inline comments as done.