mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
mt76: move band capabilities in mt76_phy
This is a preliminary patch to move properly support mt7915 dbdc Signed-off-by: Lorenzo Bianconi <[email protected]> Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
576647f2ec
commit
e881fd67c7
+3
-3
@@ -52,15 +52,15 @@ static void mt76x0_set_chip_cap(struct mt76x02_dev *dev)
|
||||
|
||||
mt76x02_eeprom_parse_hw_cap(dev);
|
||||
dev_dbg(dev->mt76.dev, "2GHz %d 5GHz %d\n",
|
||||
dev->mt76.cap.has_2ghz, dev->mt76.cap.has_5ghz);
|
||||
dev->mphy.cap.has_2ghz, dev->mphy.cap.has_5ghz);
|
||||
|
||||
if (dev->no_2ghz) {
|
||||
dev->mt76.cap.has_2ghz = false;
|
||||
dev->mphy.cap.has_2ghz = false;
|
||||
dev_dbg(dev->mt76.dev, "mask out 2GHz support\n");
|
||||
}
|
||||
|
||||
if (is_mt7630(dev)) {
|
||||
dev->mt76.cap.has_5ghz = false;
|
||||
dev->mphy.cap.has_5ghz = false;
|
||||
dev_dbg(dev->mt76.dev, "mask out 5GHz support\n");
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -245,7 +245,7 @@ int mt76x0_register_device(struct mt76x02_dev *dev)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
if (dev->mt76.cap.has_5ghz) {
|
||||
if (dev->mphy.cap.has_5ghz) {
|
||||
struct ieee80211_supported_band *sband;
|
||||
|
||||
sband = &dev->mphy.sband_5g.sband;
|
||||
@@ -253,7 +253,7 @@ int mt76x0_register_device(struct mt76x02_dev *dev)
|
||||
mt76x0_init_txpower(dev, sband);
|
||||
}
|
||||
|
||||
if (dev->mt76.cap.has_2ghz)
|
||||
if (dev->mphy.cap.has_2ghz)
|
||||
mt76x0_init_txpower(dev, &dev->mphy.sband_2g.sband);
|
||||
|
||||
mt76x02_init_debugfs(dev);
|
||||
|
||||
+2
-2
@@ -447,11 +447,11 @@ static void mt76x0_phy_ant_select(struct mt76x02_dev *dev)
|
||||
else
|
||||
coex3 |= BIT(4);
|
||||
coex3 |= BIT(3);
|
||||
if (dev->mt76.cap.has_2ghz)
|
||||
if (dev->mphy.cap.has_2ghz)
|
||||
wlan |= BIT(6);
|
||||
} else {
|
||||
/* sigle antenna mode */
|
||||
if (dev->mt76.cap.has_5ghz) {
|
||||
if (dev->mphy.cap.has_5ghz) {
|
||||
coex3 |= BIT(3) | BIT(4);
|
||||
} else {
|
||||
wlan |= BIT(6);
|
||||
|
||||
Reference in New Issue
Block a user