PHY_100BT_FEATURES | \
PHY_DEFAULT_FEATURES)
+#define PHY_100BT1_FEATURES (SUPPORTED_TP | \
+ SUPPORTED_MII | \
+ SUPPORTED_100baseT_Full)
+
#define PHY_GBIT_FEATURES (PHY_BASIC_FEATURES | \
PHY_1000BT_FEATURES)
{
return interface == PHY_INTERFACE_MODE_XGMII ||
interface == PHY_INTERFACE_MODE_USXGMII ||
- interface == PHY_INTERFACE_MODE_XFI;
+ interface == PHY_INTERFACE_MODE_10GBASER;
}
#endif
struct phy_device *phy_find_by_mask(struct mii_dev *bus, unsigned phy_mask,
phy_interface_t interface);
+#ifdef CONFIG_PHY_FIXED
+
+/**
+ * fixed_phy_create() - create an unconnected fixed-link pseudo-PHY device
+ * @node: OF node for the container of the fixed-link node
+ *
+ * Description: Creates a struct phy_device based on a fixed-link of_node
+ * description. Can be used without phy_connect by drivers which do not expose
+ * a UCLASS_ETH udevice.
+ */
+struct phy_device *fixed_phy_create(ofnode node);
+
+#else
+
+static inline struct phy_device *fixed_phy_create(ofnode node)
+{
+ return NULL;
+}
+
+#endif
+
#ifdef CONFIG_DM_ETH
/**
struct phy_device *phy_connect(struct mii_dev *bus, int addr,
struct udevice *dev,
phy_interface_t interface);
+/**
+ * phy_device_create() - Create a PHY device
+ *
+ * @bus: MII/MDIO bus that hosts the PHY
+ * @addr: PHY address on MDIO bus
+ * @phy_id: where to store the ID retrieved
+ * @is_c45: Device Identifiers if is_c45
+ * @interface: interface between the MAC and PHY
+ * @return: pointer to phy_device if a PHY is found, or NULL otherwise
+ */
+struct phy_device *phy_device_create(struct mii_dev *bus, int addr,
+ u32 phy_id, bool is_c45,
+ phy_interface_t interface);
+
+/**
+ * phy_connect_phy_id() - Connect to phy device by reading PHY id
+ * from phy node.
+ *
+ * @bus: MII/MDIO bus that hosts the PHY
+ * @dev: Ethernet device to associate to the PHY
+ * @interface: Interface between the MAC and PHY
+ * @return: pointer to phy_device if a PHY is found,
+ * or NULL otherwise
+ */
+struct phy_device *phy_connect_phy_id(struct mii_dev *bus, struct udevice *dev,
+ phy_interface_t interface);
static inline ofnode phy_get_ofnode(struct phy_device *phydev)
{
int phy_atheros_init(void);
int phy_broadcom_init(void);
int phy_cortina_init(void);
+int phy_cortina_access_init(void);
int phy_davicom_init(void);
int phy_et1011c_init(void);
int phy_lxt_init(void);
int phy_micrel_ksz90x1_init(void);
int phy_meson_gxl_init(void);
int phy_natsemi_init(void);
+int phy_nxp_tja11xx_init(void);
int phy_realtek_init(void);
int phy_smsc_init(void);
int phy_teranetics_init(void);
}
/* PHY UIDs for various PHYs that are referenced in external code */
-#define PHY_UID_CS4340 0x13e51002
-#define PHY_UID_CS4223 0x03e57003
+#define PHY_UID_CS4340 0x13e51002
+#define PHY_UID_CS4223 0x03e57003
#define PHY_UID_TN2020 0x00a19410
#define PHY_UID_IN112525_S03 0x02107440