diff options
author | Sudip Mukherjee <sudipm.mukherjee@gmail.com> | 2014-10-27 12:12:25 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-10-29 09:37:26 (GMT) |
commit | e29d3ebcda3ebc0193fb98c53c6c3ca6fa2fc030 (patch) | |
tree | e97d381a07c3cd43449fc9f83f41d18db8008f32 /drivers/staging/rtl8712/rtl871x_xmit.c | |
parent | eecc515a1b5ed6188562471f41a78988290376e6 (diff) | |
download | linux-e29d3ebcda3ebc0193fb98c53c6c3ca6fa2fc030.tar.xz |
staging: rtl8712: remove unused variables
unused variables are removed. These variables were only assigned some
values and after that they were never being used. So they are safe to
be removed , and it has been build tested.
I left a call to r8712_read32(padapter, TCR) and
r8712_read8(padapter, SDIO_HCPWM) .
r8712_read32() and r8712_read8() is ultimately calling usb_read32()
and usb_read8() respectively. and they are again calling
r8712_usbctrl_vendorreq().
this r8712_usbctrl_vendorreq() is communicating through the usb bus
and is sending and receiving the control msg.
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8712/rtl871x_xmit.c')
-rw-r--r-- | drivers/staging/rtl8712/rtl871x_xmit.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/drivers/staging/rtl8712/rtl871x_xmit.c b/drivers/staging/rtl8712/rtl871x_xmit.c index 9d26fd2..62a377e 100644 --- a/drivers/staging/rtl8712/rtl871x_xmit.c +++ b/drivers/staging/rtl8712/rtl871x_xmit.c @@ -184,7 +184,6 @@ void _free_xmit_priv(struct xmit_priv *pxmitpriv) sint r8712_update_attrib(struct _adapter *padapter, _pkt *pkt, struct pkt_attrib *pattrib) { - uint i; struct pkt_file pktfile; struct sta_info *psta = NULL; struct ethhdr etherhdr; @@ -199,7 +198,7 @@ sint r8712_update_attrib(struct _adapter *padapter, _pkt *pkt, _r8712_open_pktfile(pkt, &pktfile); - i = _r8712_pktfile_read(&pktfile, (unsigned char *)ðerhdr, ETH_HLEN); + _r8712_pktfile_read(&pktfile, (unsigned char *)ðerhdr, ETH_HLEN); pattrib->ether_type = ntohs(etherhdr.h_proto); @@ -236,7 +235,7 @@ sint r8712_update_attrib(struct _adapter *padapter, _pkt *pkt, /* for mp storing the txcmd per packet, * according to the info of txcmd to update pattrib */ /*get MP_TXDESC_SIZE bytes txcmd per packet*/ - i = _r8712_pktfile_read(&pktfile, (u8 *)&txdesc, TXDESC_SIZE); + _r8712_pktfile_read(&pktfile, (u8 *)&txdesc, TXDESC_SIZE); memcpy(pattrib->ra, pattrib->dst, ETH_ALEN); memcpy(pattrib->ta, pattrib->src, ETH_ALEN); pattrib->pctrl = 1; @@ -347,7 +346,7 @@ sint r8712_update_attrib(struct _adapter *padapter, _pkt *pkt, static sint xmitframe_addmic(struct _adapter *padapter, struct xmit_frame *pxmitframe) { - u32 curfragnum, length, datalen; + u32 curfragnum, length; u8 *pframe, *payload, mic[8]; struct mic_data micdata; struct sta_info *stainfo; @@ -369,7 +368,6 @@ static sint xmitframe_addmic(struct _adapter *padapter, u8 null_key[16] = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}; - datalen = pattrib->pktlen - pattrib->hdrlen; pframe = pxmitframe->buf_addr + TXDESC_OFFSET; if (bmcst) { if (!memcmp(psecuritypriv->XGrptxmickey @@ -825,16 +823,13 @@ void r8712_free_xmitframe(struct xmit_priv *pxmitpriv, unsigned long irqL; struct __queue *pfree_xmit_queue = &pxmitpriv->free_xmit_queue; struct _adapter *padapter = pxmitpriv->adapter; - struct sk_buff *pndis_pkt = NULL; if (pxmitframe == NULL) return; spin_lock_irqsave(&pfree_xmit_queue->lock, irqL); list_del_init(&pxmitframe->list); - if (pxmitframe->pkt) { - pndis_pkt = pxmitframe->pkt; + if (pxmitframe->pkt) pxmitframe->pkt = NULL; - } list_add_tail(&pxmitframe->list, &pfree_xmit_queue->queue); pxmitpriv->free_xmitframe_cnt++; spin_unlock_irqrestore(&pfree_xmit_queue->lock, irqL); |