RE: [PATCH 13/24] rtw89: 8852a: add 8852a specific files
flat view
From: Pkshih <pkshih@realtek.com>
Date: 2021-07-12 06:25:51
-----Original Message----- From: Oleksij Rempel [mailto:o.rempel@pengutronix.de] Sent: Saturday, July 10, 2021 1:28 PM To: Pkshih Cc: kvalo@codeaurora.org; linux-wireless@vger.kernel.org Subject: Re: [PATCH 13/24] rtw89: 8852a: add 8852a specific files On Fri, Jun 18, 2021 at 02:46:14PM +0800, Ping-Ke Shih wrote:quoted
+static struct rtw89_hfc_param_ini rtw8852a_hfc_param_ini_pcie[] = { + [RTW89_QTA_SCC] = {rtw8852a_hfc_chcfg_pcie, &rtw8852a_hfc_pubcfg_pcie, + &rtw_hfc_preccfg_pcie, RTW89_HCIFC_POH}, + [RTW89_QTA_DBCC] = {rtw8852a_hfc_chcfg_pcie, &rtw8852a_hfc_pubcfg_pcie, + &rtw_hfc_preccfg_pcie, RTW89_HCIFC_POH}, + [RTW89_QTA_SCC_STF] = {rtw8852a_hfc_chcfg_pcie_stf, + &rtw8852a_hfc_pubcfg_pcie_stf, + &rtw_hfc_preccfg_pcie_stf, RTW89_HCIFC_STF}, + [RTW89_QTA_DBCC_STF] = {rtw8852a_hfc_chcfg_pcie_stf, + &rtw8852a_hfc_pubcfg_pcie_stf, + &rtw_hfc_preccfg_pcie_stf, RTW89_HCIFC_STF}, + [RTW89_QTA_SU_TP] = {rtw8852a_hfc_chcfg_pcie_sutp, + &rtw8852a_hfc_pubcfg_pcie_sutp, + &rtw_hfc_preccfg_pcie, RTW89_HCIFC_POH}, + [RTW89_QTA_DLFW] = {NULL, NULL, &rtw_hfc_preccfg_pcie, RTW89_HCIFC_POH}, + [RTW89_QTA_LAMODE] = {rtw8852a_hfc_chcfg_pcie_la, + &rtw8852a_hfc_pubcfg_pcie_la, + &rtw_hfc_preccfg_pcie, RTW89_HCIFC_POH}, + [RTW89_QTA_INVALID] = {NULL}, +}; + +static struct rtw89_dle_mem rtw8852a_dle_mem_pcie[] = { + [RTW89_QTA_SCC] = {RTW89_QTA_SCC, &wde_size0, &ple_size0, &wde_qt0, + &wde_qt0, &ple_qt4, &ple_qt5}, + [RTW89_QTA_DBCC] = {RTW89_QTA_DBCC, &wde_size0, &ple_size0, &wde_qt0, + &wde_qt0, &ple_qt0, &ple_qt1}, + [RTW89_QTA_SCC_STF] = {RTW89_QTA_SCC_STF, &wde_size1, &ple_size2, + &wde_qt1, &wde_qt1, &ple_qt8, &ple_qt9}, + [RTW89_QTA_DBCC_STF] = {RTW89_QTA_DBCC_STF, &wde_size1, &ple_size2, + &wde_qt1, &wde_qt1, &ple_qt10, &ple_qt11}, + [RTW89_QTA_SU_TP] = {RTW89_QTA_SU_TP, &wde_size3, &ple_size3, + &wde_qt3, &wde_qt3, &ple_qt12, &ple_qt12}, + [RTW89_QTA_DLFW] = {RTW89_QTA_DLFW, &wde_size4, &ple_size4, + &wde_qt4, &wde_qt4, &ple_qt13, &ple_qt13}, + [RTW89_QTA_LAMODE] = {RTW89_QTA_LAMODE, &wde_size10, &ple_size10, + &wde_qt9, &wde_qt9, &ple_qt23, &ple_qt24}, + [RTW89_QTA_INVALID] = {RTW89_QTA_INVALID, NULL, NULL, NULL, NULL, NULL, + NULL}, +};IF I see it correctly, only some of this RTW89_QTA_* modes are actually used. If this modes are not used by the current state of the driver, please remove it. RTW89_QTA_SCC, RTW89_QTA_DLFW and RTW89_QTA_INVALID - are requested RTW89_QTA_DBCC, RTW89_QTA_SU_TP - not used. If so, please remove. RTW89_QTA_SCC_STF, RTW89_QTA_DBCC_STF and RTW89_QTA_LAMODE - kind of used but never set/requested? If so, please remove the modes and the code which depends on it. For example dle_rsvd_size() is executed if RTW89_QTA_LAMODE is set, but I can find any play where it is actually set.
Will remove unused parts.