STRUCT EXYNOS5_USBDRD_PHY(9)
π struct exynos5_usbdrd_phy
okay so bestie, this is a Kernel API Manual page for struct exynos5_usbdrd_phy(9) β it's literally the driver data home for the USB 3.0 PHY, and we're about to read it together like it's the group chat lore π«Ά
β¨ NAME β¨
struct exynos5_usbdrd_phy β driver data for USB 3.0 PHY. that's it, that's the whole vibe: it's the struct that holds everything the driver needs to know about the PHY π
πΈ SYNOPSIS πΈ
here's the whole struct, no cap, every field exactly where it lives:
struct exynos5_usbdrd_phy {
struct device *dev;
void __iomem *reg_phy;
void __iomem *reg_pcs;
void __iomem *reg_pma;
struct clk_bulk_data *clks;
struct clk_bulk_data *core_clks;
const struct exynos5_usbdrd_phy_drvdata *drv_data;
struct phy *hs_phy;
struct mutex phy_mutex;
struct phy_usb_instance {
struct phy *phy;
u32 index;
struct regmap *reg_pmu;
u32 pmu_offset;
const struct exynos5_usbdrd_phy_config *phy_cfg;
} phys[EXYNOS5_DRDPHYS_NUM];
u32 extrefclk;
struct regulator_bulk_data *regulators;
struct typec_switch_dev *sw;
enum typec_orientation orientation;
};
π¦ MEMBERS π¦
okay now the fun part, member by member, main character energy only π
devβ pointer to the device instance of this platform device. like, this is the "who am I" of the whole thing πͺͺreg_phyβ the usb phy controller register memory base. the address where the register party starts β¨reg_pcsβ the usb phy physical coding sublayer register memory base. yes, PCS, physical coding sublayer, she has a full name πreg_pmaβ the usb phy physical media attachment register memory base. PMA, physical media attachment, also fancy πclksβ clocks for register access. you need these to even touch the registers, periodt β°core_clksβ core clocks for phy (ref, pipe3, utmi+, ITP, etc. as required). literally the whole list, "as required" and all πdrv_dataβ pointer to the SoC level driver data structure. SoC-specific deets live here π§hs_phyβ pointer to the non-Samsung IP high-speed phy controller. not Samsung's IP, so it gets its own pointer π«Άphy_mutexβ mutex protectingphy_init/exit& TCPC callbacks. she's the bouncer keeping things from colliding πphysβ array for'EXYNOS5_DRDPHYS_NUM'number of PHY instances, each with its'phy'and'phy_cfg'. and inside each one there'sstruct phy *phy,u32 index,struct regmap *reg_pmu,u32 pmu_offset, andconst struct exynos5_usbdrd_phy_config *phy_cfgβ a whole little nested struct, we love a struct within a struct πextrefclkβ frequency select settings when using'separate reference clocks'for SS and HS operations. SS and HS, both of them, separate clocks, iconic π«regulatorsβ regulators for phy. give the phy her power, she deserves it β‘swβ TypeC orientation switch handle. flips things around, lowkey πorientationβ TypeC connector orientation β normal or flipped. just those two, normal or flipped, no in-between π
π₯ SEE ALSO π₯
want the source? go look at the kernel file ./drivers/phy/samsung/phy-exynos5-usbdrd.c β that's where this whole thing actually lives, iykyk π
ngl bestie, this is a kernel struct doc so the "danger" is mostly "read the fields before you poke them", but fr fr: the phy_mutex is there for a reason, respect the mutex π
and that's the tea π this page came from ./drivers/phy/samsung, dated October 2026, and it's literally titled struct exynos5_usbdrd_phy(9) β ate and left no crumbs ππβ¨
π¦ 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