diff options
Diffstat (limited to 'drivers/staging/octeon')
-rw-r--r-- | drivers/staging/octeon/ethernet-mdio.h | 2 | ||||
-rw-r--r-- | drivers/staging/octeon/ethernet-rgmii.c | 7 | ||||
-rw-r--r-- | drivers/staging/octeon/ethernet-tx.c | 10 | ||||
-rw-r--r-- | drivers/staging/octeon/ethernet.c | 1 | ||||
-rw-r--r-- | drivers/staging/octeon/octeon-ethernet.h | 22 |
5 files changed, 23 insertions, 19 deletions
diff --git a/drivers/staging/octeon/ethernet-mdio.h b/drivers/staging/octeon/ethernet-mdio.h index a530b55f27d8..5ed8483fc24d 100644 --- a/drivers/staging/octeon/ethernet-mdio.h +++ b/drivers/staging/octeon/ethernet-mdio.h @@ -25,7 +25,7 @@ extern const struct ethtool_ops cvm_oct_ethtool_ops; -extern void octeon_mdiobus_force_mod_depencency(void); +void octeon_mdiobus_force_mod_depencency(void); int cvm_oct_ioctl(struct net_device *dev, struct ifreq *rq, int cmd); int cvm_oct_phy_setup_device(struct net_device *dev); diff --git a/drivers/staging/octeon/ethernet-rgmii.c b/drivers/staging/octeon/ethernet-rgmii.c index beb7aac9c289..51dcb611702f 100644 --- a/drivers/staging/octeon/ethernet-rgmii.c +++ b/drivers/staging/octeon/ethernet-rgmii.c @@ -118,9 +118,10 @@ static void cvm_oct_rgmii_poll(struct net_device *dev) } /* Since the 10Mbps preamble workaround is allowed we need to enable - preamble checking, FCS stripping, and clear error bits on - every speed change. If errors occur during 10Mbps operation - the above code will change this stuff */ + * preamble checking, FCS stripping, and clear error bits on + * every speed change. If errors occur during 10Mbps operation + * the above code will change this stuff + */ cvm_oct_set_hw_preamble(priv, true); if (priv->phydev == NULL) { diff --git a/drivers/staging/octeon/ethernet-tx.c b/drivers/staging/octeon/ethernet-tx.c index 588354756c57..9e2116f4c915 100644 --- a/drivers/staging/octeon/ethernet-tx.c +++ b/drivers/staging/octeon/ethernet-tx.c @@ -396,10 +396,12 @@ dont_put_skbuff_in_hw: /* Check if we can use the hardware checksumming */ if ((skb->protocol == htons(ETH_P_IP)) && - (ip_hdr(skb)->version == 4) && (ip_hdr(skb)->ihl == 5) && - ((ip_hdr(skb)->frag_off == 0) || (ip_hdr(skb)->frag_off == htons(1 << 14))) - && ((ip_hdr(skb)->protocol == IPPROTO_TCP) - || (ip_hdr(skb)->protocol == IPPROTO_UDP))) { + (ip_hdr(skb)->version == 4) && + (ip_hdr(skb)->ihl == 5) && + ((ip_hdr(skb)->frag_off == 0) || + (ip_hdr(skb)->frag_off == htons(1 << 14))) && + ((ip_hdr(skb)->protocol == IPPROTO_TCP) || + (ip_hdr(skb)->protocol == IPPROTO_UDP))) { /* Use hardware checksum calc */ pko_command.s.ipoffp1 = sizeof(struct ethhdr) + 1; } diff --git a/drivers/staging/octeon/ethernet.c b/drivers/staging/octeon/ethernet.c index fbde4191e717..7274fda0b77b 100644 --- a/drivers/staging/octeon/ethernet.c +++ b/drivers/staging/octeon/ethernet.c @@ -157,6 +157,7 @@ static void cvm_oct_configure_common_hw(void) #ifdef __LITTLE_ENDIAN { union cvmx_ipd_ctl_status ipd_ctl_status; + ipd_ctl_status.u64 = cvmx_read_csr(CVMX_IPD_CTL_STATUS); ipd_ctl_status.s.pkt_lend = 1; ipd_ctl_status.s.wqe_lend = 1; diff --git a/drivers/staging/octeon/octeon-ethernet.h b/drivers/staging/octeon/octeon-ethernet.h index e9d3e9a7e8a7..a242c700bc53 100644 --- a/drivers/staging/octeon/octeon-ethernet.h +++ b/drivers/staging/octeon/octeon-ethernet.h @@ -53,20 +53,20 @@ struct octeon_ethernet { int cvm_oct_free_work(void *work_queue_entry); -extern int cvm_oct_rgmii_init(struct net_device *dev); -extern void cvm_oct_rgmii_uninit(struct net_device *dev); -extern int cvm_oct_rgmii_open(struct net_device *dev); +int cvm_oct_rgmii_init(struct net_device *dev); +void cvm_oct_rgmii_uninit(struct net_device *dev); +int cvm_oct_rgmii_open(struct net_device *dev); -extern int cvm_oct_sgmii_init(struct net_device *dev); -extern int cvm_oct_sgmii_open(struct net_device *dev); +int cvm_oct_sgmii_init(struct net_device *dev); +int cvm_oct_sgmii_open(struct net_device *dev); -extern int cvm_oct_spi_init(struct net_device *dev); -extern void cvm_oct_spi_uninit(struct net_device *dev); -extern int cvm_oct_xaui_init(struct net_device *dev); -extern int cvm_oct_xaui_open(struct net_device *dev); +int cvm_oct_spi_init(struct net_device *dev); +void cvm_oct_spi_uninit(struct net_device *dev); +int cvm_oct_xaui_init(struct net_device *dev); +int cvm_oct_xaui_open(struct net_device *dev); -extern int cvm_oct_common_init(struct net_device *dev); -extern void cvm_oct_common_uninit(struct net_device *dev); +int cvm_oct_common_init(struct net_device *dev); +void cvm_oct_common_uninit(struct net_device *dev); void cvm_oct_adjust_link(struct net_device *dev); int cvm_oct_common_stop(struct net_device *dev); int cvm_oct_common_open(struct net_device *dev, |