projects
/
openwrt
/
staging
/
wigyori.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ath79: ag71xx: add support for optional mdio reset
[openwrt/staging/wigyori.git]
/
target
/
linux
/
ath79
/
files
/
drivers
/
net
/
ethernet
/
atheros
/
ag71xx
/
ag71xx.h
diff --git
a/target/linux/ath79/files/drivers/net/ethernet/atheros/ag71xx/ag71xx.h
b/target/linux/ath79/files/drivers/net/ethernet/atheros/ag71xx/ag71xx.h
index 22b22522a3f6985b114ec155f7212c51d45e98cf..fde9db37456d5ce261ff3d4414f3e1dc69f40be0 100644
(file)
--- a/
target/linux/ath79/files/drivers/net/ethernet/atheros/ag71xx/ag71xx.h
+++ b/
target/linux/ath79/files/drivers/net/ethernet/atheros/ag71xx/ag71xx.h
@@
-154,6
+154,8
@@
struct ag71xx {
struct ag71xx_ring rx_ring ____cacheline_aligned;
struct ag71xx_ring tx_ring ____cacheline_aligned;
struct ag71xx_ring rx_ring ____cacheline_aligned;
struct ag71xx_ring tx_ring ____cacheline_aligned;
+ int mac_idx;
+
u16 desc_pktlen_mask;
u16 rx_buf_size;
u8 rx_buf_offset;
u16 desc_pktlen_mask;
u16 rx_buf_size;
u8 rx_buf_offset;
@@
-170,12
+172,10
@@
struct ag71xx {
*/
void __iomem *mac_base;
void __iomem *mii_base;
*/
void __iomem *mac_base;
void __iomem *mii_base;
- struct regmap *mii_regmap;
struct ag71xx_desc *stop_desc;
dma_addr_t stop_desc_dma;
struct ag71xx_desc *stop_desc;
dma_addr_t stop_desc_dma;
- struct mii_bus *mii_bus;
struct phy_device *phy_dev;
void *phy_priv;
int phy_if_mode;
struct phy_device *phy_dev;
void *phy_priv;
int phy_if_mode;
@@
-188,7
+188,6
@@
struct ag71xx {
struct timer_list oom_timer;
struct reset_control *mac_reset;
struct timer_list oom_timer;
struct reset_control *mac_reset;
- struct reset_control *phy_reset;
struct reset_control *mdio_reset;
u32 fifodata[3];
struct reset_control *mdio_reset;
u32 fifodata[3];
@@
-201,6
+200,12
@@
struct ag71xx {
#endif
};
#endif
};
+struct ag71xx_mdio {
+ struct reset_control *mdio_reset;
+ struct mii_bus *mii_bus;
+ struct regmap *mii_regmap;
+};
+
extern struct ethtool_ops ag71xx_ethtool_ops;
void ag71xx_link_adjust(struct ag71xx *ag);
extern struct ethtool_ops ag71xx_ethtool_ops;
void ag71xx_link_adjust(struct ag71xx *ag);
@@
-440,12
+445,8
@@
static inline void ag71xx_debugfs_update_napi_stats(struct ag71xx *ag,
int ag71xx_ar7240_init(struct ag71xx *ag, struct device_node *np);
void ag71xx_ar7240_cleanup(struct ag71xx *ag);
int ag71xx_ar7240_init(struct ag71xx *ag, struct device_node *np);
void ag71xx_ar7240_cleanup(struct ag71xx *ag);
-void ag71xx_ar7240_start(struct ag71xx *ag);
-int ag71xx_mdio_init(struct ag71xx *ag);
-void ag71xx_mdio_cleanup(struct ag71xx *ag);
-int ag71xx_mdio_mii_read(struct mii_bus *bus, int addr, int reg);
-int ag71xx_mdio_mii_write(struct mii_bus *bus, int addr, int reg, u16 val);
+int ag71xx_setup_gmac(struct device_node *np);
int ar7240sw_phy_read(struct mii_bus *mii, int addr, int reg);
int ar7240sw_phy_write(struct mii_bus *mii, int addr, int reg, u16 val);
int ar7240sw_phy_read(struct mii_bus *mii, int addr, int reg);
int ar7240sw_phy_write(struct mii_bus *mii, int addr, int reg, u16 val);