Commit c7ff1bfe authored by Stanislaw Gruszka's avatar Stanislaw Gruszka Committed by Kalle Valo

rt2800: comment and simplify AGC init for RT6352

We do not need separate lines for calculating register values.
Also add comment that value is different than in vendor driver.
Suggested-by: default avatarDaniel Golle <daniel@makrotopia.org>
Signed-off-by: default avatarStanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent 7aca1488
...@@ -3989,9 +3989,12 @@ static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev, ...@@ -3989,9 +3989,12 @@ static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev,
rt2800_bbp_write(rt2x00dev, 195, 141); rt2800_bbp_write(rt2x00dev, 195, 141);
rt2800_bbp_write(rt2x00dev, 196, reg); rt2800_bbp_write(rt2x00dev, 196, reg);
/* AGC init */ /* AGC init.
reg = rf->channel <= 14 ? 0x1c : 0x24; * Despite the vendor driver using different values here for
reg += 2 * rt2x00dev->lna_gain; * RT6352 chip, we use 0x1c for now. This may have to be changed
* once TSSI got implemented.
*/
reg = (rf->channel <= 14 ? 0x1c : 0x24) + 2*rt2x00dev->lna_gain;
rt2800_bbp_write_with_rx_chain(rt2x00dev, 66, reg); rt2800_bbp_write_with_rx_chain(rt2x00dev, 66, reg);
rt2800_iq_calibrate(rt2x00dev, rf->channel); rt2800_iq_calibrate(rt2x00dev, rf->channel);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment