Skip to content

Commit

Permalink
rtlwifi: btcoex: 23b 1ant: fix duplicated code for different branches
Browse files Browse the repository at this point in the history
Refactor code in order to avoid identical code for different branches.

This issue was detected with the help of Coccinelle.

Addresses-Coverity-ID: 1415177
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
  • Loading branch information
Gustavo A. R. Silva authored and Kalle Valo committed Aug 24, 2017
1 parent d382b9c commit 14cc696
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8723b1ant.c
Original file line number Diff line number Diff line change
Expand Up @@ -600,14 +600,8 @@ static void halbtc8723b1ant_coex_table_with_type(struct btc_coexist *btcoexist,
0xffffff, 0x3);
break;
case 5:
if ((coex_sta->cck_ever_lock) && (coex_sta->scan_ap_num <= 5))
halbtc8723b1ant_coex_table(btcoexist, force_exec,
0x5a5a5a5a, 0x5aaa5a5a,
0xffffff, 0x3);
else
halbtc8723b1ant_coex_table(btcoexist, force_exec,
0x5a5a5a5a, 0x5aaa5a5a,
0xffffff, 0x3);
halbtc8723b1ant_coex_table(btcoexist, force_exec, 0x5a5a5a5a,
0x5aaa5a5a, 0xffffff, 0x3);
break;
case 6:
halbtc8723b1ant_coex_table(btcoexist, force_exec, 0x55555555,
Expand Down

0 comments on commit 14cc696

Please sign in to comment.