staging: rtl8192e: Remove variable ht_info->reg_short_gi_20mhz
authorPhilipp Hortmann <philipp.g.hortmann@gmail.com>
Sun, 10 Dec 2023 15:26:24 +0000 (16:26 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 15 Dec 2023 12:35:21 +0000 (13:35 +0100)
ht_info->reg_short_gi_20mhz is set to 1 and unchanged. Therefore all
equations result accordingly and ht_info->reg_short_gi_20mhz can be
removed.

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/a2778d12a2bb104a980a69f8eb05ba1cabf7b545.1702212003.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8192e/rtl819x_HT.h
drivers/staging/rtl8192e/rtl819x_HTProc.c

index 6556c5df958d764044eada6aeacece3e3a4a12f7..8a4bd389004a2c09741bdc4649eb4512acaa4644 100644 (file)
@@ -97,7 +97,6 @@ struct rt_hi_throughput {
        u8 cur_bw_40mhz;
        u8 reg_short_gi_40mhz;
        u8 cur_short_gi_40mhz;
-       u8 reg_short_gi_20mhz;
        u8 cur_short_gi_20mhz;
        u8 bCurSuppCCK;
        enum ht_spec_ver ePeerHTSpecVer;
index 7acc8b4c11c4affca3ddf117be0a717eee6aa5fd..ed9b3db1a3933ff55ccb8346efa7ee6f9eef2f2b 100644 (file)
@@ -71,7 +71,6 @@ void ht_update_default_setting(struct rtllib_device *ieee)
 {
        struct rt_hi_throughput *ht_info = ieee->ht_info;
 
-       ht_info->reg_short_gi_20mhz = 1;
        ht_info->reg_short_gi_40mhz = 1;
 
        ht_info->amsdu_max_size = 7935UL;
@@ -471,9 +470,7 @@ void HTOnAssocRsp(struct rtllib_device *ieee)
        ht_info->cur_tx_bw40mhz = ((pPeerHTInfo->RecommemdedTxWidth == 1) ?
                                 true : false);
 
-       ht_info->cur_short_gi_20mhz = ((ht_info->reg_short_gi_20mhz) ?
-                                   ((pPeerHTCap->ShortGI20Mhz == 1) ?
-                                   true : false) : false);
+       ht_info->cur_short_gi_20mhz = ((pPeerHTCap->ShortGI20Mhz == 1) ? true : false);
        ht_info->cur_short_gi_40mhz = ((ht_info->reg_short_gi_40mhz) ?
                                     ((pPeerHTCap->ShortGI40Mhz == 1) ?
                                     true : false) : false);