Ver código fonte

qcacmn: Add domain checks for precac and rcac

Write two new functions to check if preCAC and RCAC are supported in the
current DFS domain.

Currently, the preCAC is supported in the following DFS domains:
1. ETSI Domain

Currently, the RCAC is supported in the following DFS domains:
1. FCC Domain
2. MKK Domain
3. MKKN Domain

Change-Id: I2996e4d5b26e1a57ebb00e415fa41108af997b21
CRs-Fixed: 3005416
Vignesh U 3 anos atrás
pai
commit
d746469888
1 arquivos alterados com 40 adições e 0 exclusões
  1. 40 0
      umac/dfs/core/src/dfs_zero_cac.h

+ 40 - 0
umac/dfs/core/src/dfs_zero_cac.h

@@ -657,6 +657,46 @@ static inline bool dfs_is_agile_precac_enabled(struct wlan_dfs *dfs)
 }
 #endif
 
+/**
+ * dfs_is_precac_domain() - Check if current DFS domain supports preCAC.
+ * @dfs: Pointer to the wlan_dfs object.
+ *
+ * Return: True if current DFS domain supports preCAC, else false.
+ *
+ * preCAC is currently supported in,
+ * 1. ETSI domain.
+ *
+ */
+#if defined(QCA_SUPPORT_AGILE_DFS) || defined(ATH_SUPPORT_ZERO_CAC_DFS)
+bool dfs_is_precac_domain(struct wlan_dfs *dfs);
+#else
+static inline bool dfs_is_precac_domain(struct wlan_dfs *dfs)
+{
+	return false;
+}
+#endif
+
+/**
+ * dfs_is_rcac_domain() - Check if current DFS domain supports agile RCAC.
+ * @dfs: Pointer to the wlan_dfs object.
+ *
+ * Return: True if current DFS domain supports RCAC, else false.
+ *
+ * preCAC is currently supported in,
+ * 1. FCC domain.
+ * 2. MKK domain.
+ * 3. MKKN domain.
+ *
+ */
+#if defined(QCA_SUPPORT_ADFS_RCAC)
+bool dfs_is_rcac_domain(struct wlan_dfs *dfs);
+#else
+static inline bool dfs_is_rcac_domain(struct wlan_dfs *dfs)
+{
+	return false;
+}
+#endif
+
 #ifdef WLAN_DFS_PRECAC_AUTO_CHAN_SUPPORT
 /**
  * dfs_set_precac_intermediate_chan() - Set intermediate chan to be used while