diff options
author | Ben Hutchings <bhutchings@solarflare.com> | 2012-11-16 07:44:56 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-11-19 19:13:59 -0500 |
commit | f1d29a3fa68ba7c0b78b659a0e427ab834a26b44 (patch) | |
tree | 9c753bdde61384321e3dc99929d6c2754cd76587 | |
parent | 01f1c6b994bc4e0cf048534e67702e08ae69a890 (diff) |
mlx4_en: Remove remnants of LRO support
Commit fa37a9586f92051de03a13e55e5ec3880bb6783e ('mlx4_en: Moving to
work with GRO') left behind the Kconfig depends/select, some dead
code and comments referring to LRO.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Acked-by: Amir Vadai <amirv@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx4/Kconfig | 3 | ||||
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx4/en_rx.c | 9 | ||||
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | 17 |
3 files changed, 4 insertions, 25 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx4/Kconfig b/drivers/net/ethernet/mellanox/mlx4/Kconfig index 5f027f95cc84..eb520ab64014 100644 --- a/drivers/net/ethernet/mellanox/mlx4/Kconfig +++ b/drivers/net/ethernet/mellanox/mlx4/Kconfig | |||
@@ -4,9 +4,8 @@ | |||
4 | 4 | ||
5 | config MLX4_EN | 5 | config MLX4_EN |
6 | tristate "Mellanox Technologies 10Gbit Ethernet support" | 6 | tristate "Mellanox Technologies 10Gbit Ethernet support" |
7 | depends on PCI && INET | 7 | depends on PCI |
8 | select MLX4_CORE | 8 | select MLX4_CORE |
9 | select INET_LRO | ||
10 | ---help--- | 9 | ---help--- |
11 | This driver supports Mellanox Technologies ConnectX Ethernet | 10 | This driver supports Mellanox Technologies ConnectX Ethernet |
12 | devices. | 11 | devices. |
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_rx.c b/drivers/net/ethernet/mellanox/mlx4/en_rx.c index 5aba5ecdf1e2..f76c9671f362 100644 --- a/drivers/net/ethernet/mellanox/mlx4/en_rx.c +++ b/drivers/net/ethernet/mellanox/mlx4/en_rx.c | |||
@@ -630,7 +630,7 @@ int mlx4_en_process_rx_cq(struct net_device *dev, struct mlx4_en_cq *cq, int bud | |||
630 | if ((cqe->status & cpu_to_be16(MLX4_CQE_STATUS_IPOK)) && | 630 | if ((cqe->status & cpu_to_be16(MLX4_CQE_STATUS_IPOK)) && |
631 | (cqe->checksum == cpu_to_be16(0xffff))) { | 631 | (cqe->checksum == cpu_to_be16(0xffff))) { |
632 | ring->csum_ok++; | 632 | ring->csum_ok++; |
633 | /* This packet is eligible for LRO if it is: | 633 | /* This packet is eligible for GRO if it is: |
634 | * - DIX Ethernet (type interpretation) | 634 | * - DIX Ethernet (type interpretation) |
635 | * - TCP/IP (v4) | 635 | * - TCP/IP (v4) |
636 | * - without IP options | 636 | * - without IP options |
@@ -667,7 +667,7 @@ int mlx4_en_process_rx_cq(struct net_device *dev, struct mlx4_en_cq *cq, int bud | |||
667 | goto next; | 667 | goto next; |
668 | } | 668 | } |
669 | 669 | ||
670 | /* LRO not possible, complete processing here */ | 670 | /* GRO not possible, complete processing here */ |
671 | ip_summed = CHECKSUM_UNNECESSARY; | 671 | ip_summed = CHECKSUM_UNNECESSARY; |
672 | } else { | 672 | } else { |
673 | ip_summed = CHECKSUM_NONE; | 673 | ip_summed = CHECKSUM_NONE; |
@@ -710,11 +710,8 @@ next: | |||
710 | ++cq->mcq.cons_index; | 710 | ++cq->mcq.cons_index; |
711 | index = (cq->mcq.cons_index) & ring->size_mask; | 711 | index = (cq->mcq.cons_index) & ring->size_mask; |
712 | cqe = &cq->buf[index]; | 712 | cqe = &cq->buf[index]; |
713 | if (++polled == budget) { | 713 | if (++polled == budget) |
714 | /* We are here because we reached the NAPI budget - | ||
715 | * flush only pending LRO sessions */ | ||
716 | goto out; | 714 | goto out; |
717 | } | ||
718 | } | 715 | } |
719 | 716 | ||
720 | out: | 717 | out: |
diff --git a/drivers/net/ethernet/mellanox/mlx4/mlx4_en.h b/drivers/net/ethernet/mellanox/mlx4/mlx4_en.h index 8a5e70d68894..d3eba8bcce13 100644 --- a/drivers/net/ethernet/mellanox/mlx4/mlx4_en.h +++ b/drivers/net/ethernet/mellanox/mlx4/mlx4_en.h | |||
@@ -95,8 +95,6 @@ | |||
95 | #define MLX4_EN_ALLOC_SIZE PAGE_ALIGN(16384) | 95 | #define MLX4_EN_ALLOC_SIZE PAGE_ALIGN(16384) |
96 | #define MLX4_EN_ALLOC_ORDER get_order(MLX4_EN_ALLOC_SIZE) | 96 | #define MLX4_EN_ALLOC_ORDER get_order(MLX4_EN_ALLOC_SIZE) |
97 | 97 | ||
98 | #define MLX4_EN_MAX_LRO_DESCRIPTORS 32 | ||
99 | |||
100 | /* Receive fragment sizes; we use at most 4 fragments (for 9600 byte MTU | 98 | /* Receive fragment sizes; we use at most 4 fragments (for 9600 byte MTU |
101 | * and 4K allocations) */ | 99 | * and 4K allocations) */ |
102 | enum { | 100 | enum { |
@@ -290,21 +288,6 @@ struct mlx4_en_rx_ring { | |||
290 | unsigned long csum_none; | 288 | unsigned long csum_none; |
291 | }; | 289 | }; |
292 | 290 | ||
293 | |||
294 | static inline int mlx4_en_can_lro(__be16 status) | ||
295 | { | ||
296 | return (status & cpu_to_be16(MLX4_CQE_STATUS_IPV4 | | ||
297 | MLX4_CQE_STATUS_IPV4F | | ||
298 | MLX4_CQE_STATUS_IPV6 | | ||
299 | MLX4_CQE_STATUS_IPV4OPT | | ||
300 | MLX4_CQE_STATUS_TCP | | ||
301 | MLX4_CQE_STATUS_UDP | | ||
302 | MLX4_CQE_STATUS_IPOK)) == | ||
303 | cpu_to_be16(MLX4_CQE_STATUS_IPV4 | | ||
304 | MLX4_CQE_STATUS_IPOK | | ||
305 | MLX4_CQE_STATUS_TCP); | ||
306 | } | ||
307 | |||
308 | struct mlx4_en_cq { | 291 | struct mlx4_en_cq { |
309 | struct mlx4_cq mcq; | 292 | struct mlx4_cq mcq; |
310 | struct mlx4_hwq_resources wqres; | 293 | struct mlx4_hwq_resources wqres; |