X-Git-Url: http://git.rohieb.name/openwrt.git/blobdiff_plain/3f4343bbc3339826f7fea6f36e80c6913cddefb1..866750add03712d91944b4ac2f31303de1c2d52c:/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx.h diff --git a/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx.h b/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx.h index 7daa9f206..1d22453a9 100644 --- a/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx.h +++ b/target/linux/ar71xx/files/drivers/net/ag71xx/ag71xx.h @@ -1,7 +1,7 @@ /* * Atheros AR71xx built-in ethernet mac driver * - * Copyright (C) 2008 Gabor Juhos + * Copyright (C) 2008-2009 Gabor Juhos * Copyright (C) 2008 Imre Kaloz * * Based on Atheros' AG7100 driver @@ -38,7 +38,7 @@ #define ETH_FCS_LEN 4 #define AG71XX_DRV_NAME "ag71xx" -#define AG71XX_DRV_VERSION "0.5.14" +#define AG71XX_DRV_VERSION "0.5.21" #define AG71XX_NAPI_WEIGHT 64 #define AG71XX_OOM_REFILL (1 + HZ/10) @@ -63,8 +63,7 @@ #define AG71XX_RX_RING_SIZE 128 -#undef AG71XX_DEBUG -#ifdef AG71XX_DEBUG +#ifdef CONFIG_AG71XX_DEBUG #define DBG(fmt, args...) printk(KERN_DEBUG fmt, ## args) #else #define DBG(fmt, args...) do {} while (0) @@ -85,6 +84,7 @@ struct ag71xx_desc { #define DESC_MORE BIT(24) #define DESC_PKTLEN_M 0x1fff u32 next; + u32 pad; }; struct ag71xx_buf { @@ -101,7 +101,7 @@ struct ag71xx_ring { }; struct ag71xx_mdio { - struct mii_bus mii_bus; + struct mii_bus *mii_bus; int mii_irq[PHY_MAX_ADDR]; void __iomem *mdio_base; }; @@ -430,4 +430,20 @@ static void inline ag71xx_mii_ctrl_set_speed(struct ag71xx *ag, ag71xx_mii_ctrl_wr(ag, t); } +#ifdef CONFIG_AG71XX_AR8216_SUPPORT +void ag71xx_add_ar8216_header(struct ag71xx *ag, struct sk_buff *skb); +int ag71xx_remove_ar8216_header(struct ag71xx *ag, struct sk_buff *skb); +#else +static inline void ag71xx_add_ar8216_header(struct ag71xx *ag, + struct sk_buff *skb) +{ +} + +static inline int ag71xx_remove_ar8216_header(struct ag71xx *ag, + struct sk_buff *skb) +{ + return 0; +} +#endif + #endif /* _AG71XX_H */