rf.c 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471
  1. /******************************************************************************
  2. *
  3. * Copyright(c) 2009-2012 Realtek Corporation.
  4. *
  5. * This program is free software; you can redistribute it and/or modify it
  6. * under the terms of version 2 of the GNU General Public License as
  7. * published by the Free Software Foundation.
  8. *
  9. * This program is distributed in the hope that it will be useful, but WITHOUT
  10. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11. * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
  12. * more details.
  13. *
  14. * The full GNU General Public License is included in this distribution in the
  15. * file called LICENSE.
  16. *
  17. * Contact Information:
  18. * wlanfae <wlanfae@realtek.com>
  19. * Realtek Corporation, No. 2, Innovation Road II, Hsinchu Science Park,
  20. * Hsinchu 300, Taiwan.
  21. *
  22. * Larry Finger <Larry.Finger@lwfinger.net>
  23. *
  24. *****************************************************************************/
  25. #include "../wifi.h"
  26. #include "reg.h"
  27. #include "def.h"
  28. #include "phy.h"
  29. #include "rf.h"
  30. #include "dm.h"
  31. static bool _rtl92c_phy_rf6052_config_parafile(struct ieee80211_hw *hw);
  32. void rtl92cu_phy_rf6052_set_bandwidth(struct ieee80211_hw *hw, u8 bandwidth)
  33. {
  34. struct rtl_priv *rtlpriv = rtl_priv(hw);
  35. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  36. switch (bandwidth) {
  37. case HT_CHANNEL_WIDTH_20:
  38. rtlphy->rfreg_chnlval[0] = ((rtlphy->rfreg_chnlval[0] &
  39. 0xfffff3ff) | 0x0400);
  40. rtl_set_rfreg(hw, RF90_PATH_A, RF_CHNLBW, RFREG_OFFSET_MASK,
  41. rtlphy->rfreg_chnlval[0]);
  42. break;
  43. case HT_CHANNEL_WIDTH_20_40:
  44. rtlphy->rfreg_chnlval[0] = ((rtlphy->rfreg_chnlval[0] &
  45. 0xfffff3ff));
  46. rtl_set_rfreg(hw, RF90_PATH_A, RF_CHNLBW, RFREG_OFFSET_MASK,
  47. rtlphy->rfreg_chnlval[0]);
  48. break;
  49. default:
  50. RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
  51. "unknown bandwidth: %#X\n", bandwidth);
  52. break;
  53. }
  54. }
  55. void rtl92cu_phy_rf6052_set_cck_txpower(struct ieee80211_hw *hw,
  56. u8 *ppowerlevel)
  57. {
  58. struct rtl_priv *rtlpriv = rtl_priv(hw);
  59. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  60. struct rtl_mac *mac = rtl_mac(rtl_priv(hw));
  61. struct rtl_efuse *rtlefuse = rtl_efuse(rtl_priv(hw));
  62. u32 tx_agc[2] = { 0, 0 }, tmpval = 0;
  63. bool turbo_scanoff = false;
  64. u8 idx1, idx2;
  65. u8 *ptr;
  66. if ((rtlefuse->eeprom_regulatory != 0) || (rtlefuse->external_pa))
  67. turbo_scanoff = true;
  68. if (mac->act_scanning) {
  69. tx_agc[RF90_PATH_A] = 0x3f3f3f3f;
  70. tx_agc[RF90_PATH_B] = 0x3f3f3f3f;
  71. for (idx1 = RF90_PATH_A; idx1 <= RF90_PATH_B; idx1++) {
  72. tx_agc[idx1] = ppowerlevel[idx1] |
  73. (ppowerlevel[idx1] << 8) |
  74. (ppowerlevel[idx1] << 16) |
  75. (ppowerlevel[idx1] << 24);
  76. if (tx_agc[idx1] > 0x20 && rtlefuse->external_pa)
  77. tx_agc[idx1] = 0x20;
  78. }
  79. } else {
  80. if (rtlpriv->dm.dynamic_txhighpower_lvl ==
  81. TXHIGHPWRLEVEL_LEVEL1) {
  82. tx_agc[RF90_PATH_A] = 0x10101010;
  83. tx_agc[RF90_PATH_B] = 0x10101010;
  84. } else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
  85. TXHIGHPWRLEVEL_LEVEL2) {
  86. tx_agc[RF90_PATH_A] = 0x00000000;
  87. tx_agc[RF90_PATH_B] = 0x00000000;
  88. } else {
  89. for (idx1 = RF90_PATH_A; idx1 <= RF90_PATH_B; idx1++) {
  90. tx_agc[idx1] = ppowerlevel[idx1] |
  91. (ppowerlevel[idx1] << 8) |
  92. (ppowerlevel[idx1] << 16) |
  93. (ppowerlevel[idx1] << 24);
  94. }
  95. if (rtlefuse->eeprom_regulatory == 0) {
  96. tmpval = (rtlphy->mcs_offset[0][6]) +
  97. (rtlphy->mcs_offset[0][7] << 8);
  98. tx_agc[RF90_PATH_A] += tmpval;
  99. tmpval = (rtlphy->mcs_offset[0][14]) +
  100. (rtlphy->mcs_offset[0][15] << 24);
  101. tx_agc[RF90_PATH_B] += tmpval;
  102. }
  103. }
  104. }
  105. for (idx1 = RF90_PATH_A; idx1 <= RF90_PATH_B; idx1++) {
  106. ptr = (u8 *) (&(tx_agc[idx1]));
  107. for (idx2 = 0; idx2 < 4; idx2++) {
  108. if (*ptr > RF6052_MAX_TX_PWR)
  109. *ptr = RF6052_MAX_TX_PWR;
  110. ptr++;
  111. }
  112. }
  113. tmpval = tx_agc[RF90_PATH_A] & 0xff;
  114. rtl_set_bbreg(hw, RTXAGC_A_CCK1_MCS32, MASKBYTE1, tmpval);
  115. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  116. "CCK PWR 1M (rf-A) = 0x%x (reg 0x%x)\n",
  117. tmpval, RTXAGC_A_CCK1_MCS32);
  118. tmpval = tx_agc[RF90_PATH_A] >> 8;
  119. if (mac->mode == WIRELESS_MODE_B)
  120. tmpval = tmpval & 0xff00ffff;
  121. rtl_set_bbreg(hw, RTXAGC_B_CCK11_A_CCK2_11, 0xffffff00, tmpval);
  122. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  123. "CCK PWR 2~11M (rf-A) = 0x%x (reg 0x%x)\n",
  124. tmpval, RTXAGC_B_CCK11_A_CCK2_11);
  125. tmpval = tx_agc[RF90_PATH_B] >> 24;
  126. rtl_set_bbreg(hw, RTXAGC_B_CCK11_A_CCK2_11, MASKBYTE0, tmpval);
  127. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  128. "CCK PWR 11M (rf-B) = 0x%x (reg 0x%x)\n",
  129. tmpval, RTXAGC_B_CCK11_A_CCK2_11);
  130. tmpval = tx_agc[RF90_PATH_B] & 0x00ffffff;
  131. rtl_set_bbreg(hw, RTXAGC_B_CCK1_55_MCS32, 0xffffff00, tmpval);
  132. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  133. "CCK PWR 1~5.5M (rf-B) = 0x%x (reg 0x%x)\n",
  134. tmpval, RTXAGC_B_CCK1_55_MCS32);
  135. }
  136. static void rtl92c_phy_get_power_base(struct ieee80211_hw *hw,
  137. u8 *ppowerlevel, u8 channel,
  138. u32 *ofdmbase, u32 *mcsbase)
  139. {
  140. struct rtl_priv *rtlpriv = rtl_priv(hw);
  141. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  142. struct rtl_efuse *rtlefuse = rtl_efuse(rtl_priv(hw));
  143. u32 powerBase0, powerBase1;
  144. u8 legacy_pwrdiff = 0, ht20_pwrdiff = 0;
  145. u8 i, powerlevel[2];
  146. for (i = 0; i < 2; i++) {
  147. powerlevel[i] = ppowerlevel[i];
  148. legacy_pwrdiff = rtlefuse->txpwr_legacyhtdiff[i][channel - 1];
  149. powerBase0 = powerlevel[i] + legacy_pwrdiff;
  150. powerBase0 = (powerBase0 << 24) | (powerBase0 << 16) |
  151. (powerBase0 << 8) | powerBase0;
  152. *(ofdmbase + i) = powerBase0;
  153. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  154. " [OFDM power base index rf(%c) = 0x%x]\n",
  155. i == 0 ? 'A' : 'B', *(ofdmbase + i));
  156. }
  157. for (i = 0; i < 2; i++) {
  158. if (rtlphy->current_chan_bw == HT_CHANNEL_WIDTH_20) {
  159. ht20_pwrdiff = rtlefuse->txpwr_ht20diff[i][channel - 1];
  160. powerlevel[i] += ht20_pwrdiff;
  161. }
  162. powerBase1 = powerlevel[i];
  163. powerBase1 = (powerBase1 << 24) |
  164. (powerBase1 << 16) | (powerBase1 << 8) | powerBase1;
  165. *(mcsbase + i) = powerBase1;
  166. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  167. " [MCS power base index rf(%c) = 0x%x]\n",
  168. i == 0 ? 'A' : 'B', *(mcsbase + i));
  169. }
  170. }
  171. static void _rtl92c_get_txpower_writeval_by_regulatory(struct ieee80211_hw *hw,
  172. u8 channel, u8 index,
  173. u32 *powerBase0,
  174. u32 *powerBase1,
  175. u32 *p_outwriteval)
  176. {
  177. struct rtl_priv *rtlpriv = rtl_priv(hw);
  178. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  179. struct rtl_efuse *rtlefuse = rtl_efuse(rtl_priv(hw));
  180. u8 i, chnlgroup = 0, pwr_diff_limit[4];
  181. u32 writeVal, customer_limit, rf;
  182. for (rf = 0; rf < 2; rf++) {
  183. switch (rtlefuse->eeprom_regulatory) {
  184. case 0:
  185. chnlgroup = 0;
  186. writeVal = rtlphy->mcs_offset
  187. [chnlgroup][index + (rf ? 8 : 0)]
  188. + ((index < 2) ? powerBase0[rf] : powerBase1[rf]);
  189. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  190. "RTK better performance,writeVal(%c) = 0x%x\n",
  191. rf == 0 ? 'A' : 'B', writeVal);
  192. break;
  193. case 1:
  194. if (rtlphy->pwrgroup_cnt == 1)
  195. chnlgroup = 0;
  196. if (rtlphy->pwrgroup_cnt >= 3) {
  197. if (channel <= 3)
  198. chnlgroup = 0;
  199. else if (channel >= 4 && channel <= 9)
  200. chnlgroup = 1;
  201. else if (channel > 9)
  202. chnlgroup = 2;
  203. if (rtlphy->current_chan_bw ==
  204. HT_CHANNEL_WIDTH_20)
  205. chnlgroup++;
  206. else
  207. chnlgroup += 4;
  208. }
  209. writeVal = rtlphy->mcs_offset[chnlgroup][index +
  210. (rf ? 8 : 0)] +
  211. ((index < 2) ? powerBase0[rf] :
  212. powerBase1[rf]);
  213. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  214. "Realtek regulatory, 20MHz, writeVal(%c) = 0x%x\n",
  215. rf == 0 ? 'A' : 'B', writeVal);
  216. break;
  217. case 2:
  218. writeVal = ((index < 2) ? powerBase0[rf] :
  219. powerBase1[rf]);
  220. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  221. "Better regulatory,writeVal(%c) = 0x%x\n",
  222. rf == 0 ? 'A' : 'B', writeVal);
  223. break;
  224. case 3:
  225. chnlgroup = 0;
  226. if (rtlphy->current_chan_bw ==
  227. HT_CHANNEL_WIDTH_20_40) {
  228. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  229. "customer's limit, 40MHzrf(%c) = 0x%x\n",
  230. rf == 0 ? 'A' : 'B',
  231. rtlefuse->pwrgroup_ht40[rf]
  232. [channel - 1]);
  233. } else {
  234. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  235. "customer's limit, 20MHz rf(%c) = 0x%x\n",
  236. rf == 0 ? 'A' : 'B',
  237. rtlefuse->pwrgroup_ht20[rf]
  238. [channel - 1]);
  239. }
  240. for (i = 0; i < 4; i++) {
  241. pwr_diff_limit[i] = (u8) ((rtlphy->mcs_offset
  242. [chnlgroup][index + (rf ? 8 : 0)]
  243. & (0x7f << (i * 8))) >> (i * 8));
  244. if (rtlphy->current_chan_bw ==
  245. HT_CHANNEL_WIDTH_20_40) {
  246. if (pwr_diff_limit[i] >
  247. rtlefuse->pwrgroup_ht40[rf]
  248. [channel - 1])
  249. pwr_diff_limit[i] = rtlefuse->
  250. pwrgroup_ht40[rf]
  251. [channel - 1];
  252. } else {
  253. if (pwr_diff_limit[i] >
  254. rtlefuse->pwrgroup_ht20[rf]
  255. [channel - 1])
  256. pwr_diff_limit[i] =
  257. rtlefuse->pwrgroup_ht20[rf]
  258. [channel - 1];
  259. }
  260. }
  261. customer_limit = (pwr_diff_limit[3] << 24) |
  262. (pwr_diff_limit[2] << 16) |
  263. (pwr_diff_limit[1] << 8) | (pwr_diff_limit[0]);
  264. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  265. "Customer's limit rf(%c) = 0x%x\n",
  266. rf == 0 ? 'A' : 'B', customer_limit);
  267. writeVal = customer_limit + ((index < 2) ?
  268. powerBase0[rf] : powerBase1[rf]);
  269. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  270. "Customer, writeVal rf(%c)= 0x%x\n",
  271. rf == 0 ? 'A' : 'B', writeVal);
  272. break;
  273. default:
  274. chnlgroup = 0;
  275. writeVal = rtlphy->mcs_offset[chnlgroup]
  276. [index + (rf ? 8 : 0)] + ((index < 2) ?
  277. powerBase0[rf] : powerBase1[rf]);
  278. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  279. "RTK better performance, writeValrf(%c) = 0x%x\n",
  280. rf == 0 ? 'A' : 'B', writeVal);
  281. break;
  282. }
  283. if (rtlpriv->dm.dynamic_txhighpower_lvl ==
  284. TXHIGHPWRLEVEL_LEVEL1)
  285. writeVal = 0x14141414;
  286. else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
  287. TXHIGHPWRLEVEL_LEVEL2)
  288. writeVal = 0x00000000;
  289. if (rtlpriv->dm.dynamic_txhighpower_lvl == TXHIGHPWRLEVEL_BT1)
  290. writeVal = writeVal - 0x06060606;
  291. else if (rtlpriv->dm.dynamic_txhighpower_lvl ==
  292. TXHIGHPWRLEVEL_BT2)
  293. writeVal = writeVal;
  294. *(p_outwriteval + rf) = writeVal;
  295. }
  296. }
  297. static void _rtl92c_write_ofdm_power_reg(struct ieee80211_hw *hw,
  298. u8 index, u32 *pValue)
  299. {
  300. struct rtl_priv *rtlpriv = rtl_priv(hw);
  301. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  302. u16 regoffset_a[6] = {
  303. RTXAGC_A_RATE18_06, RTXAGC_A_RATE54_24,
  304. RTXAGC_A_MCS03_MCS00, RTXAGC_A_MCS07_MCS04,
  305. RTXAGC_A_MCS11_MCS08, RTXAGC_A_MCS15_MCS12
  306. };
  307. u16 regoffset_b[6] = {
  308. RTXAGC_B_RATE18_06, RTXAGC_B_RATE54_24,
  309. RTXAGC_B_MCS03_MCS00, RTXAGC_B_MCS07_MCS04,
  310. RTXAGC_B_MCS11_MCS08, RTXAGC_B_MCS15_MCS12
  311. };
  312. u8 i, rf, pwr_val[4];
  313. u32 writeVal;
  314. u16 regoffset;
  315. for (rf = 0; rf < 2; rf++) {
  316. writeVal = pValue[rf];
  317. for (i = 0; i < 4; i++) {
  318. pwr_val[i] = (u8)((writeVal & (0x7f << (i * 8))) >>
  319. (i * 8));
  320. if (pwr_val[i] > RF6052_MAX_TX_PWR)
  321. pwr_val[i] = RF6052_MAX_TX_PWR;
  322. }
  323. writeVal = (pwr_val[3] << 24) | (pwr_val[2] << 16) |
  324. (pwr_val[1] << 8) | pwr_val[0];
  325. if (rf == 0)
  326. regoffset = regoffset_a[index];
  327. else
  328. regoffset = regoffset_b[index];
  329. rtl_set_bbreg(hw, regoffset, MASKDWORD, writeVal);
  330. RTPRINT(rtlpriv, FPHY, PHY_TXPWR,
  331. "Set 0x%x = %08x\n", regoffset, writeVal);
  332. if (((get_rf_type(rtlphy) == RF_2T2R) &&
  333. (regoffset == RTXAGC_A_MCS15_MCS12 ||
  334. regoffset == RTXAGC_B_MCS15_MCS12)) ||
  335. ((get_rf_type(rtlphy) != RF_2T2R) &&
  336. (regoffset == RTXAGC_A_MCS07_MCS04 ||
  337. regoffset == RTXAGC_B_MCS07_MCS04))) {
  338. writeVal = pwr_val[3];
  339. if (regoffset == RTXAGC_A_MCS15_MCS12 ||
  340. regoffset == RTXAGC_A_MCS07_MCS04)
  341. regoffset = 0xc90;
  342. if (regoffset == RTXAGC_B_MCS15_MCS12 ||
  343. regoffset == RTXAGC_B_MCS07_MCS04)
  344. regoffset = 0xc98;
  345. for (i = 0; i < 3; i++) {
  346. if (i != 2)
  347. writeVal = (writeVal > 8) ?
  348. (writeVal - 8) : 0;
  349. else
  350. writeVal = (writeVal > 6) ?
  351. (writeVal - 6) : 0;
  352. rtl_write_byte(rtlpriv, (u32)(regoffset + i),
  353. (u8)writeVal);
  354. }
  355. }
  356. }
  357. }
  358. void rtl92cu_phy_rf6052_set_ofdm_txpower(struct ieee80211_hw *hw,
  359. u8 *ppowerlevel, u8 channel)
  360. {
  361. u32 writeVal[2], powerBase0[2], powerBase1[2];
  362. u8 index = 0;
  363. rtl92c_phy_get_power_base(hw, ppowerlevel,
  364. channel, &powerBase0[0], &powerBase1[0]);
  365. for (index = 0; index < 6; index++) {
  366. _rtl92c_get_txpower_writeval_by_regulatory(hw,
  367. channel, index,
  368. &powerBase0[0],
  369. &powerBase1[0],
  370. &writeVal[0]);
  371. _rtl92c_write_ofdm_power_reg(hw, index, &writeVal[0]);
  372. }
  373. }
  374. bool rtl92cu_phy_rf6052_config(struct ieee80211_hw *hw)
  375. {
  376. struct rtl_priv *rtlpriv = rtl_priv(hw);
  377. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  378. bool rtstatus = true;
  379. u8 b_reg_hwparafile = 1;
  380. if (rtlphy->rf_type == RF_1T1R)
  381. rtlphy->num_total_rfpath = 1;
  382. else
  383. rtlphy->num_total_rfpath = 2;
  384. if (b_reg_hwparafile == 1)
  385. rtstatus = _rtl92c_phy_rf6052_config_parafile(hw);
  386. return rtstatus;
  387. }
  388. static bool _rtl92c_phy_rf6052_config_parafile(struct ieee80211_hw *hw)
  389. {
  390. struct rtl_priv *rtlpriv = rtl_priv(hw);
  391. struct rtl_phy *rtlphy = &(rtlpriv->phy);
  392. u32 u4_regvalue = 0;
  393. u8 rfpath;
  394. bool rtstatus = true;
  395. struct bb_reg_def *pphyreg;
  396. for (rfpath = 0; rfpath < rtlphy->num_total_rfpath; rfpath++) {
  397. pphyreg = &rtlphy->phyreg_def[rfpath];
  398. switch (rfpath) {
  399. case RF90_PATH_A:
  400. case RF90_PATH_C:
  401. u4_regvalue = rtl_get_bbreg(hw, pphyreg->rfintfs,
  402. BRFSI_RFENV);
  403. break;
  404. case RF90_PATH_B:
  405. case RF90_PATH_D:
  406. u4_regvalue = rtl_get_bbreg(hw, pphyreg->rfintfs,
  407. BRFSI_RFENV << 16);
  408. break;
  409. }
  410. rtl_set_bbreg(hw, pphyreg->rfintfe, BRFSI_RFENV << 16, 0x1);
  411. udelay(1);
  412. rtl_set_bbreg(hw, pphyreg->rfintfo, BRFSI_RFENV, 0x1);
  413. udelay(1);
  414. rtl_set_bbreg(hw, pphyreg->rfhssi_para2,
  415. B3WIREADDREAALENGTH, 0x0);
  416. udelay(1);
  417. rtl_set_bbreg(hw, pphyreg->rfhssi_para2, B3WIREDATALENGTH, 0x0);
  418. udelay(1);
  419. switch (rfpath) {
  420. case RF90_PATH_A:
  421. case RF90_PATH_B:
  422. rtstatus = rtl92cu_phy_config_rf_with_headerfile(hw,
  423. (enum radio_path) rfpath);
  424. break;
  425. case RF90_PATH_C:
  426. break;
  427. case RF90_PATH_D:
  428. break;
  429. }
  430. switch (rfpath) {
  431. case RF90_PATH_A:
  432. case RF90_PATH_C:
  433. rtl_set_bbreg(hw, pphyreg->rfintfs,
  434. BRFSI_RFENV, u4_regvalue);
  435. break;
  436. case RF90_PATH_B:
  437. case RF90_PATH_D:
  438. rtl_set_bbreg(hw, pphyreg->rfintfs,
  439. BRFSI_RFENV << 16, u4_regvalue);
  440. break;
  441. }
  442. if (!rtstatus) {
  443. RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE,
  444. "Radio[%d] Fail!!\n", rfpath);
  445. goto phy_rf_cfg_fail;
  446. }
  447. }
  448. RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, "<---\n");
  449. phy_rf_cfg_fail:
  450. return rtstatus;
  451. }