Browse Source

qcacmn: Add BSS peer for P2P client mode

Set bss peer for both STA and P2P client mode.

Change-Id: Ic25e48930511ff6c6e3af8c9bbdb9425ec654f04
CRs-Fixed: 2332938
Bala Venkatesh 6 years ago
parent
commit
b966910cb6
1 changed files with 4 additions and 3 deletions
  1. 4 3
      umac/cmn_services/obj_mgr/src/wlan_objmgr_vdev_obj.c

+ 4 - 3
umac/cmn_services/obj_mgr/src/wlan_objmgr_vdev_obj.c

@@ -694,9 +694,10 @@ QDF_STATUS wlan_objmgr_vdev_peer_attach(struct wlan_objmgr_vdev *vdev,
 			wlan_vdev_set_bsspeer(vdev, peer);
 	}
 	/* set BSS peer for sta */
-	if ((wlan_vdev_mlme_get_opmode(vdev) == QDF_STA_MODE) &&
-		((wlan_peer_get_peer_type(peer) == WLAN_PEER_AP) ||
-		 (wlan_peer_get_peer_type(peer) == WLAN_PEER_P2P_GO)))
+	if ((wlan_vdev_mlme_get_opmode(vdev) == QDF_STA_MODE ||
+	     wlan_vdev_mlme_get_opmode(vdev) == QDF_P2P_CLIENT_MODE) &&
+	    (wlan_peer_get_peer_type(peer) == WLAN_PEER_AP ||
+	     wlan_peer_get_peer_type(peer) == WLAN_PEER_P2P_GO))
 		wlan_vdev_set_bsspeer(vdev, peer);
 
 	/* Increment vdev ref count to make sure it won't be destroyed before */