* [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
@ 2023-06-05 7:34 Paul Fertser
2023-06-06 9:03 ` Simon Horman
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Paul Fertser @ 2023-06-05 7:34 UTC (permalink / raw)
To: linux-wireless
Cc: Felix Fietkau, Lorenzo Bianconi, Ryder Lee, Shayne Chen,
Sean Wang, Kalle Valo, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, Paul Fertser, netdev, linux-kernel,
linux-arm-kernel, linux-mediatek, Rani Hod, stable
On DBDC devices the first (internal) phy is only capable of using
2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
so avoid the false advertising.
Reported-by: Rani Hod <rani.hod@gmail.com>
Closes: https://github.com/openwrt/openwrt/pull/12361
Fixes: 7660a1bd0c22 ("mt76: mt7615: register ext_phy if DBDC is detected")
Cc: stable@vger.kernel.org
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
---
drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c b/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c
index 68e88224b8b1..ccedea7e8a50 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c
@@ -128,12 +128,12 @@ mt7615_eeprom_parse_hw_band_cap(struct mt7615_dev *dev)
case MT_EE_5GHZ:
dev->mphy.cap.has_5ghz = true;
break;
- case MT_EE_2GHZ:
- dev->mphy.cap.has_2ghz = true;
- break;
case MT_EE_DBDC:
dev->dbdc_support = true;
fallthrough;
+ case MT_EE_2GHZ:
+ dev->mphy.cap.has_2ghz = true;
+ break;
default:
dev->mphy.cap.has_2ghz = true;
dev->mphy.cap.has_5ghz = true;
--
2.34.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-06-05 7:34 [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC) Paul Fertser
@ 2023-06-06 9:03 ` Simon Horman
2023-06-06 9:12 ` Paul Fertser
2023-07-21 8:03 ` Felix Fietkau
2023-07-24 13:37 ` wifi: " Kalle Valo
2 siblings, 1 reply; 8+ messages in thread
From: Simon Horman @ 2023-06-06 9:03 UTC (permalink / raw)
To: Paul Fertser
Cc: linux-wireless, Felix Fietkau, Lorenzo Bianconi, Ryder Lee,
Shayne Chen, Sean Wang, Kalle Valo, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, netdev, linux-kernel,
linux-arm-kernel, linux-mediatek, Rani Hod, stable
On Mon, Jun 05, 2023 at 10:34:07AM +0300, Paul Fertser wrote:
> On DBDC devices the first (internal) phy is only capable of using
> 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
> so avoid the false advertising.
Hi Paul,
Can I clarify that the second object won't hit the logic change
below and thus be limited to 2GHz?
> Reported-by: Rani Hod <rani.hod@gmail.com>
> Closes: https://github.com/openwrt/openwrt/pull/12361
> Fixes: 7660a1bd0c22 ("mt76: mt7615: register ext_phy if DBDC is detected")
> Cc: stable@vger.kernel.org
> Signed-off-by: Paul Fertser <fercerpav@gmail.com>
> ---
> drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c b/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c
> index 68e88224b8b1..ccedea7e8a50 100644
> --- a/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c
> +++ b/drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c
> @@ -128,12 +128,12 @@ mt7615_eeprom_parse_hw_band_cap(struct mt7615_dev *dev)
> case MT_EE_5GHZ:
> dev->mphy.cap.has_5ghz = true;
> break;
> - case MT_EE_2GHZ:
> - dev->mphy.cap.has_2ghz = true;
> - break;
> case MT_EE_DBDC:
> dev->dbdc_support = true;
> fallthrough;
> + case MT_EE_2GHZ:
> + dev->mphy.cap.has_2ghz = true;
> + break;
> default:
> dev->mphy.cap.has_2ghz = true;
> dev->mphy.cap.has_5ghz = true;
> --
> 2.34.1
>
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-06-06 9:03 ` Simon Horman
@ 2023-06-06 9:12 ` Paul Fertser
2023-06-06 9:16 ` Simon Horman
0 siblings, 1 reply; 8+ messages in thread
From: Paul Fertser @ 2023-06-06 9:12 UTC (permalink / raw)
To: Simon Horman
Cc: linux-wireless, Felix Fietkau, Lorenzo Bianconi, Ryder Lee,
Shayne Chen, Sean Wang, Kalle Valo, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, netdev, linux-kernel,
linux-arm-kernel, linux-mediatek, Rani Hod, stable
Hi Simon,
On Tue, Jun 06, 2023 at 11:03:31AM +0200, Simon Horman wrote:
> On Mon, Jun 05, 2023 at 10:34:07AM +0300, Paul Fertser wrote:
> > On DBDC devices the first (internal) phy is only capable of using
> > 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
> > so avoid the false advertising.
>
> Can I clarify that the second object won't hit the logic change
> below and thus be limited to 2GHz?
The second object (external 5 GHz phy) doesn't have an EEPROM of its
own, and is created explicitly with just this band enabled:
https://elixir.bootlin.com/linux/latest/source/drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c#L104
https://elixir.bootlin.com/linux/latest/source/drivers/net/wireless/mediatek/mt76/mt7615/init.c#L573
So it won't hit the logic change and it will be limited to 5 GHz.
--
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:fercerpav@gmail.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-06-06 9:12 ` Paul Fertser
@ 2023-06-06 9:16 ` Simon Horman
0 siblings, 0 replies; 8+ messages in thread
From: Simon Horman @ 2023-06-06 9:16 UTC (permalink / raw)
To: Paul Fertser
Cc: linux-wireless, Felix Fietkau, Lorenzo Bianconi, Ryder Lee,
Shayne Chen, Sean Wang, Kalle Valo, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, netdev, linux-kernel,
linux-arm-kernel, linux-mediatek, Rani Hod, stable
On Tue, Jun 06, 2023 at 12:12:51PM +0300, Paul Fertser wrote:
> Hi Simon,
>
> On Tue, Jun 06, 2023 at 11:03:31AM +0200, Simon Horman wrote:
> > On Mon, Jun 05, 2023 at 10:34:07AM +0300, Paul Fertser wrote:
> > > On DBDC devices the first (internal) phy is only capable of using
> > > 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
> > > so avoid the false advertising.
> >
> > Can I clarify that the second object won't hit the logic change
> > below and thus be limited to 2GHz?
>
> The second object (external 5 GHz phy) doesn't have an EEPROM of its
> own, and is created explicitly with just this band enabled:
>
> https://elixir.bootlin.com/linux/latest/source/drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c#L104
> https://elixir.bootlin.com/linux/latest/source/drivers/net/wireless/mediatek/mt76/mt7615/init.c#L573
>
> So it won't hit the logic change and it will be limited to 5 GHz.
Thanks Paul,
in that case this patch looks good to me.
Reviewed-by: Simon Horman <simon.horman@corigine.com>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-06-05 7:34 [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC) Paul Fertser
2023-06-06 9:03 ` Simon Horman
@ 2023-07-21 8:03 ` Felix Fietkau
2023-07-21 14:37 ` Jakub Kicinski
2023-07-24 13:37 ` wifi: " Kalle Valo
2 siblings, 1 reply; 8+ messages in thread
From: Felix Fietkau @ 2023-07-21 8:03 UTC (permalink / raw)
To: Paul Fertser, linux-wireless
Cc: Lorenzo Bianconi, Ryder Lee, Shayne Chen, Sean Wang, Kalle Valo,
David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Matthias Brugger, AngeloGioacchino Del Regno, netdev,
linux-kernel, linux-arm-kernel, linux-mediatek, Rani Hod, stable
On 05.06.23 09:34, Paul Fertser wrote:
> On DBDC devices the first (internal) phy is only capable of using
> 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
> so avoid the false advertising.
>
> Reported-by: Rani Hod <rani.hod@gmail.com>
> Closes: https://github.com/openwrt/openwrt/pull/12361
> Fixes: 7660a1bd0c22 ("mt76: mt7615: register ext_phy if DBDC is detected")
> Cc: stable@vger.kernel.org
> Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Acked-by: Felix Fietkau <nbd@nbd.name>
Jakub, could you please pick this one up for 6.5?
Thanks,
- Felix
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-07-21 8:03 ` Felix Fietkau
@ 2023-07-21 14:37 ` Jakub Kicinski
2023-07-22 6:23 ` Kalle Valo
0 siblings, 1 reply; 8+ messages in thread
From: Jakub Kicinski @ 2023-07-21 14:37 UTC (permalink / raw)
To: Felix Fietkau
Cc: Paul Fertser, linux-wireless, Lorenzo Bianconi, Ryder Lee,
Shayne Chen, Sean Wang, Kalle Valo, David S. Miller,
Eric Dumazet, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, netdev, linux-kernel,
linux-arm-kernel, linux-mediatek, Rani Hod, stable
On Fri, 21 Jul 2023 10:03:49 +0200 Felix Fietkau wrote:
> On 05.06.23 09:34, Paul Fertser wrote:
> > On DBDC devices the first (internal) phy is only capable of using
> > 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
> > so avoid the false advertising.
> >
> > Reported-by: Rani Hod <rani.hod@gmail.com>
> > Closes: https://github.com/openwrt/openwrt/pull/12361
> > Fixes: 7660a1bd0c22 ("mt76: mt7615: register ext_phy if DBDC is detected")
> > Cc: stable@vger.kernel.org
> > Signed-off-by: Paul Fertser <fercerpav@gmail.com>
> Acked-by: Felix Fietkau <nbd@nbd.name>
>
> Jakub, could you please pick this one up for 6.5?
Kalle reported that he's back to wireless duties a few hours after you
posted so just to avoid any confusion - I'll leave this one to Kalle
unless told otherwise.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-07-21 14:37 ` Jakub Kicinski
@ 2023-07-22 6:23 ` Kalle Valo
0 siblings, 0 replies; 8+ messages in thread
From: Kalle Valo @ 2023-07-22 6:23 UTC (permalink / raw)
To: Jakub Kicinski
Cc: Felix Fietkau, Paul Fertser, linux-wireless, Lorenzo Bianconi,
Ryder Lee, Shayne Chen, Sean Wang, David S. Miller, Eric Dumazet,
Paolo Abeni, Matthias Brugger, AngeloGioacchino Del Regno,
netdev, linux-kernel, linux-arm-kernel, linux-mediatek, Rani Hod,
stable
Jakub Kicinski <kuba@kernel.org> writes:
> On Fri, 21 Jul 2023 10:03:49 +0200 Felix Fietkau wrote:
>> On 05.06.23 09:34, Paul Fertser wrote:
>> > On DBDC devices the first (internal) phy is only capable of using
>> > 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
>> > so avoid the false advertising.
>> >
>> > Reported-by: Rani Hod <rani.hod@gmail.com>
>> > Closes: https://github.com/openwrt/openwrt/pull/12361
>> > Fixes: 7660a1bd0c22 ("mt76: mt7615: register ext_phy if DBDC is detected")
>> > Cc: stable@vger.kernel.org
>> > Signed-off-by: Paul Fertser <fercerpav@gmail.com>
>> Acked-by: Felix Fietkau <nbd@nbd.name>
>>
>> Jakub, could you please pick this one up for 6.5?
>
> Kalle reported that he's back to wireless duties a few hours after you
> posted so just to avoid any confusion - I'll leave this one to Kalle
> unless told otherwise.
Yup, I'm back. I assigned this to me on patchwork and planning to queue
for v6.5.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: wifi: mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
2023-06-05 7:34 [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC) Paul Fertser
2023-06-06 9:03 ` Simon Horman
2023-07-21 8:03 ` Felix Fietkau
@ 2023-07-24 13:37 ` Kalle Valo
2 siblings, 0 replies; 8+ messages in thread
From: Kalle Valo @ 2023-07-24 13:37 UTC (permalink / raw)
To: Paul Fertser
Cc: linux-wireless, Felix Fietkau, Lorenzo Bianconi, Ryder Lee,
Shayne Chen, Sean Wang, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni, Matthias Brugger,
AngeloGioacchino Del Regno, Paul Fertser, netdev, linux-kernel,
linux-arm-kernel, linux-mediatek, Rani Hod, stable
Paul Fertser <fercerpav@gmail.com> wrote:
> On DBDC devices the first (internal) phy is only capable of using
> 2.4 GHz band, and the 5 GHz band is exposed via a separate phy object,
> so avoid the false advertising.
>
> Reported-by: Rani Hod <rani.hod@gmail.com>
> Closes: https://github.com/openwrt/openwrt/pull/12361
> Fixes: 7660a1bd0c22 ("mt76: mt7615: register ext_phy if DBDC is detected")
> Cc: stable@vger.kernel.org
> Signed-off-by: Paul Fertser <fercerpav@gmail.com>
> Reviewed-by: Simon Horman <simon.horman@corigine.com>
> Acked-by: Felix Fietkau <nbd@nbd.name>
Patch applied to wireless.git, thanks.
421033deb915 wifi: mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC)
--
https://patchwork.kernel.org/project/linux-wireless/patch/20230605073408.8699-1-fercerpav@gmail.com/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2023-07-24 13:37 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-05 7:34 [PATCH] mt76: mt7615: do not advertise 5 GHz on first phy of MT7615D (DBDC) Paul Fertser
2023-06-06 9:03 ` Simon Horman
2023-06-06 9:12 ` Paul Fertser
2023-06-06 9:16 ` Simon Horman
2023-07-21 8:03 ` Felix Fietkau
2023-07-21 14:37 ` Jakub Kicinski
2023-07-22 6:23 ` Kalle Valo
2023-07-24 13:37 ` wifi: " Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).