usb_find_interface(9)
π usb_find_interface (kernel API manual)
okay so bestie, welcome to the usb_find_interface(9) page π this is a kernel API manual situation, and honestly? it does exactly one thing and does it cute. let's get into it β¨
πΈ NAME πΈ
usb_find_interface β find the usb_interface pointer for a driver and a device π«Ά
β¨ SYNOPSIS β¨
struct usb_interface * usb_find_interface (struct usb_driver *drv , int
minor );
likeβ¦ it takes two things and gives you a pointer back. main character energy fr fr π
π ARGUMENTS π
drvβ the driver whose current configuration is being considered. yes bestie, current, not the ex configuration πminorβ the minor number of the desired device. the device you're looking for, in minor-number form πΈ
π¦ DESCRIPTION π¦
so what this does is it walks the bus device list β literally strolling through the devices like it owns the place π β and returns a pointer to the interface that has the matching minor and driver.
β οΈ note bestie: this only works for devices that share the USB major number. no major number match? no vibe. it's giving exclusive π
β RETURN β
a pointer to the interface with the matching major and minor. that's it, that's the return π«Ά
π₯ SEE ALSO π₯
kernel file ./drivers/usb/core/usb.c π and then the whole friend group:
usb_find_common_endpoints(9)usb_find_common_endpoints_reverse(9)usb_find_endpoint(9)usb_check_bulk_endpoints(9)usb_check_int_endpoints(9)usb_find_alt_setting(9)usb_ifnum_to_if(9)usb_altnum_to_altsetting(9)usb_for_each_dev(9)usb_release_dev(9)usb_alloc_dev(9)usb_get_dev(9)usb_put_dev(9)usb_get_intf(9)usb_put_intf(9)usb_intf_get_dma_device(9)usb_lock_device_for_reset(9)usb_get_current_frame_number(9)usb_alloc_coherent(9)usb_free_coherent(9)usb_alloc_noncoherent(9)usb_free_noncoherent(9)usb_endpoint_max_periodic_payload(9)usb_endpoint_is_hs_isoc_double(9)
like, the whole usb squad showed up ππ
and that's the page, bestie π this little icon lives in ./drivers/usb/core and the version slaps a date of October 2026 on it β iconic, no notes π
β¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms