Skip to contentSkip to conversation

brcmfmac: of: introduce new property to allow disable PNO

PATCH Superseded Hermes Zhang 3 participants 3 messages Apr 22, 2022 – Apr 24, 2022

Subsystems (3)

v2 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 brcmfmac: of: introduce new property to allow disable PNO

From: Hermes Zhang <[email protected]>

The PNO feature need to be disable for some scenario in different product. This commit introduce a new property to allow the product-specific toggling of this feature.

---

Notes:
Change property name to brcm,pno-disable

 drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c +4 -0
index 8623bde5eb70..121a195e4054 100644
@@ -11,6 +11,7 @@
 #include "core.h"
 #include "common.h"
 #include "of.h"
+#include "feature.h"
 
 static int brcmf_of_get_country_codes(struct device *dev,
 				      struct brcmf_mp_device *settings)
@@ -102,6 +103,9 @@ void brcmf_of_probe(struct device *dev, enum brcmf_bus_type bus_type,
 	if (bus_type != BRCMF_BUSTYPE_SDIO)
 		return;
 
+	if (of_find_property(np, "brcm,pno-disable", NULL))
+		settings->feature_disable |= BIT(BRCMF_FEAT_PNO);
+
 	if (of_property_read_u32(np, "brcm,drive-strength", &val) == 0)
 		sdio->drive_strength = val;
 
Signature · 1 line
2.30.2
#1 lore raw
Quoted 5 lines · Hermes Zhang

From: Hermes Zhang <[email protected]>

The PNO feature need to be disable for some scenario in different product. This commit introduce a new property to allow the product-specific toggling of this feature.

"some scenario"? That's not really helpful.

Quoted 22 lines

---

Notes:
Change property name to brcm,pno-disable

 drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c +1 -0
index 8623bde5eb70..121a195e4054 100644
@@ -11,6 +11,7 @@
 #include "core.h"
 #include "common.h"
 #include "of.h"
+#include "feature.h"
 
 static int brcmf_of_get_country_codes(struct device *dev,
 				      struct brcmf_mp_device *settings)

drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c void brcmf_of_probe(struct device *dev, enum brcmf_bus_type bus_type, · line 107

Quoted 5 lines
drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c +2 -0
@@ -102,6 +103,9 @@ void brcmf_of_probe(struct device *dev, enum brcmf_bus_type bus_type,
 	if (bus_type != BRCMF_BUSTYPE_SDIO)
 		return;
 
+	if (of_find_property(np, "brcm,pno-disable", NULL))
+		settings->feature_disable |= BIT(BRCMF_FEAT_PNO);

Is this DT property documented and acked by the Device Tree maintainers? AFAIK DT is not supposed to be used as a software configuration database.

Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/list/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
maintainer
#2 lore raw
Quoted 9 lines · Kalle Valo
Quoted 5 lines · Hermes Zhang

From: Hermes Zhang <[email protected]>

The PNO feature need to be disable for some scenario in different product. This commit introduce a new property to allow the product-specific toggling of this feature.

"some scenario"? That's not really helpful.

The firmware feature PNO is used to provide the scheduled scan functionality. User-space can choose whether or not to use scheduled scan. If the scheduled scan is not working I would rather see a bug report so it can be properly investigated.

Regards,
Arend