Skip to contentSkip to conversation

mwl8k: Announcing AP_VLAN suport

PATCH In review Yogesh Ashok Powar 2 participants 3 messages Jan 25, 2013 – Jan 28, 2013 Networking drivers (wireless)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mwl8k: Announcing AP_VLAN suport

AP_VLAN support is needed in order to support wds_sta in the hostapd. This will allow us adding support for 4-address for AP and client mode

---
 drivers/net/wireless/mwl8k.c | 1 +
 1 file changed, 1 insertion(+)
drivers/net/wireless/mwl8k.c +1 -0
index ee5c7ea..8788157 100644
@@ -5920,6 +5920,7 @@ static int mwl8k_firmware_load_success(struct mwl8k_priv *priv)
 
 	if (priv->ap_macids_supported || priv->device_info->fw_image_ap) {
 		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP);
+		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP_VLAN);
 		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_STATION);
 		hw->wiphy->iface_combinations = &ap_if_comb;
 		hw->wiphy->n_iface_combinations = 1;
Signature · 1 line
1.8.0.3
maintainer
#1 lore raw
Quoted 16 lines · Yogesh Ashok Powar

AP_VLAN support is needed in order to support wds_sta in the hostapd. This will allow us adding support for 4-address for AP and client mode

---
 drivers/net/wireless/mwl8k.c | 1 +
 1 file changed, 1 insertion(+)
drivers/net/wireless/mwl8k.c +0 -0
index ee5c7ea..8788157 100644

drivers/net/wireless/mwl8k.c static int mwl8k_firmware_load_success(struct mwl8k_priv *priv) · line 5924

Quoted 5 lines
drivers/net/wireless/mwl8k.c +1 -0
@@ -5920,6 +5920,7 @@ static int mwl8k_firmware_load_success(struct mwl8k_priv *priv)
 
 	if (priv->ap_macids_supported || priv->device_info->fw_image_ap) {
 		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP);
+		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP_VLAN);
 		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_STATION);

Hmm, why is this needed? mac80211 should add it:

        /* if low-level driver supports AP, we also support VLAN */
        if (local->hw.wiphy->interface_modes & BIT(NL80211_IFTYPE_AP)) {
                hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP_VLAN);
                hw->wiphy->software_iftypes |= BIT(NL80211_IFTYPE_AP_VLAN);
        }

Is this run too late, i.e. after registering hw? If so, that's a bug.

johannes

#2 lore raw
Quoted 7 lines

drivers/net/wireless/mwl8k.c static int mwl8k_firmware_load_success(struct mwl8k_priv *priv) · line 5924

Quoted 4 lines
drivers/net/wireless/mwl8k.c +1 -0
 	if (priv->ap_macids_supported || priv->device_info->fw_image_ap) {
 		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP);
+		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP_VLAN);
 		hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_STATION);

Hmm, why is this needed? mac80211 should add it:

Quoted 7 lines
        /* if low-level driver supports AP, we also support VLAN */
        if (local->hw.wiphy->interface_modes & BIT(NL80211_IFTYPE_AP)) {
                hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_AP_VLAN);
                hw->wiphy->software_iftypes |= BIT(NL80211_IFTYPE_AP_VLAN);
        }

Is this run too late, i.e. after registering hw? If so, that's a bug.

Hi Johannes,

We agree with you. There is no need to explicitly set
NL80211_IFTYPE_AP_VLAN support for AP driver. This patch is redundant.

@John: Please ignore this patch.

Thanks
Yogesh

Quoted 3 lines

johannes