From 6b313fba498546d171839f51bf700680d9bc5fa6 Mon Sep 17 00:00:00 2001 From: Larry Finger Date: Fri, 19 Jul 2013 16:35:51 -0500 Subject: [PATCH] rtl8188eu: Remove CONFIG_TCP_CSUM_OFFLOAD_TX This configuration option is not selected. Signed-off-by: Larry Finger --- hal/rtl8188eu_xmit.c | 13 +------------ include/osdep_service.h | 5 ----- include/rtw_xmit.h | 3 --- os_dep/os_intfs.c | 5 ----- os_dep/xmit_linux.c | 35 ----------------------------------- 5 files changed, 1 insertion(+), 60 deletions(-) diff --git a/hal/rtl8188eu_xmit.c b/hal/rtl8188eu_xmit.c index fc346f2..ac7860f 100644 --- a/hal/rtl8188eu_xmit.c +++ b/hal/rtl8188eu_xmit.c @@ -343,18 +343,7 @@ static s32 update_txdesc(struct xmit_frame *pxmitframe, u8 *pmem, s32 sz ,u8 bag ptxdesc->txdw5 |= cpu_to_le32(MRateToHwRate(pmlmeext->tx_rate)); } - -#ifdef CONFIG_TCP_CSUM_OFFLOAD_TX - /* offset 24 */ - if ( pattrib->hw_tcp_csum == 1 ) { - u8 ip_hdr_offset = 32 + pattrib->hdrlen + pattrib->iv_len + 8; - ptxdesc->txdw7 = (1 << 31) | (ip_hdr_offset << 16); - DBG_88E("ptxdesc->txdw7 = %08x\n", ptxdesc->txdw7); - } -#endif - } - else if ((pxmitframe->frame_tag&0x0f)== MGNT_FRAMETAG) - { + } else if ((pxmitframe->frame_tag&0x0f)== MGNT_FRAMETAG) { /* offset 4 */ ptxdesc->txdw1 |= cpu_to_le32(pattrib->mac_id&0x3f); diff --git a/include/osdep_service.h b/include/osdep_service.h index b4ebe23..83634f9 100644 --- a/include/osdep_service.h +++ b/include/osdep_service.h @@ -68,11 +68,6 @@ #include #endif //CONFIG_IOCTL_CFG80211 -#ifdef CONFIG_TCP_CSUM_OFFLOAD_TX -#include -#include -#endif - #include #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,21)) #include diff --git a/include/rtw_xmit.h b/include/rtw_xmit.h index 450e8b3..52e87ec 100644 --- a/include/rtw_xmit.h +++ b/include/rtw_xmit.h @@ -176,9 +176,6 @@ struct pkt_attrib u8 intel_proxim; u8 retry_ctrl; struct sta_info * psta; -#ifdef CONFIG_TCP_CSUM_OFFLOAD_TX - u8 hw_tcp_csum; -#endif }; #define WLANHDR_OFFSET 64 diff --git a/os_dep/os_intfs.c b/os_dep/os_intfs.c index f58e767..5b6976b 100644 --- a/os_dep/os_intfs.c +++ b/os_dep/os_intfs.c @@ -942,11 +942,6 @@ struct net_device *rtw_init_netdev(_adapter *old_padapter) pnetdev->get_stats = rtw_net_get_stats; pnetdev->do_ioctl = rtw_ioctl; #endif - - -#ifdef CONFIG_TCP_CSUM_OFFLOAD_TX - pnetdev->features |= NETIF_F_IP_CSUM; -#endif pnetdev->watchdog_timeo = HZ*3; /* 3 second timeout */ #ifdef CONFIG_WIRELESS_EXT pnetdev->wireless_handlers = (struct iw_handler_def *)&rtw_handlers_def; diff --git a/os_dep/xmit_linux.c b/os_dep/xmit_linux.c index e3b90ba..b408463 100644 --- a/os_dep/xmit_linux.c +++ b/os_dep/xmit_linux.c @@ -86,41 +86,6 @@ _func_exit_; void rtw_set_tx_chksum_offload(_pkt *pkt, struct pkt_attrib *pattrib) { - -#ifdef CONFIG_TCP_CSUM_OFFLOAD_TX - struct sk_buff *skb = (struct sk_buff *)pkt; - pattrib->hw_tcp_csum = 0; - - if (skb->ip_summed == CHECKSUM_PARTIAL) { - if (skb_shinfo(skb)->nr_frags == 0) - { - const struct iphdr *ip = ip_hdr(skb); - if (ip->protocol == IPPROTO_TCP) { - // TCP checksum offload by HW - DBG_88E("CHECKSUM_PARTIAL TCP\n"); - pattrib->hw_tcp_csum = 1; - //skb_checksum_help(skb); - } else if (ip->protocol == IPPROTO_UDP) { - //DBG_88E("CHECKSUM_PARTIAL UDP\n"); -#if 1 - skb_checksum_help(skb); -#else - // Set UDP checksum = 0 to skip checksum check - struct udphdr *udp = skb_transport_header(skb); - udp->check = 0; -#endif - } else { - DBG_88E("%s-%d TCP CSUM offload Error!!\n", __func__, __LINE__); - WARN_ON(1); /* we need a WARN() */ - } - } - else { // IP fragmentation case - DBG_88E("%s-%d nr_frags != 0, using skb_checksum_help(skb);!!\n", __func__, __LINE__); - skb_checksum_help(skb); - } - } -#endif - } int rtw_os_xmit_resource_alloc(_adapter *padapter, struct xmit_buf *pxmitbuf,u32 alloc_sz)