usb_find_common_endpoints(9)
π usb_find_common_endpoints(9) π
okay so bestie, welcome to the Kernel API Manual entry for usb_find_common_endpoints β yes that's the whole function name, no we're not shortening it, she's iconic and she's got a long name, deal with it π
β¨ NAME β¨
usb_find_common_endpoints β look up common endpoint descriptors π
πΈ SYNOPSIS πΈ
int usb_find_common_endpoints (struct usb_host_interface *alt , struct
usb_endpoint_descriptor **bulk_in , struct usb_endpoint_descriptor
**bulk_out , struct usb_endpoint_descriptor **int_in , struct
usb_endpoint_descriptor **int_out );
like, five arguments, one int return, she's serving function signature realness π₯
π¦ ARGUMENTS π¦
altβ the alternate setting the function goes searching through, no cap πbulk_inβ pointer to a descriptor pointer, orNULL. your girl gets to skip it if you passNULL, we love options πbulk_outβ pointer to a descriptor pointer, orNULLint_inβ pointer to a descriptor pointer, orNULLint_outβ pointer to a descriptor pointer, orNULL
π DESCRIPTION π
So here's the tea: this function searches the alternate setting's endpoint descriptors for the first bulk-in, bulk-out, interrupt-in and interrupt-out endpoints, and it returns them in the provided pointers β but only the ones you actually asked for, because if a pointer is NULL she's literally not touching it, okay? π
And if a requested endpoint is not found? the corresponding pointer gets set to NULL. not found bestie, moving on, we don't dwell π
β RETURN β
- Zero if all requested descriptors were found β slay, everything ate π
-ENXIOotherwise β not the vibe, some endpoint ghosted us π
π SEE ALSO π
- Kernel file
./drivers/usb/core/usb.c 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_find_interface(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)
the whole usb friend group fr fr π«Ά
signed, sealed, delivered by ./drivers/usb/core β dated October 2026 β page usb_find_common_endpoints(9), and that's periodt π
β¨
π¦ 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