usb_intf_get_dma_device(9)
π usb_intf_get_dma_device(9) β Kernel API Manual, bestie edition β¨
Okay so this is a page from the Kernel API Manual and honestly? It's short, it's sweet, it's giving "small but mighty" π Let's get into it.
πΈ NAME πΈ
usb_intf_get_dma_device β grab yourself a reference on the usb interface's DMA endpoint, no cap π₯
β¨ SYNOPSIS β¨
struct device * usb_intf_get_dma_device (struct usb_interface *intf );
π ARGUMENTS π
intfβ the usb interface. That's it, that's the whole argument, she's lowkey simple π«Ά
π¦ DESCRIPTION π¦
So here's the tea β: a USB device cannot perform DMA operations by itself. Like, it just can't, that's not her job π But β plot twist β many USB controllers can π
So when you call usb_intf_get_dma_device, it hands you back the DMA endpoint for the given USB interface, if any exists. Slay.
β οΈ Bestie, listen to me: the returned device structure must be released with put_device. Not optional. Don't leave her hanging, that's so rude π
Also see usb_get_dma_device π
π RETURN π
A reference to the usb interface's DMA endpoint π« β or NULL if none exists π (she simply isn't there, and that's okay).
π SEE ALSO π
Kernel file ./drivers/usb/core/usb.c along with this whole squad right here π―ββοΈ:
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_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_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)
And that's the whole page, bestie π She lives in ./drivers/usb/core and this edition is dated October 2026 β periodt, go touch some DMA π
π§ββοΈ
π¦ 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