Commit ceb2f735 authored by Nicholas Mc Guire's avatar Nicholas Mc Guire Committed by Greg Kroah-Hartman

staging: rtl8723au: multiple condition with no effect - if identical to else

A number if/else if/else branches are identical - so the condition has no
effect on the effective code and can be significantly simplified - this
patch removes the condition and the duplicated code.
Signed-off-by: default avatarNicholas Mc Guire <hofrat@osadl.org>
Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 11862b36
...@@ -7255,63 +7255,19 @@ btdm_2AntTdmaDurationAdjust(struct rtw_adapter *padapter, u8 bScoHid, ...@@ -7255,63 +7255,19 @@ btdm_2AntTdmaDurationAdjust(struct rtw_adapter *padapter, u8 bScoHid,
RTPRINT(FBT, BT_TRACE, ("[BTCoex], first run TdmaDurationAdjust()!!\n")); RTPRINT(FBT, BT_TRACE, ("[BTCoex], first run TdmaDurationAdjust()!!\n"));
if (bScoHid) { if (bScoHid) {
if (bTxPause) { if (bTxPause) {
if (maxInterval == 1) { btdm_2AntPsTdma(padapter, true, 15);
btdm_2AntPsTdma(padapter, true, 15); pBtdm8723->psTdmaDuAdjType = 15;
pBtdm8723->psTdmaDuAdjType = 15;
} else if (maxInterval == 2) {
btdm_2AntPsTdma(padapter, true, 15);
pBtdm8723->psTdmaDuAdjType = 15;
} else if (maxInterval == 3) {
btdm_2AntPsTdma(padapter, true, 15);
pBtdm8723->psTdmaDuAdjType = 15;
} else {
btdm_2AntPsTdma(padapter, true, 15);
pBtdm8723->psTdmaDuAdjType = 15;
}
} else { } else {
if (maxInterval == 1) { btdm_2AntPsTdma(padapter, true, 11);
btdm_2AntPsTdma(padapter, true, 11); pBtdm8723->psTdmaDuAdjType = 11;
pBtdm8723->psTdmaDuAdjType = 11;
} else if (maxInterval == 2) {
btdm_2AntPsTdma(padapter, true, 11);
pBtdm8723->psTdmaDuAdjType = 11;
} else if (maxInterval == 3) {
btdm_2AntPsTdma(padapter, true, 11);
pBtdm8723->psTdmaDuAdjType = 11;
} else {
btdm_2AntPsTdma(padapter, true, 11);
pBtdm8723->psTdmaDuAdjType = 11;
}
} }
} else { } else {
if (bTxPause) { if (bTxPause) {
if (maxInterval == 1) { btdm_2AntPsTdma(padapter, true, 7);
btdm_2AntPsTdma(padapter, true, 7); pBtdm8723->psTdmaDuAdjType = 7;
pBtdm8723->psTdmaDuAdjType = 7;
} else if (maxInterval == 2) {
btdm_2AntPsTdma(padapter, true, 7);
pBtdm8723->psTdmaDuAdjType = 7;
} else if (maxInterval == 3) {
btdm_2AntPsTdma(padapter, true, 7);
pBtdm8723->psTdmaDuAdjType = 7;
} else {
btdm_2AntPsTdma(padapter, true, 7);
pBtdm8723->psTdmaDuAdjType = 7;
}
} else { } else {
if (maxInterval == 1) { btdm_2AntPsTdma(padapter, true, 3);
btdm_2AntPsTdma(padapter, true, 3); pBtdm8723->psTdmaDuAdjType = 3;
pBtdm8723->psTdmaDuAdjType = 3;
} else if (maxInterval == 2) {
btdm_2AntPsTdma(padapter, true, 3);
pBtdm8723->psTdmaDuAdjType = 3;
} else if (maxInterval == 3) {
btdm_2AntPsTdma(padapter, true, 3);
pBtdm8723->psTdmaDuAdjType = 3;
} else {
btdm_2AntPsTdma(padapter, true, 3);
pBtdm8723->psTdmaDuAdjType = 3;
}
} }
} }
up = 0; up = 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