Commit 7db57ca4 authored by Javier F. Arias's avatar Javier F. Arias Committed by Greg Kroah-Hartman

staging: rtl8723bs: Remove unnecessary braces

This patch removes unnecessary braces on single statement blocks or
that aren't necessary in any arm of the statement.
Issue found by Checkpatch.
Signed-off-by: default avatarJavier F. Arias <jarias.linux@gmail.com>
Link: https://lore.kernel.org/r/041503946a1c58111e69579838b184359745d8c1.1573577309.git.jarias.linux@gmail.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 309e05f5
...@@ -253,9 +253,8 @@ s32 _rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, struct adapter *padapter) ...@@ -253,9 +253,8 @@ s32 _rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, struct adapter *padapter)
goto exit; goto exit;
rtw_init_hwxmits(pxmitpriv->hwxmits, pxmitpriv->hwxmit_entry); rtw_init_hwxmits(pxmitpriv->hwxmits, pxmitpriv->hwxmit_entry);
for (i = 0; i < 4; i++) { for (i = 0; i < 4; i++)
pxmitpriv->wmm_para_seq[i] = i; pxmitpriv->wmm_para_seq[i] = i;
}
pxmitpriv->ack_tx = false; pxmitpriv->ack_tx = false;
mutex_init(&pxmitpriv->ack_tx_mutex); mutex_init(&pxmitpriv->ack_tx_mutex);
...@@ -316,9 +315,8 @@ void _rtw_free_xmit_priv(struct xmit_priv *pxmitpriv) ...@@ -316,9 +315,8 @@ void _rtw_free_xmit_priv(struct xmit_priv *pxmitpriv)
pxmitbuf++; pxmitbuf++;
} }
if (pxmitpriv->pallocated_xmit_extbuf) { if (pxmitpriv->pallocated_xmit_extbuf)
vfree(pxmitpriv->pallocated_xmit_extbuf); vfree(pxmitpriv->pallocated_xmit_extbuf);
}
for (i = 0; i < CMDBUF_MAX; i++) { for (i = 0; i < CMDBUF_MAX; i++) {
pxmitbuf = &pxmitpriv->pcmd_xmitbuf[i]; pxmitbuf = &pxmitpriv->pcmd_xmitbuf[i];
...@@ -834,15 +832,13 @@ static s32 xmitframe_addmic(struct adapter *padapter, struct xmit_frame *pxmitfr ...@@ -834,15 +832,13 @@ static s32 xmitframe_addmic(struct adapter *padapter, struct xmit_frame *pxmitfr
pframe = pxmitframe->buf_addr + hw_hdr_offset; pframe = pxmitframe->buf_addr + hw_hdr_offset;
if (bmcst) { if (bmcst) {
if (!memcmp(psecuritypriv->dot118021XGrptxmickey[psecuritypriv->dot118021XGrpKeyid].skey, null_key, 16)) { if (!memcmp(psecuritypriv->dot118021XGrptxmickey[psecuritypriv->dot118021XGrpKeyid].skey, null_key, 16))
return _FAIL; return _FAIL;
}
/* start to calculate the mic code */ /* start to calculate the mic code */
rtw_secmicsetkey(&micdata, psecuritypriv->dot118021XGrptxmickey[psecuritypriv->dot118021XGrpKeyid].skey); rtw_secmicsetkey(&micdata, psecuritypriv->dot118021XGrptxmickey[psecuritypriv->dot118021XGrpKeyid].skey);
} else { } else {
if (!memcmp(&pattrib->dot11tkiptxmickey.skey[0], null_key, 16)) { if (!memcmp(&pattrib->dot11tkiptxmickey.skey[0], null_key, 16))
return _FAIL; return _FAIL;
}
/* start to calculate the mic code */ /* start to calculate the mic code */
rtw_secmicsetkey(&micdata, &pattrib->dot11tkiptxmickey.skey[0]); rtw_secmicsetkey(&micdata, &pattrib->dot11tkiptxmickey.skey[0]);
} }
...@@ -1180,9 +1176,8 @@ s32 rtw_xmitframe_coalesce(struct adapter *padapter, _pkt *pkt, struct xmit_fram ...@@ -1180,9 +1176,8 @@ s32 rtw_xmitframe_coalesce(struct adapter *padapter, _pkt *pkt, struct xmit_fram
mpdu_len -= llc_sz; mpdu_len -= llc_sz;
} }
if ((pattrib->icv_len > 0) && (pattrib->bswenc)) { if ((pattrib->icv_len > 0) && (pattrib->bswenc))
mpdu_len -= pattrib->icv_len; mpdu_len -= pattrib->icv_len;
}
if (bmcst) { if (bmcst) {
/* don't do fragment to broadcat/multicast packets */ /* don't do fragment to broadcat/multicast packets */
...@@ -1979,9 +1974,8 @@ s32 rtw_xmit_classifier(struct adapter *padapter, struct xmit_frame *pxmitframe) ...@@ -1979,9 +1974,8 @@ s32 rtw_xmit_classifier(struct adapter *padapter, struct xmit_frame *pxmitframe)
ptxservq = rtw_get_sta_pending(padapter, psta, pattrib->priority, (u8 *)(&ac_index)); ptxservq = rtw_get_sta_pending(padapter, psta, pattrib->priority, (u8 *)(&ac_index));
if (list_empty(&ptxservq->tx_pending)) { if (list_empty(&ptxservq->tx_pending))
list_add_tail(&ptxservq->tx_pending, get_list_head(phwxmits[ac_index].sta_queue)); list_add_tail(&ptxservq->tx_pending, get_list_head(phwxmits[ac_index].sta_queue));
}
list_add_tail(&pxmitframe->list, get_list_head(&ptxservq->sta_pending)); list_add_tail(&pxmitframe->list, get_list_head(&ptxservq->sta_pending));
ptxservq->qcnt++; ptxservq->qcnt++;
...@@ -2043,9 +2037,8 @@ void rtw_init_hwxmits(struct hw_xmit *phwxmit, sint entry) ...@@ -2043,9 +2037,8 @@ void rtw_init_hwxmits(struct hw_xmit *phwxmit, sint entry)
{ {
sint i; sint i;
for (i = 0; i < entry; i++, phwxmit++) { for (i = 0; i < entry; i++, phwxmit++)
phwxmit->accnt = 0; phwxmit->accnt = 0;
}
} }
u32 rtw_get_ff_hwaddr(struct xmit_frame *pxmitframe) u32 rtw_get_ff_hwaddr(struct xmit_frame *pxmitframe)
...@@ -2253,11 +2246,10 @@ sint xmitframe_enqueue_for_sleeping_sta(struct adapter *padapter, struct xmit_fr ...@@ -2253,11 +2246,10 @@ sint xmitframe_enqueue_for_sleeping_sta(struct adapter *padapter, struct xmit_fr
pstapriv->tim_bitmap |= BIT(0); pstapriv->tim_bitmap |= BIT(0);
pstapriv->sta_dz_bitmap |= BIT(0); pstapriv->sta_dz_bitmap |= BIT(0);
if (update_tim) { if (update_tim)
update_beacon(padapter, _TIM_IE_, NULL, true); update_beacon(padapter, _TIM_IE_, NULL, true);
} else { else
chk_bmc_sleepq_cmd(padapter); chk_bmc_sleepq_cmd(padapter);
}
ret = true; ret = true;
...@@ -2464,9 +2456,8 @@ void wakeup_sta_to_xmit(struct adapter *padapter, struct sta_info *psta) ...@@ -2464,9 +2456,8 @@ void wakeup_sta_to_xmit(struct adapter *padapter, struct sta_info *psta)
} }
if (psta->sleepq_len == 0) { if (psta->sleepq_len == 0) {
if (pstapriv->tim_bitmap & BIT(psta->aid)) { if (pstapriv->tim_bitmap & BIT(psta->aid))
update_mask = BIT(0); update_mask = BIT(0);
}
pstapriv->tim_bitmap &= ~BIT(psta->aid); pstapriv->tim_bitmap &= ~BIT(psta->aid);
...@@ -2508,9 +2499,9 @@ void wakeup_sta_to_xmit(struct adapter *padapter, struct sta_info *psta) ...@@ -2508,9 +2499,9 @@ void wakeup_sta_to_xmit(struct adapter *padapter, struct sta_info *psta)
} }
if (psta_bmc->sleepq_len == 0) { if (psta_bmc->sleepq_len == 0) {
if (pstapriv->tim_bitmap & BIT(0)) { if (pstapriv->tim_bitmap & BIT(0))
update_mask |= BIT(1); update_mask |= BIT(1);
}
pstapriv->tim_bitmap &= ~BIT(0); pstapriv->tim_bitmap &= ~BIT(0);
pstapriv->sta_dz_bitmap &= ~BIT(0); pstapriv->sta_dz_bitmap &= ~BIT(0);
} }
......
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