staging: rtl8723bs: remove unused code
cover staging: rtl8723bs: remove unused code
This series of patches removes dead code hidden behind unused ifdefs to improve readability.
Andrei Khomenkov (2):
staging: rtl8723bs: remove unused DBG_XMIT_BUF and DBG_XMIT_BUF_EXT
code
staging: rtl8723bs: remove unused TXDESC_64_BYTES code
drivers/staging/rtl8723bs/core/rtw_xmit.c | 7 ------- .../staging/rtl8723bs/hal/rtl8723bs_xmit.c | 5 ----- drivers/staging/rtl8723bs/include/rtw_xmit.h | 21 +------------------ 3 files changed, 1 insertion(+), 32 deletions(-)
Signature · 1 line
2.47.3
PATCH 1/2 staging: rtl8723bs: remove unused DBG_XMIT_BUF and DBG_XMIT_BUF_EXT code
Remove the DBG_XMIT_BUF and DBG_XMIT_BUF_EXT code since it is not used as the macros are not defined anywhere.
Signed-off-by Andrei Khomenkov <[email protected]>
--- drivers/staging/rtl8723bs/core/rtw_xmit.c | 7 ------- drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c | 5 ----- drivers/staging/rtl8723bs/include/rtw_xmit.h | 5 ----- 3 files changed, 17 deletions(-)
drivers/staging/rtl8723bs/core/rtw_xmit.c +0 -7
@@ -191,10 +191,6 @@ s32 _rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, struct adapter *padapter)list_add_tail (&pxmitbuf->list, &pxmitpriv->free_xmitbuf_queue.queue); -#ifdef DBG_XMIT_BUF - pxmitbuf->no = i; -#endif - pxmitbuf++; }
@@ -264,9 +260,6 @@ s32 _rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, struct adapter *padapter)list_add_tail (&pxmitbuf->list, &pxmitpriv->free_xmit_extbuf_queue.queue); -#ifdef DBG_XMIT_BUF_EXT - pxmitbuf->no = i; -#endif pxmitbuf++; }
drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c +0 -5
@@ -256,11 +256,6 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv pxmitbuf =rtw_alloc_xmitbuf (pxmitpriv);if (!pxmitbuf) { -#ifdef DBG_XMIT_BUF -netdev_err (padapter->pnetdev, -"%s: xmit_buf is not enough!\n" , - __func__); -#endif err =-2 ;complete (&(pxmitpriv->xmit_comp));break ;
drivers/staging/rtl8723bs/include/rtw_xmit.h +0 -5
@@ -254,11 +254,6 @@ struct xmit_buf {u32 ff_hwaddr;u8 pg_num;u8 agg_num; - -#if defined(DBG_XMIT_BUF ) || defined(DBG_XMIT_BUF_EXT ) -u8 no; -#endif - };
Signature · 1 line
2.47.3
PATCH 2/2 staging: rtl8723bs: remove unused TXDESC_64_BYTES code
In reply to Andrei KhomenkovRemove the TXDESC_64_BYTES code since it is not used as the macro is not defined anywhere.
Signed-off-by Andrei Khomenkov <[email protected]>
--- drivers/staging/rtl8723bs/include/rtw_xmit.h | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-)
drivers/staging/rtl8723bs/include/rtw_xmit.h +1 -15
@@ -94,23 +94,9 @@ struct tx_desc {__le32 txdw6;__le32 txdw7; -#if defined(TXDESC_40_BYTES ) || defined(TXDESC_64_BYTES ) +#ifdef TXDESC_40_BYTES __le32 txdw8;__le32 txdw9; -#endif /* TXDESC_40_BYTES */ - -#ifdef TXDESC_64_BYTES -__le32 txdw10; -__le32 txdw11; - -/* 2008/05/15 MH Because PCIE HW memory R/W 4K limit. And now, our descriptor */ -/* size is 40 bytes. If you use more than 102 descriptor(103*40>4096), HW will execute */ -/* memoryR/W CRC error. And then all DMA fetch will fail. We must decrease descriptor */ -/* number or enlarge descriptor size as 64 bytes. */ -__le32 txdw12; -__le32 txdw13; -__le32 txdw14; -__le32 txdw15;#endif };
Signature · 1 line
2.47.3