浏览代码

qcacmn: Add callback to notify if vdev is in mlo_sync_wait

Add vdev callback to notify once the vdev has entered into
MLO_SYNC_WAIT state.

Change-Id: I655bfa68d666807468cacf1a0a052ac6ddf0b8d6
CRs-Fixed: 3338519
Santosh Anbu 2 年之前
父节点
当前提交
53d2d231fc

+ 2 - 1
umac/mlme/include/wlan_vdev_mlme.h

@@ -770,7 +770,8 @@ struct vdev_mlme_ops {
 	QDF_STATUS (*mlme_vdev_sta_disconn_start)(
 				struct vdev_mlme_obj *vdev_mlme,
 				uint16_t event_data_len, void *event_data);
-
+	QDF_STATUS (*mlme_vdev_notify_mlo_sync_wait_entry)(
+				struct vdev_mlme_obj *vdev_mlme);
 };
 
 /**

+ 1 - 0
umac/mlme/vdev_mgr/core/src/vdev_mlme_sm.c

@@ -1658,6 +1658,7 @@ static void mlme_vdev_subst_mlo_sync_wait_entry(void *ctx)
 		QDF_BUG(0);
 
 	mlme_vdev_set_substate(vdev, WLAN_VDEV_SS_MLO_SYNC_WAIT);
+	mlme_vdev_notify_mlo_sync_wait_entry(vdev_mlme);
 }
 
 /**

+ 25 - 0
umac/mlme/vdev_mgr/core/src/vdev_mlme_sm.h

@@ -693,6 +693,25 @@ static inline void mlme_vdev_up_active_notify_mlo_mgr(
 	    wlan_vdev_mlme_is_mlo_vdev(vdev_mlme->vdev))
 		mlo_sta_up_active_notify(vdev_mlme->vdev);
 }
+
+/**
+ * mlme_vdev_notify_mlo_sync_wait_entry - Notifies mlo sync wait state
+ * @vdev_mlme_obj:  VDEV MLME comp object
+ *
+ * Return: NO_SUPPORT if the callback is not supported.
+ *         SUCCESS if notification is handled by caller
+ */
+static inline QDF_STATUS mlme_vdev_notify_mlo_sync_wait_entry(
+				struct vdev_mlme_obj *vdev_mlme)
+{
+	QDF_STATUS ret = QDF_STATUS_E_NOSUPPORT;
+
+	if (vdev_mlme->ops &&
+	    vdev_mlme->ops->mlme_vdev_notify_mlo_sync_wait_entry)
+		ret = vdev_mlme->ops->mlme_vdev_notify_mlo_sync_wait_entry(
+				vdev_mlme);
+	return ret;
+}
 #else
 static inline void mlme_vdev_up_notify_mlo_mgr(struct vdev_mlme_obj *vdev_mlme)
 {
@@ -712,6 +731,12 @@ static inline void mlme_vdev_up_active_notify_mlo_mgr(
 					struct vdev_mlme_obj *vdev_mlme)
 {
 }
+
+static inline QDF_STATUS mlme_vdev_notify_mlo_sync_wait_entry(
+				struct vdev_mlme_obj *vdev_mlme)
+{
+	return QDF_STATUS_SUCCESS;
+}
 #endif
 
 #ifdef VDEV_SM_LOCK_SUPPORT