usb_role_switch_set_drvdata(9)
π usb_role_switch_set_drvdata(9) π
okay bestie, this one's from the Kernel API Manual, and it's giving tiny-helper-big-purpose energy. The function is usb_role_switch_set_drvdata β long name, iconic behavior: Assign private data pointer to a switch. slay. π
β¨ NAME β¨
usb_role_switch_set_drvdata β Assign private data pointer to a switch
πΈ SYNOPSIS πΈ
void usb_role_switch_set_drvdata (struct usb_role_switch *sw , void
*data );
No cap, it returns void β it's not handing a value back, it's just doing the assignment vibe. π
π¦ ARGUMENTS π¦
swβ USB Role Switch. That's the switch getting the private data pointer.dataβ Private data pointer. The pointer itself. Private. Data. No extra lore needed.
π SEE ALSO π
Kernel file ./drivers/usb/roles/class.c is right there with the related function besties:
usb_role_switch_set_role(9)usb_role_switch_get_role(9)usb_role_switch_get(9)fwnode_usb_role_switch_get(9)usb_role_switch_put(9)usb_role_switch_find_by_fwnode(9)usb_role_switch_register(9)usb_role_switch_unregister(9)usb_role_switch_get_drvdata(9)
k byeee π this cutie page came from ./drivers/usb/roles, dated October 2026, for usb_role_switch_set_drvdata(9) β mwah πβ¨
π¦ 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