staging: rtl8188eu: Remove pdata, phead, ptail and pend from struct recv_buf
authornavin patidar <navin.patidar@gmail.com>
Sat, 3 May 2014 11:45:25 +0000 (17:15 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 4 May 2014 00:30:10 +0000 (20:30 -0400)
Driver is not making use of value stored in removed variables.

Signed-off-by: navin patidar <navin.patidar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/hal/rtl8188eu_recv.c
drivers/staging/rtl8188eu/hal/usb_ops_linux.c
drivers/staging/rtl8188eu/include/rtw_recv.h
drivers/staging/rtl8188eu/os_dep/recv_linux.c

index ee7fa6408fe416145d8b12de5e2810e14fc392bf..41a0c0dc521ee4e1d211f6ca927c3ad49c55161c 100644 (file)
 void rtl8188eu_init_recvbuf(struct adapter *padapter, struct recv_buf *precvbuf)
 {
        precvbuf->len = 0;
-
        precvbuf->ref_cnt = 0;
-
-       if (precvbuf->pbuf) {
-               precvbuf->pdata = precvbuf->pbuf;
-               precvbuf->phead = precvbuf->pbuf;
-               precvbuf->ptail = precvbuf->pbuf;
-               precvbuf->pend = precvbuf->pdata + MAX_RECVBUF_SZ;
-       }
 }
 
 int    rtl8188eu_init_recv_priv(struct adapter *padapter)
index 285cb5f3f727cdd298e5bece3c498b10b8cf3dbe..654c5b38b1ac5e7b72bb538019fe1e0a9e53023a 100644 (file)
@@ -615,18 +615,9 @@ static u32 usb_read_port(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, u8 *rmem)
                alignment = tmpaddr & (RECVBUFF_ALIGN_SZ-1);
                skb_reserve(precvbuf->pskb, (RECVBUFF_ALIGN_SZ - alignment));
 
-               precvbuf->phead = precvbuf->pskb->head;
-               precvbuf->pdata = precvbuf->pskb->data;
-               precvbuf->ptail = skb_tail_pointer(precvbuf->pskb);
-               precvbuf->pend = skb_end_pointer(precvbuf->pskb);
                precvbuf->pbuf = precvbuf->pskb->data;
        } else { /* reuse skb */
-               precvbuf->phead = precvbuf->pskb->head;
-               precvbuf->pdata = precvbuf->pskb->data;
-               precvbuf->ptail = skb_tail_pointer(precvbuf->pskb);
-               precvbuf->pend = skb_end_pointer(precvbuf->pskb);
                precvbuf->pbuf = precvbuf->pskb->data;
-
                precvbuf->reuse = false;
        }
 
index cac8acb1052288696e156822d1b643475f7f3e82..8d3424b257e6f3bf9658faf79bfd262d84f2dd39 100644 (file)
@@ -240,10 +240,6 @@ struct recv_buf {
        u8      *pbuf;
        u8      *pallocated_buf;
        u32     len;
-       u8      *phead;
-       u8      *pdata;
-       u8      *ptail;
-       u8      *pend;
        struct urb *purb;
        u32 alloc_sz;
        u8  irp_pending;
index 083833908e93f6a25fd6ad8b5c0f52cde4855421..99b5910e20f355b89c9d7525797badfc70bb1364 100644 (file)
@@ -63,10 +63,6 @@ int rtw_os_recvbuf_resource_alloc(struct adapter *padapter,
        precvbuf->reuse = false;
        precvbuf->pallocated_buf = NULL;
        precvbuf->pbuf = NULL;
-       precvbuf->pdata = NULL;
-       precvbuf->phead = NULL;
-       precvbuf->ptail = NULL;
-       precvbuf->pend = NULL;
        precvbuf->len = 0;
        return res;
 }