Commit da80ede2 authored by Himadri Pandya's avatar Himadri Pandya Committed by Greg Kroah-Hartman

staging: rtl8723bs: hal:Remove comparison to NULL in rtl8723bs_xmit.c

Remove comparison to NULL in file rtl8723bs_xmit.c. Suggested by Coccinelle.
Signed-off-by: default avatarHimadri Pandya <himadri18.07@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 3f181eb2
...@@ -63,7 +63,7 @@ static s32 rtl8723_dequeue_writeport(struct adapter *padapter) ...@@ -63,7 +63,7 @@ static s32 rtl8723_dequeue_writeport(struct adapter *padapter)
else else
pxmitbuf = dequeue_pending_xmitbuf(pxmitpriv); pxmitbuf = dequeue_pending_xmitbuf(pxmitpriv);
if (pxmitbuf == NULL) if (!pxmitbuf)
return true; return true;
deviceId = ffaddr2deviceId(pdvobjpriv, pxmitbuf->ff_hwaddr); deviceId = ffaddr2deviceId(pdvobjpriv, pxmitbuf->ff_hwaddr);
...@@ -283,8 +283,7 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv ...@@ -283,8 +283,7 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv
/* check xmit_buf size enough or not */ /* check xmit_buf size enough or not */
txlen = txdesc_size + rtw_wlan_pkt_size(pxmitframe); txlen = txdesc_size + rtw_wlan_pkt_size(pxmitframe);
if ( if( !pxmitbuf ||
(NULL == pxmitbuf) ||
((_RND(pxmitbuf->len, 8) + txlen) > max_xmit_len) || ((_RND(pxmitbuf->len, 8) + txlen) > max_xmit_len) ||
(k >= (rtw_hal_sdio_max_txoqt_free_space(padapter)-1)) (k >= (rtw_hal_sdio_max_txoqt_free_space(padapter)-1))
) { ) {
...@@ -307,7 +306,7 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv ...@@ -307,7 +306,7 @@ static s32 xmit_xmitframes(struct adapter *padapter, struct xmit_priv *pxmitpriv
} }
pxmitbuf = rtw_alloc_xmitbuf(pxmitpriv); pxmitbuf = rtw_alloc_xmitbuf(pxmitpriv);
if (pxmitbuf == NULL) { if (!pxmitbuf) {
#ifdef DBG_XMIT_BUF #ifdef DBG_XMIT_BUF
DBG_871X_LEVEL(_drv_err_, "%s: xmit_buf is not enough!\n", __func__); DBG_871X_LEVEL(_drv_err_, "%s: xmit_buf is not enough!\n", __func__);
#endif #endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment