rtlwifi: rtl8821ae: Place braces around empty if() body
authorLee Jones <lee.jones@linaro.org>
Mon, 2 Nov 2020 11:24:03 +0000 (11:24 +0000)
committerKalle Valo <kvalo@codeaurora.org>
Sat, 7 Nov 2020 16:14:48 +0000 (18:14 +0200)
Fixes the following W=1 kernel build warning(s):

 drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c: In function ‘_rtl8812ae_phy_get_txpower_limit’:
 drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c:2453:3: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]

Cc: Ping-Ke Shih <pkshih@realtek.com>
Cc: Kalle Valo <kvalo@codeaurora.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20201102112410.1049272-35-lee.jones@linaro.org
drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c

index 404a4eeaea98db0a893e012a0747f337c016808d..f39c035b9e4b0aedc9e0c30ab89e2c3ae0af8e86 100644 (file)
@@ -2446,8 +2446,9 @@ static s8 _rtl8812ae_phy_get_txpower_limit(struct ieee80211_hw *hw,
        else if (band == BAND_ON_5G)
                channel_temp = _rtl8812ae_phy_get_chnl_idx_of_txpwr_lmt(hw,
                BAND_ON_5G, channel);
-       else if (band == BAND_ON_BOTH)
+       else if (band == BAND_ON_BOTH) {
                ;/* BAND_ON_BOTH don't care temporarily */
+       }
 
        if (band_temp == -1 || regulation == -1 || bandwidth_temp == -1 ||
                rate_section == -1 || channel_temp == -1) {