mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
mt76: mt7915: use min_t() to make code cleaner
Use min_t() in order to make code cleaner. Reported-by: Zeal Robot <[email protected]> Signed-off-by: Changcheng Deng <[email protected]> Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
abd80cf68d
commit
a050c14b56
+2
-6
@@ -227,12 +227,8 @@ mt7915_tm_set_ipg_params(struct mt7915_phy *phy, u32 ipg, u8 mode)
|
||||
|
||||
ipg -= aifsn * slot_time;
|
||||
|
||||
if (ipg > TM_DEFAULT_SIFS) {
|
||||
if (ipg < TM_MAX_SIFS)
|
||||
sifs = ipg;
|
||||
else
|
||||
sifs = TM_MAX_SIFS;
|
||||
}
|
||||
if (ipg > TM_DEFAULT_SIFS)
|
||||
sifs = min_t(u32, ipg, TM_MAX_SIFS);
|
||||
}
|
||||
done:
|
||||
txv_time = mt76_get_field(dev, MT_TMAC_ATCR(phy->band_idx),
|
||||
|
||||
Reference in New Issue
Block a user