STRUCT ROCKCHIP_USB2PHY_PORT_CFG(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct rockchip_usb2phy_port_cfg(9) πŸ’–

okay so bestie, this is a page straight out of the Kernel API Manual β€” the manual name is literally struct rockc...phy_port_cfg(9) (yes, the header truncates it like that, it's giving "we ran out of room on the label"). It's the struct that holds all the usb-phy port configuration for Rockchip's USB2 PHY. Let's get into it πŸŽ€


✨ NAME ✨

struct rockchip_usb2phy_port_cfg β€” usb-phy port configuration. that's it, that's the whole vibe. it's the config struct. it holds registers. it's iconic πŸ’…


🌸 SYNOPSIS 🌸

struct rockchip_usb2phy_port_cfg {
    struct usb2phy_reg      phy_sus;
    struct usb2phy_reg      bvalid_det_en;
    struct usb2phy_reg      bvalid_det_st;
    struct usb2phy_reg      bvalid_det_clr;
    struct usb2phy_reg      disfall_en;
    struct usb2phy_reg      disfall_st;
    struct usb2phy_reg      disfall_clr;
    struct usb2phy_reg      disrise_en;
    struct usb2phy_reg      disrise_st;
    struct usb2phy_reg      disrise_clr;
    struct usb2phy_reg      idfall_det_en;
    struct usb2phy_reg      idfall_det_st;
    struct usb2phy_reg      idfall_det_clr;
    struct usb2phy_reg      idrise_det_en;
    struct usb2phy_reg      idrise_det_st;
    struct usb2phy_reg      idrise_det_clr;
    struct usb2phy_reg      ls_det_en;
    struct usb2phy_reg      ls_det_st;
    struct usb2phy_reg      ls_det_clr;
    struct usb2phy_reg      utmi_avalid;
    struct usb2phy_reg      utmi_bvalid;
    struct usb2phy_reg      utmi_id;
    struct usb2phy_reg      utmi_ls;
    struct usb2phy_reg      utmi_hstdet;
 };

no cap, every single member is a struct usb2phy_reg β€” consistent queen behavior πŸ‘‘ twenty-four of them. we love a uniform cast.


πŸ¦‹ Members πŸ¦‹

  • phy_sus β€” phy suspend register. the "go to sleep" switch, lowkey πŸ¦‹
  • bvalid_det_en β€” vbus valid rise detection enable register. turns the detector on πŸ’–
  • bvalid_det_st β€” vbus valid rise detection status register. tells you what the detector saw πŸ‘€
  • bvalid_det_clr β€” vbus valid rise detection clear register. wipes the status clean, fresh start energy ✨
  • disfall_en β€” host disconnect fall edge detection enable.
  • disfall_st β€” host disconnect fall edge detection state.
  • disfall_clr β€” host disconnect fall edge detection clear.
  • disrise_en β€” host disconnect rise edge detection enable.
  • disrise_st β€” host disconnect rise edge detection state.
  • disrise_clr β€” host disconnect rise edge detection clear.
  • idfall_det_en β€” id detection enable register, falling edge. (yes, falling edge, write that down πŸ“)
  • idfall_det_st β€” id detection state register, falling edge.
  • idfall_det_clr β€” id detection clear register, falling edge.
  • idrise_det_en β€” id detection enable register, rising edge. (and this one's rising, don't mix them up bestie 😭)
  • idrise_det_st β€” id detection state register, rising edge.
  • idrise_det_clr β€” id detection clear register, rising edge.
  • ls_det_en β€” linestate detection enable register.
  • ls_det_st β€” linestate detection state register.
  • ls_det_clr β€” linestate detection clear register.
  • utmi_avalid β€” utmi vbus avalid status register. (that's "avalid" with two a's, keep it exactly like that πŸ™ˆ)
  • utmi_bvalid β€” utmi vbus bvalid status register.
  • utmi_id β€” utmi id state register.
  • utmi_ls β€” utmi linestate state register.
  • utmi_hstdet β€” utmi host disconnect register. the disconnect gossip column fr fr πŸ’€

πŸ”₯ SEE ALSO πŸ”₯

  • Kernel file ./drivers/phy/rockchip/phy-rockchip-inno-usb2.c
  • enum usb_chg_state(9)
  • struct rockchip_chg_det_reg(9)
  • struct rockchip_usb2phy_cfg(9)
  • struct rockchip_usb2phy_port(9)
  • struct rockchip_usb2phy(9)

all the sibling structs and that one enum, living their best lives in the same file 🫢


that's the whole page bestie, go forth and configure your ports πŸ’œ

🌸 sign-off szn: this one comes from ./drivers/phy/rockchip, dated October 2026, and the manual title at the bottom is struct rockc...phy_port_cfg(9) β€” same truncated legend as the top, we stan a consistent header βœ¨πŸŽ€

πŸ“¦ where this page comes from