summaryrefslogtreecommitdiff
path: root/patches/collateral-evolutions/network/40-netdev-hw-features/drivers_net_ethernet_atheros_atl1c_atl1c_main.patch
diff options
context:
space:
mode:
Diffstat (limited to 'patches/collateral-evolutions/network/40-netdev-hw-features/drivers_net_ethernet_atheros_atl1c_atl1c_main.patch')
-rw-r--r--patches/collateral-evolutions/network/40-netdev-hw-features/drivers_net_ethernet_atheros_atl1c_atl1c_main.patch72
1 files changed, 0 insertions, 72 deletions
diff --git a/patches/collateral-evolutions/network/40-netdev-hw-features/drivers_net_ethernet_atheros_atl1c_atl1c_main.patch b/patches/collateral-evolutions/network/40-netdev-hw-features/drivers_net_ethernet_atheros_atl1c_atl1c_main.patch
deleted file mode 100644
index be9c1b8f..00000000
--- a/patches/collateral-evolutions/network/40-netdev-hw-features/drivers_net_ethernet_atheros_atl1c_atl1c_main.patch
+++ /dev/null
@@ -1,72 +0,0 @@
---- a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
-+++ b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
-@@ -494,6 +494,7 @@ static void atl1c_set_rxbufsize(struct a
- adapter->rx_frag_size = roundup_pow_of_two(head_size);
- }
-
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39))
- static netdev_features_t atl1c_fix_features(struct net_device *netdev,
- netdev_features_t features)
- {
-@@ -522,6 +523,7 @@ static int atl1c_set_features(struct net
-
- return 0;
- }
-+#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)) */
-
- /**
- * atl1c_change_mtu - Change the Maximum Transfer Unit
-@@ -554,8 +556,19 @@ static int atl1c_change_mtu(struct net_d
- netdev->mtu = new_mtu;
- adapter->hw.max_frame_size = new_mtu;
- atl1c_set_rxbufsize(adapter, netdev);
-+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,39))
-+ if (new_mtu > MAX_TSO_FRAME_SIZE) {
-+ adapter->netdev->features &= ~NETIF_F_TSO;
-+ adapter->netdev->features &= ~NETIF_F_TSO6;
-+ } else {
-+ adapter->netdev->features |= NETIF_F_TSO;
-+ adapter->netdev->features |= NETIF_F_TSO6;
-+ }
-+#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,39)) */
- atl1c_down(adapter);
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39))
- netdev_update_features(netdev);
-+#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)) */
- atl1c_up(adapter);
- clear_bit(__AT_RESETTING, &adapter->flags);
- }
-@@ -2504,8 +2517,10 @@ static const struct net_device_ops atl1c
- .ndo_set_mac_address = atl1c_set_mac_addr,
- .ndo_set_rx_mode = atl1c_set_multi,
- .ndo_change_mtu = atl1c_change_mtu,
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39))
- .ndo_fix_features = atl1c_fix_features,
- .ndo_set_features = atl1c_set_features,
-+#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)) */
- .ndo_do_ioctl = atl1c_ioctl,
- .ndo_tx_timeout = atl1c_tx_timeout,
- .ndo_get_stats = atl1c_get_stats,
-@@ -2523,6 +2538,7 @@ static int atl1c_init_netdev(struct net_
- netdev->watchdog_timeo = AT_TX_WATCHDOG;
- atl1c_set_ethtool_ops(netdev);
-
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39))
- /* TODO: add when ready */
- netdev->hw_features = NETIF_F_SG |
- NETIF_F_HW_CSUM |
-@@ -2531,6 +2547,14 @@ static int atl1c_init_netdev(struct net_
- NETIF_F_TSO6;
- netdev->features = netdev->hw_features |
- NETIF_F_HW_VLAN_CTAG_TX;
-+#else
-+ netdev->features = NETIF_F_SG |
-+ NETIF_F_HW_CSUM |
-+ NETIF_F_HW_VLAN_TX |
-+ NETIF_F_HW_VLAN_RX |
-+ NETIF_F_TSO |
-+ NETIF_F_TSO6;
-+#endif /* (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)) */
- return 0;
- }
-