]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Improve handling of alternate settings in the USB stack.
authorHans Petter Selasky <hselasky@FreeBSD.org>
Tue, 15 Dec 2020 12:05:07 +0000 (12:05 +0000)
committerHans Petter Selasky <hselasky@FreeBSD.org>
Tue, 15 Dec 2020 12:05:07 +0000 (12:05 +0000)
commitb8b3f4fdc31fb21b54f5f3104e318e1c342cb2d9
tree1f5c014aeb2abb8fcb9e40518cbfe85b257e92fd
parent6da5df470099fc55f20b03ef364af730e7be4ffe
Improve handling of alternate settings in the USB stack.

Allow setting the alternate interface number to fail when there is only
one alternate setting present, to comply with the USB specification.

Refactor how iface->num_altsetting is computed.

Bump the __FreeBSD_version due to change of core USB structure.

PR: 251856
MFC after: 1 week
Submitted by: Ma, Horse <Shichun.Ma@dell.com>
Sponsored by: Mellanox Technologies // NVIDIA Networking
sys/compat/linuxkpi/common/src/linux_usb.c
sys/dev/usb/usb_device.c
sys/dev/usb/usb_request.c
sys/dev/usb/usbdi.h
sys/sys/param.h