Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
| phy.h [2018/12/27 14:40] – rpjday | phy.h [2018/12/27 14:49] (current) – [struct phy_lookup] rpjday | ||
|---|---|---|---|
| Line 3: | Line 3: | ||
| Discussion of low-level PHY structures and operations, starting at '' | Discussion of low-level PHY structures and operations, starting at '' | ||
| - | ===== Structures ===== | + | ===== Structures |
| ==== struct phy ==== | ==== struct phy ==== | ||
| Line 17: | Line 17: | ||
| struct phy_attrs | struct phy_attrs | ||
| struct regulator | struct regulator | ||
| + | }; | ||
| + | </ | ||
| + | |||
| + | ==== struct phy_attrs and PHY mode ==== | ||
| + | |||
| + | < | ||
| + | struct phy_attrs { | ||
| + | u32 | ||
| + | enum phy_mode | ||
| + | }; | ||
| + | </ | ||
| + | |||
| + | < | ||
| + | enum phy_mode { | ||
| + | PHY_MODE_INVALID, | ||
| + | PHY_MODE_USB_HOST, | ||
| + | PHY_MODE_USB_HOST_LS, | ||
| + | PHY_MODE_USB_HOST_FS, | ||
| + | PHY_MODE_USB_HOST_HS, | ||
| + | PHY_MODE_USB_HOST_SS, | ||
| + | PHY_MODE_USB_DEVICE, | ||
| + | PHY_MODE_USB_DEVICE_LS, | ||
| + | PHY_MODE_USB_DEVICE_FS, | ||
| + | PHY_MODE_USB_DEVICE_HS, | ||
| + | PHY_MODE_USB_DEVICE_SS, | ||
| + | PHY_MODE_USB_OTG, | ||
| + | PHY_MODE_SGMII, | ||
| + | PHY_MODE_2500SGMII, | ||
| + | PHY_MODE_QSGMII, | ||
| + | PHY_MODE_10GKR, | ||
| + | PHY_MODE_UFS_HS_A, | ||
| + | PHY_MODE_UFS_HS_B, | ||
| + | PHY_MODE_PCIE, | ||
| + | }; | ||
| + | </ | ||
| + | |||
| + | ==== struct phy_ops ==== | ||
| + | |||
| + | < | ||
| + | struct phy_ops { | ||
| + | int | ||
| + | int | ||
| + | int | ||
| + | int | ||
| + | int | ||
| + | int | ||
| + | int | ||
| + | struct module *owner; | ||
| + | }; | ||
| + | </ | ||
| + | |||
| + | ==== struct phy_provider ==== | ||
| + | |||
| + | < | ||
| + | struct phy_provider { | ||
| + | struct device | ||
| + | struct device_node | ||
| + | struct module | ||
| + | struct list_head | ||
| + | struct phy * (*of_xlate)(struct device *dev, | ||
| + | struct of_phandle_args *args); | ||
| + | }; | ||
| + | </ | ||
| + | |||
| + | ==== struct phy_lookup ==== | ||
| + | |||
| + | < | ||
| + | struct phy_lookup { | ||
| + | struct list_head node; | ||
| + | const char *dev_id; | ||
| + | const char *con_id; | ||
| + | struct phy *phy; | ||
| }; | }; | ||
| </ | </ | ||