Page MenuHomeFreeBSD

hid: Fix LINT build
ClosedPublic

Authored by wulf on Sat, Jan 9, 11:08 AM.

Details

Summary

Add NOTES entries and fix extraneous SYSCTL_ADD_INT() options revealed by LINT build

Test Plan

build LINT kernel

Diff Detail

Repository
R10 FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

wulf requested review of this revision.Sat, Jan 9, 11:08 AM
sys/conf/NOTES
2855

I already added "device hid" in NOTES, so please rebase your patch!

sys/amd64/conf/NOTES
610–616

Please remove this \r character while at it :-)

sys/i386/conf/NOTES
863–869

Ditto.

wulf marked 2 inline comments as done.Sat, Jan 9, 12:13 PM
wulf added inline comments.
sys/amd64/conf/NOTES
610–616

Done

sys/i386/conf/NOTES
863–869

Done

Looks good. Just make sure LINT builds.

sys/conf/NOTES
2415–2416
# Generic HID support

->

# HID support
This revision is now accepted and ready to land.Sat, Jan 9, 5:04 PM
imp added inline comments.
sys/amd64/conf/NOTES
612

I'd prefer we put this in sys/conf/NOTES as well.
And for mips/powerpc remove it in those notes files with nodevice if needed.
It's supported on all the 'mainstream' ports and there's nothing specific to the architecture in these files that I've noticed.
I think the duplication of the other options is worse than just having a nodevice or two if it turns out not to build there.

sys/conf/NOTES
2597

Is there some reason this is commented out? If it's not normally on in GENERIC, it should be here, if it is normally on and we want to support things with it off, it shouldn't be here, though it's a mixed bag if that's commented out with a comment about why or it simply not here. I prefer the former. But commented out w/o a reason will invite others to remove either the '#' or the whole thing when 'cleaning up' this.

sys/dev/hid/hidmap.c
755 ↗(On Diff #81947)

This is unrelated and should be committed separately, here and elsewhere in this review (iichid.c)

wulf marked 3 inline comments as done.Sat, Jan 9, 8:50 PM
wulf added inline comments.
sys/amd64/conf/NOTES
612

HID-over-I2C depends on ACPI as it read configuration through _DSM method call (Microsoft specs requires that). That means it is architecture dependent at least for now.
If someone knows how to attach such a devices with FDT, it is easy to fix as all ACPI parts are isolated in probe() method.

sys/conf/NOTES
2597

This option only changes usbhid probe priority and adds/removes PnP IDs to different drivers. I will add comment about that.
IMO there is no difference if it is enabled or is disabled in LINT.

sys/dev/hid/hidmap.c
755 ↗(On Diff #81947)

sysctl changes stays in separate commit in my repo.

wulf marked an inline comment as done.Sat, Jan 9, 9:25 PM
wulf added inline comments.
sys/conf/NOTES
2597

Really, It is better to enable it in a case of "no difference". Just to not confuse others.

Uncomment "option USBHID_ENABLED"
Remove word "Generic" from HID section header.

This revision now requires review to proceed.Sat, Jan 9, 10:34 PM
This revision was not accepted when it landed; it landed in state Needs Review.Sun, Jan 10, 7:20 PM
This revision was automatically updated to reflect the committed changes.