HomeFreeBSD

wmt(4): Use internal function to calculate input report size

Description

wmt(4): Use internal function to calculate input report size

Usbhid's hid_report_size() calculates integral size of all reports of given
kind found in the HID descriptor rather then exact size of report with given
ID as its userland counterpart does. As all input data processed by the
driver is located within the same report, calculate required driver's buffer
size with userland version, imported in one of the previous commits.
This allows us to skip zeroing of buffer on processing of each report.

While here do some minor refactoring.

MFC after: 2 weeks

Details

Provenance
wulfAuthored on
Parents
rS337288: wmt(4): Read Microsoft's "Touch Hardware Quality Assurance" certificate blob
Branches
Unknown
Tags
Unknown