Search Linux Wireless

[bug report] rtw88: coex: add feature to enhance HID coexistence performance

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Ching-Te Ku,

The patch 5b2e9a35e456: "rtw88: coex: add feature to enhance HID
coexistence performance" from Nov 26, 2020, leads to the following
static checker warning:

	drivers/net/wireless/realtek/rtw88/coex.c:2099 rtw_coex_action_bt_a2dp_hid()
	error: uninitialized symbol 'interval'.

drivers/net/wireless/realtek/rtw88/coex.c
  2047  static void rtw_coex_action_bt_a2dp_hid(struct rtw_dev *rtwdev)
  2048  {
  2049          struct rtw_coex *coex = &rtwdev->coex;
  2050          struct rtw_coex_stat *coex_stat = &coex->stat;
  2051          struct rtw_coex_dm *coex_dm = &coex->dm;
  2052          struct rtw_efuse *efuse = &rtwdev->efuse;
  2053          struct rtw_chip_info *chip = rtwdev->chip;
  2054          u8 table_case, tdma_case, interval;
                                          ^^^^^^^^
  2055          u32 slot_type = 0;
  2056          bool is_toggle_table = false;
  2057  
  2058          slot_type = TDMA_4SLOT;
  2059  
  2060          rtw_dbg(rtwdev, RTW_DBG_COEX, "[BTCoex], %s()\n", __func__);
  2061          rtw_coex_set_ant_path(rtwdev, false, COEX_SET_ANT_2G);
  2062          rtw_coex_set_rf_para(rtwdev, chip->wl_rf_para_rx[0]);
  2063  
  2064          if (efuse->share_ant) {
  2065                  /* Shared-Ant */
  2066                  if (coex_stat->bt_ble_exist) {
  2067                          table_case = 26; /* for RCU */
  2068                  } else if (coex_stat->bt_418_hid_exist) {
  2069                          table_case = 9;
  2070                          interval = 1;
                                ^^^^^^^^^^^^
The "interval" variable is only set here and not on the other paths.

  2071                  } else {
  2072                          table_case = 9;
  2073                  }
  2074  
  2075                  if (coex_stat->wl_connecting || !coex_stat->wl_gl_busy) {
  2076                          tdma_case = 14;
  2077                  } else if (coex_stat->bt_418_hid_exist) {
  2078                          is_toggle_table = true;
  2079                          tdma_case = 23;
  2080                  } else {
  2081                          tdma_case = 13;
  2082                  }
  2083          } else {
  2084                  /* Non-Shared-Ant */
  2085                  if (coex_stat->bt_ble_exist)
  2086                          table_case = 121;
  2087                  else
  2088                          table_case = 113;
  2089  
  2090                  if (COEX_RSSI_HIGH(coex_dm->wl_rssi_state[1]))
  2091                          tdma_case = 112;
  2092                  else
  2093                          tdma_case = 113;
  2094          }
  2095  
  2096          rtw_coex_table(rtwdev, false, table_case);
  2097          if (is_toggle_table) {
  2098                  rtw_btc_wltoggle_table_a(rtwdev, true, table_case);
  2099                  rtw_btc_wltoggle_table_b(rtwdev, false, interval, COEX_WL_SLOT_TOGLLE);
                                                                ^^^^^^^^

  2100          }
  2101          rtw_coex_tdma(rtwdev, false, tdma_case | slot_type);
  2102  }

regards,
dan carpenter



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux