Lines Matching full:cal
171 u8 limit = dev->cal.low_gain > 0 ? 16 : 4; in mt76x02_phy_adjust_vga_gain()
177 dev->cal.false_cca = false_cca; in mt76x02_phy_adjust_vga_gain()
178 if (false_cca > 800 && dev->cal.agc_gain_adjust < limit) { in mt76x02_phy_adjust_vga_gain()
179 dev->cal.agc_gain_adjust += 2; in mt76x02_phy_adjust_vga_gain()
181 } else if ((false_cca < 10 && dev->cal.agc_gain_adjust > 0) || in mt76x02_phy_adjust_vga_gain()
182 (dev->cal.agc_gain_adjust >= limit && false_cca < 500)) { in mt76x02_phy_adjust_vga_gain()
183 dev->cal.agc_gain_adjust -= 2; in mt76x02_phy_adjust_vga_gain()
187 dev->cal.agc_lowest_gain = dev->cal.agc_gain_adjust >= limit; in mt76x02_phy_adjust_vga_gain()
195 dev->cal.agc_gain_init[0] = mt76_get_field(dev, MT_BBP(AGC, 8), in mt76x02_init_agc_gain()
197 dev->cal.agc_gain_init[1] = mt76_get_field(dev, MT_BBP(AGC, 9), in mt76x02_init_agc_gain()
199 memcpy(dev->cal.agc_gain_cur, dev->cal.agc_gain_init, in mt76x02_init_agc_gain()
200 sizeof(dev->cal.agc_gain_cur)); in mt76x02_init_agc_gain()
201 dev->cal.low_gain = -1; in mt76x02_init_agc_gain()
202 dev->cal.gain_init_done = true; in mt76x02_init_agc_gain()