|
@@ -624,9 +624,9 @@ static int ath10k_monitor_vdev_create(struct ath10k *ar)
|
|
|
return -ENOMEM;
|
|
|
}
|
|
|
|
|
|
- bit = ffs(ar->free_vdev_map);
|
|
|
+ bit = __ffs64(ar->free_vdev_map);
|
|
|
|
|
|
- ar->monitor_vdev_id = bit - 1;
|
|
|
+ ar->monitor_vdev_id = bit;
|
|
|
|
|
|
ret = ath10k_wmi_vdev_create(ar, ar->monitor_vdev_id,
|
|
|
WMI_VDEV_TYPE_MONITOR,
|
|
@@ -637,7 +637,7 @@ static int ath10k_monitor_vdev_create(struct ath10k *ar)
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
|
- ar->free_vdev_map &= ~(1 << ar->monitor_vdev_id);
|
|
|
+ ar->free_vdev_map &= ~(1LL << ar->monitor_vdev_id);
|
|
|
ath10k_dbg(ar, ATH10K_DBG_MAC, "mac monitor vdev %d created\n",
|
|
|
ar->monitor_vdev_id);
|
|
|
|
|
@@ -657,7 +657,7 @@ static int ath10k_monitor_vdev_delete(struct ath10k *ar)
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
|
- ar->free_vdev_map |= 1 << ar->monitor_vdev_id;
|
|
|
+ ar->free_vdev_map |= 1LL << ar->monitor_vdev_id;
|
|
|
|
|
|
ath10k_dbg(ar, ATH10K_DBG_MAC, "mac monitor vdev %d deleted\n",
|
|
|
ar->monitor_vdev_id);
|
|
@@ -2791,9 +2791,12 @@ static int ath10k_add_interface(struct ieee80211_hw *hw,
|
|
|
ret = -EBUSY;
|
|
|
goto err;
|
|
|
}
|
|
|
- bit = ffs(ar->free_vdev_map);
|
|
|
+ bit = __ffs64(ar->free_vdev_map);
|
|
|
|
|
|
- arvif->vdev_id = bit - 1;
|
|
|
+ ath10k_dbg(ar, ATH10K_DBG_MAC, "mac create vdev %i map %llx\n",
|
|
|
+ bit, ar->free_vdev_map);
|
|
|
+
|
|
|
+ arvif->vdev_id = bit;
|
|
|
arvif->vdev_subtype = WMI_VDEV_SUBTYPE_NONE;
|
|
|
|
|
|
if (ar->p2p)
|
|
@@ -2865,7 +2868,7 @@ static int ath10k_add_interface(struct ieee80211_hw *hw,
|
|
|
goto err;
|
|
|
}
|
|
|
|
|
|
- ar->free_vdev_map &= ~(1 << arvif->vdev_id);
|
|
|
+ ar->free_vdev_map &= ~(1LL << arvif->vdev_id);
|
|
|
list_add(&arvif->list, &ar->arvifs);
|
|
|
|
|
|
vdev_param = ar->wmi.vdev_param->def_keyid;
|
|
@@ -2958,7 +2961,7 @@ err_peer_delete:
|
|
|
|
|
|
err_vdev_delete:
|
|
|
ath10k_wmi_vdev_delete(ar, arvif->vdev_id);
|
|
|
- ar->free_vdev_map |= 1 << arvif->vdev_id;
|
|
|
+ ar->free_vdev_map |= 1LL << arvif->vdev_id;
|
|
|
list_del(&arvif->list);
|
|
|
|
|
|
err:
|
|
@@ -2993,7 +2996,7 @@ static void ath10k_remove_interface(struct ieee80211_hw *hw,
|
|
|
ath10k_warn(ar, "failed to stop spectral for vdev %i: %d\n",
|
|
|
arvif->vdev_id, ret);
|
|
|
|
|
|
- ar->free_vdev_map |= 1 << arvif->vdev_id;
|
|
|
+ ar->free_vdev_map |= 1LL << arvif->vdev_id;
|
|
|
list_del(&arvif->list);
|
|
|
|
|
|
if (arvif->vdev_type == WMI_VDEV_TYPE_AP) {
|