diff options
author | Jon Mason <jon.mason@broadcom.com> | 2016-11-04 01:11:00 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-11-07 13:11:22 -0500 |
commit | 1676aba5ef7ec8b9d360d33b559abc7db3a5a3a0 (patch) | |
tree | 3c1396b6d349a9e8bf1f6a3f12f7761f265daf53 /drivers/net/ethernet/broadcom/bgmac.h | |
parent | 0086f0944f8f2bfc3f029dcd4759b96dfb82a2af (diff) | |
download | blackbird-obmc-linux-1676aba5ef7ec8b9d360d33b559abc7db3a5a3a0.tar.gz blackbird-obmc-linux-1676aba5ef7ec8b9d360d33b559abc7db3a5a3a0.zip |
net: ethernet: bgmac: device tree phy enablement
Change the bgmac driver to allow for phy's defined by the device tree
Signed-off-by: Jon Mason <jon.mason@broadcom.com>
Acked-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bgmac.h')
-rw-r--r-- | drivers/net/ethernet/broadcom/bgmac.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/net/ethernet/broadcom/bgmac.h b/drivers/net/ethernet/broadcom/bgmac.h index 80836b4c9f38..bfd9f40d71f7 100644 --- a/drivers/net/ethernet/broadcom/bgmac.h +++ b/drivers/net/ethernet/broadcom/bgmac.h @@ -513,10 +513,13 @@ struct bgmac { u32 (*get_bus_clock)(struct bgmac *bgmac); void (*cmn_maskset32)(struct bgmac *bgmac, u16 offset, u32 mask, u32 set); + int (*phy_connect)(struct bgmac *bgmac); }; int bgmac_enet_probe(struct bgmac *info); void bgmac_enet_remove(struct bgmac *bgmac); +void bgmac_adjust_link(struct net_device *net_dev); +int bgmac_phy_connect_direct(struct bgmac *bgmac); struct mii_bus *bcma_mdio_mii_register(struct bcma_device *core, u8 phyaddr); void bcma_mdio_mii_unregister(struct mii_bus *mii_bus); @@ -583,4 +586,9 @@ static inline void bgmac_set(struct bgmac *bgmac, u16 offset, u32 set) { bgmac_maskset(bgmac, offset, ~0, set); } + +static inline int bgmac_phy_connect(struct bgmac *bgmac) +{ + return bgmac->phy_connect(bgmac); +} #endif /* _BGMAC_H */ |