diff mbox series

[1/2] mac80211: pass phy name to hostapd_set_bss_options

Message ID 20201019195628.31747-1-mail@david-bauer.net
State Accepted
Delegated to: David Bauer
Headers show
Series [1/2] mac80211: pass phy name to hostapd_set_bss_options | expand

Commit Message

David Bauer Oct. 19, 2020, 7:56 p.m. UTC
hostapd_set_bss_options expects the PHY as second and the VIF as third
argument. However, only the VIF was passed as second argument without a
third argument at all.

This was never a problem, as both PHY and VIF were never accessed.
However, with FTM support the PHY is needed to determine the HW support
when configuring the BSS.

Signed-off-by: David Bauer <mail@david-bauer.net>
---
 package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

e9hack Oct. 19, 2020, 9:08 p.m. UTC | #1
Am 19.10.2020 um 21:56 schrieb David Bauer:
> hostapd_set_bss_options expects the PHY as second and the VIF as third
> argument. However, only the VIF was passed as second argument without a
> third argument at all.
> 
> This was never a problem, as both PHY and VIF were never accessed.
> However, with FTM support the PHY is needed to determine the HW support
> when configuring the BSS.
> 
> Signed-off-by: David Bauer <mail@david-bauer.net>
> ---
>  package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
> index 42144375b4..11ea700b98 100644
> --- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
> +++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
> @@ -372,7 +372,7 @@ mac80211_hostapd_setup_bss() {
>  	hostapd_cfg=
>  	append hostapd_cfg "$type=$ifname" "$N"
>  
> -	hostapd_set_bss_options hostapd_cfg "$vif" || return 1
> +	hostapd_set_bss_options hostapd_cfg "$phy" "$vif" || return 1
>  	json_get_vars wds wds_bridge dtim_period max_listen_int start_disabled
>  
>  	set_default wds 0
> 

Interesting, I ask for a similar patch 3 years ago and didn't get any response. For some reason, my mail isn't available in the mail archive but in patchwork:

https://patchwork.ozlabs.org/project/lede/patch/acdea515-640a-62de-afa6-45bb57654da2@gmail.com/

Regards,
Hartmut
diff mbox series

Patch

diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
index 42144375b4..11ea700b98 100644
--- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
+++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
@@ -372,7 +372,7 @@  mac80211_hostapd_setup_bss() {
 	hostapd_cfg=
 	append hostapd_cfg "$type=$ifname" "$N"
 
-	hostapd_set_bss_options hostapd_cfg "$vif" || return 1
+	hostapd_set_bss_options hostapd_cfg "$phy" "$vif" || return 1
 	json_get_vars wds wds_bridge dtim_period max_listen_int start_disabled
 
 	set_default wds 0