new file mode 100644
@@ -0,0 +1,32 @@
+// SPDX-License-Identifier: MIT
+/* Copyright(c) 2019-2021, Celeno Communications Ltd. */
+
+#include "env_det.h"
+#include "hw.h"
+
+void cl_env_det_set_type(struct cl_hw *cl_hw, enum cl_env_type type)
+{
+ cl_dbg_info(cl_hw, "Changing env state from:%u to %u\n",
+ cl_hw->env_db.type, type);
+ cl_hw->env_db.type = type;
+}
+
+bool cl_env_det_is_clean(struct cl_hw *cl_hw)
+{
+ return cl_hw->env_db.type == CL_ENV_TYPE_CLEAN;
+}
+
+bool cl_env_det_is_average(struct cl_hw *cl_hw)
+{
+ return cl_hw->env_db.type == CL_ENV_TYPE_AVERAGE;
+}
+
+bool cl_env_det_is_noisy(struct cl_hw *cl_hw)
+{
+ return cl_hw->env_db.type == CL_ENV_TYPE_NOISY;
+}
+
+bool cl_env_det_is_very_noisy(struct cl_hw *cl_hw)
+{
+ return cl_hw->env_db.type == CL_ENV_TYPE_VERY_NOISY;
+}