dwc2_gadget..._hibernation(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ dwc2_gadget_enter_hibernation ✨

okay bestie, this one lives in the Kernel API Manual (that's the manual name, yes it's fancy, we love that for it) and it's all about putting the controller to sleep. like, the ✨fancy✨ sleep. let's get into it πŸ’…


🌸 NAME 🌸

dwc2_gadget_enter_hibernation β€” Put controller in Hibernation. that's it, that's the whole name, no notes, she's straightforward and we respect it 🫢


πŸŽ€ SYNOPSIS πŸŽ€

int dwc2_gadget_enter_hibernation (struct dwc2_hsotg *hsotg );

literally just one argument bestie, look at her go πŸ’–


πŸ¦‹ ARGUMENTS πŸ¦‹

  • hsotg β€” the Programming view of the DWC_otg controller. yes, "Programming view", capital P and everything. this is your whole controller's vibe-checked soul in a struct ✨

πŸ”₯ DESCRIPTION πŸ”₯

okay so here's the tea: this function returns non-zero if it failed to enter hibernation. like, non-zero means it did NOT slay, it did not make it to sleep. read that twice. non-zero = failure. i know. the way that 0 is actually the good one here 😭

⚠️ ngl, remember the polarity: 0 = it hibernated successfully, non-zero = it did not. don't get it twisted bestie, i'm literally begging πŸ™ˆ

πŸ’œ SEE ALSO πŸ’œ

so the Kernel file to peek at is ./drivers/usb/dwc2/gadget.c, and honestly there are SO many siblings, i'm obsessed, she has a huge family, here's the whole group chat 🧚:

using_dma(9), dwc2_gadget_incr_frame_num(9), dwc2_gadget_dec_frame_num_by_one(9), dwc2_hsotg_en_gsint(9), dwc2_hsotg_disable_gsint(9), dwc2_hsotg_ctrl_epint(9), dwc2_hsotg_tx_fifo_count(9), dwc2_hsotg_tx_fifo_total_depth(9), dwc2_gadget_wkup_alert_handler(9), dwc2_hsotg_tx_fifo_average_depth(9), dwc2_hsotg_init_fifo(9), dwc2_hsotg_ep_alloc_request(9), is_ep_periodic(9), dwc2_hsotg_unmap_dma(9), dwc2_hsotg_write_fifo(9), get_ep_limit(9), dwc2_hsotg_read_frameno(9), dwc2_gadget_get_chain_limit(9), dwc2_hsotg_start_req(9), dwc2_hsotg_map_dma(9), dwc2_gadget_target_frame_elapsed(9), dwc2_hsotg_complete_oursetup(9), ep_from_windex(9), dwc2_hsotg_set_test_mode(9), dwc2_hsotg_send_reply(9), dwc2_hsotg_process_req_status(9), get_ep_head(9), dwc2_gadget_start_next_request(9), dwc2_hsotg_process_req_feature(9), dwc2_hsotg_stall_ep0(9), dwc2_hsotg_process_control(9), dwc2_hsotg_complete_setup(9), dwc2_hsotg_enqueue_setup(9), dwc2_hsotg_complete_request(9), dwc2_hsotg_rx_data(9), dwc2_hsotg_ep0_zlp(9), dwc2_hsotg_handle_outdone(9), dwc2_hsotg_handle_rx(9), dwc2_hsotg_ep0_mps(9), dwc2_hsotg_set_ep_maxpacket(9), dwc2_hsotg_txfifo_flush(9), dwc2_hsotg_trytx(9), dwc2_hsotg_complete_in(9), dwc2_gadget_read_ep_interrupts(9), dwc2_gadget_handle_ep_disabled(9), dwc2_gadget_handle_out_token_ep_disabled(9), dwc2_gadget_handle_nak(9), dwc2_hsotg_epint(9), dwc2_hsotg_irq_enumdone(9), kill_all_requests(9), dwc2_hsotg_disconnect(9), dwc2_hsotg_irq_fifoempty(9), dwc2_hsotg_core_init_disconnected(9), dwc2_gadget_handle_incomplete_isoc_in(9), dwc2_gadget_handle_incomplete_isoc_out(9), dwc2_hsotg_irq(9), dwc2_hsotg_ep_enable(9), dwc2_hsotg_ep_disable(9), on_list(9), dwc2_hsotg_ep_dequeue(9), dwc2_gadget_ep_set_wedge(9), dwc2_hsotg_ep_sethalt(9), dwc2_hsotg_ep_sethalt_lock(9), dwc2_hsotg_init(9), dwc2_hsotg_udc_start(9), dwc2_hsotg_udc_stop(9), dwc2_hsotg_gadget_getframe(9), dwc2_hsotg_set_selfpowered(9), dwc2_hsotg_pullup(9), dwc2_hsotg_vbus_draw(9), dwc2_hsotg_initep(9), dwc2_hsotg_hw_cfg(9), dwc2_hsotg_dump(9), dwc2_gadget_init(9), dwc2_hsotg_remove(9), dwc2_backup_device_registers(9), dwc2_restore_device_registers(9), dwc2_gadget_init_lpm(9), dwc2_gadget_program_ref_clk(9), dwc2_gadget_exit_hibernation(9), dwc2_gadget_enter_partial_power_down(9), dwc2_gadget_enter_clock_gating(9)

like... the range. the versatility. main character energy everywhere 🌈


that's the whole thing bestie, go forth and hibernate responsibly πŸ’–βœ¨

πŸŽ€ source/version: ./drivers/usb/dwc2 β€” dated October 2026, and this manual page was literally brought to you by the dwc2_gadget_enter_hibernation(9) girlies. slay, bye πŸ‘‘πŸ’…
πŸ“¦ where this page comes from