Lines Matching defs:vif
242 static void wil_disconnect_cid_complete(struct wil6210_vif *vif, int cid,
247 struct wil6210_priv *wil = vif_to_wil(vif);
248 struct net_device *ndev = vif_to_ndev(vif);
249 struct wireless_dev *wdev = vif_to_wdev(vif);
259 if (vif->mid != sta->mid) {
261 vif->mid);
301 static void _wil6210_disconnect_complete(struct wil6210_vif *vif,
304 struct wil6210_priv *wil = vif_to_wil(vif);
309 ndev = vif_to_ndev(vif);
310 wdev = vif_to_wdev(vif);
328 cid = wil_find_cid(wil, vif->mid, bssid);
333 wil_disconnect_cid_complete(vif, cid, reason_code);
337 wil_disconnect_cid_complete(vif, cid, reason_code);
344 wil_bcast_fini(vif);
345 wil_update_net_queues_bh(wil, vif, NULL, true);
350 if (test_and_clear_bit(wil_vif_fwconnected, vif->status)) {
354 vif->locally_generated_disc,
356 vif->locally_generated_disc = false;
357 } else if (test_bit(wil_vif_fwconnecting, vif->status)) {
361 vif->bss = NULL;
363 clear_bit(wil_vif_fwconnecting, vif->status);
364 clear_bit(wil_vif_ft_roam, vif->status);
365 vif->ptk_rekey_state = WIL_REKEY_IDLE;
370 if (!wil_vif_is_connected(wil, vif->mid)) {
371 wil_update_net_queues_bh(wil, vif, NULL, true);
373 vif->status))
376 wil_update_net_queues_bh(wil, vif, NULL, false);
384 static int wil_disconnect_cid(struct wil6210_vif *vif, int cid,
387 struct wil6210_priv *wil = vif_to_wil(vif);
388 struct wireless_dev *wdev = vif_to_wdev(vif);
399 if (vif->mid != sta->mid) {
400 wil_err(wil, "STA MID mismatch with VIF MID(%d)\n", vif->mid);
411 return wmi_disconnect_sta(vif, sta->addr, reason_code, del_sta);
414 static void _wil6210_disconnect(struct wil6210_vif *vif, const u8 *bssid,
421 if (unlikely(!vif))
424 wil = vif_to_wil(vif);
425 ndev = vif_to_ndev(vif);
442 cid = wil_find_cid(wil, vif->mid, bssid);
446 wil_disconnect_cid(vif, cid, reason_code);
450 wil_disconnect_cid(vif, cid, reason_code);
457 _wil6210_disconnect_complete(vif, bssid, reason_code);
462 struct wil6210_vif *vif = container_of(work,
464 struct wil6210_priv *wil = vif_to_wil(vif);
465 struct net_device *ndev = vif_to_ndev(vif);
472 if (test_bit(wil_vif_fwconnected, vif->status))
476 if (!test_bit(wil_vif_fwconnecting, vif->status))
482 rc = wmi_call(wil, WMI_DISCONNECT_CMDID, vif->mid, NULL, 0,
490 wil_update_net_queues_bh(wil, vif, NULL, true);
494 clear_bit(wil_vif_fwconnecting, vif->status);
613 int wil_ring_init_tx(struct wil6210_vif *vif, int cid)
615 struct wil6210_priv *wil = vif_to_wil(vif);
629 cid, vif->mid, ringid);
631 rc = wil->txrx_ops.ring_init_tx(vif, ringid, 1 << tx_ring_order,
635 cid, vif->mid, ringid);
641 int wil_bcast_init(struct wil6210_vif *vif)
643 struct wil6210_priv *wil = vif_to_wil(vif);
644 int ri = vif->bcast_ring, rc;
653 vif->bcast_ring = ri;
654 rc = wil->txrx_ops.ring_init_bcast(vif, ri, 1 << bcast_ring_order);
656 vif->bcast_ring = -1;
661 void wil_bcast_fini(struct wil6210_vif *vif)
663 struct wil6210_priv *wil = vif_to_wil(vif);
664 int ri = vif->bcast_ring;
669 vif->bcast_ring = -1;
676 struct wil6210_vif *vif;
679 vif = wil->vifs[i];
680 if (vif)
681 wil_bcast_fini(vif);
785 * @vif: virtual interface context
794 void wil6210_disconnect(struct wil6210_vif *vif, const u8 *bssid,
797 struct wil6210_priv *wil = vif_to_wil(vif);
801 del_timer_sync(&vif->connect_timer);
802 _wil6210_disconnect(vif, bssid, reason_code);
807 * @vif: virtual interface context
814 void wil6210_disconnect_complete(struct wil6210_vif *vif, const u8 *bssid,
817 struct wil6210_priv *wil = vif_to_wil(vif);
821 del_timer_sync(&vif->connect_timer);
822 _wil6210_disconnect_complete(vif, bssid, reason_code);
1454 void wil_abort_scan(struct wil6210_vif *vif, bool sync)
1456 struct wil6210_priv *wil = vif_to_wil(vif);
1464 if (!vif->scan_request)
1467 wil_dbg_misc(wil, "Abort scan_request 0x%p\n", vif->scan_request);
1468 del_timer_sync(&vif->scan_timer);
1470 rc = wmi_abort_scan(vif);
1472 wait_event_interruptible_timeout(wil->wq, !vif->scan_request,
1477 if (vif->scan_request) {
1478 cfg80211_scan_done(vif->scan_request, &info);
1479 vif->scan_request = NULL;
1490 struct wil6210_vif *vif = wil->vifs[i];
1492 if (vif)
1493 wil_abort_scan(vif, sync);
1548 struct wil6210_vif *vif;
1554 vif = wil->vifs[i];
1555 if (!vif)
1557 vif->ap_isolate = 0;
1558 if (vif->mid) {
1559 ndev = vif_to_ndev(vif);
1560 wdev = vif_to_wdev(vif);
1561 rc = wmi_port_allocate(wil, vif->mid, ndev->dev_addr,
1598 struct wil6210_vif *vif;
1644 vif = wil->vifs[i];
1645 if (vif) {
1646 cancel_work_sync(&vif->disconnect_worker);
1647 wil6210_disconnect(vif, NULL,
1649 vif->ptk_rekey_state = WIL_REKEY_IDLE;