cdns3_gadget_check_config(9)
π cdns3_gadget_check_config β bestie, it's a vibe check for your USB configs
okay so this page lives in the Kernel API Manual, and the function it's hyping up is cdns3_gadget_check_config. Think of it as the bouncer at the club door going "mm, can the cdns3 controller actually handle this USB configuration or are we delulu?" π«Ά
β¨ SYNOPSIS β¨
int cdns3_gadget_check_config (struct usb_gadget *gadget );
it returns an int, it takes one arg, it's giving functional. slay.
π ARGUMENTS π
gadgetβ pointer to the USB gadget. literally the whole entire gadget. that's the one, that's the guy π
πΈ DESCRIPTION πΈ
okay so here's the tea. this function is used to record the maximum number of endpoints being used in a USB composite device, and bestie I need you to clock that this count spans across all configurations β not just one, all of them. noted and filed, no cap.
and why do we care? because that recorded max is to be used in the calculation of the TXFIFO sizes when resizing internal memory for individual endpoints. the resize logic needs receipts before it starts moving memory around π₯
the payoff is the whole point: it will help ensured that the resizing logic reserves enough space for at least one max packet. yes, the original says "help ensured" β we do not fix the manpage prose in this house, we respect the source π. at least one max packet, guaranteed-ish, iconic behavior.
tl;dr: count endpoints β remember the max β feed it to the TXFIFO resize math β everybody gets enough space. periodt. π
π¦ SEE ALSO π¦
the source of truth, the mothership:
- Kernel file
./drivers/usb/cdns3/cdns3-gadget.c
and now the whole friend group, in order, because I would never leave anyone out of the group chat π
cdns3_clear_register_bit(9)cdns3_set_register_bit(9)cdns3_ep_addr_to_index(9)cdns3_next_request(9)cdns3_next_align_buf(9)cdns3_next_priv_request(9)cdns3_select_ep(9)cdns3_get_tdl(9)cdns3_allocate_trb_pool(9)cdns3_ep_stall_flush(9)cdns3_hw_reset_eps_config(9)cdns3_ep_inc_trb(9)cdns3_ep_inc_enq(9)cdns3_ep_inc_deq(9)cdns3_allow_enable_l1(9)cdns3_start_all_request(9)cdns3_wa2_descmiss_copy_data(9)cdns3_wa2_descmissing_packet(9)cdns3_gadget_giveback(9)cdns3_ep_run_transfer(9)cdns3_trb_handled(9)cdns3_check_ep_interrupt_proceed(9)cdns3_check_usb_interrupt_proceed(9)cdns3_device_irq_handler(9)cdns3_device_thread_irq_handler(9)cdns3_ep_onchip_buffer_reserve(9)cdns3_ep_config(9)cdns3_gadget_ep_alloc_request(9)cdns3_gadget_ep_free_request(9)cdns3_gadget_ep_enable(9)cdns3_gadget_ep_disable(9)__cdns3_gadget_ep_queue(9)cdns3_gadget_ep_dequeue(9)__cdns3_gadget_ep_set_halt(9)__cdns3_gadget_ep_clear_halt(9)cdns3_gadget_ep_set_halt(9)cdns3_gadget_get_frame(9)cdns3_gadget_udc_start(9)cdns3_gadget_udc_stop(9)cdns3_init_eps(9)cdns3_gadget_init(9)
ngl bestie that's a lot of siblings but every single one of them made the list, so nobody's getting cut from the group photo πΈ
and that's the page!! brought to you from ./drivers/usb/cdns3, dated October 2026, and yeah the manual name is literally cdns3_gadget_check_config(9) β same as the title, king behavior. byeee, go read your TXFIFO math π
β¨
π¦ 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