halapi: sensor: Add support for HAL_MODULE_SENSOR v1.0 53/313153/2 accepted/tizen/unified/20240621.010415 accepted/tizen/unified/dev/20240701.073014 accepted/tizen/unified/toolchain/20240624.121202 accepted/tizen/unified/x/20240624.031844 accepted/tizen/unified/x/asan/20240625.091428
authorChanwoo Choi <cw00.choi@samsung.com>
Wed, 19 Jun 2024 10:27:54 +0000 (19:27 +0900)
committerChanwoo Choi <cw00.choi@samsung.com>
Wed, 19 Jun 2024 10:32:50 +0000 (19:32 +0900)
HAL_MODULE_SENSOR will support the multiple version of HAL interface.
So that v1.0 is first supported version of HAL_MODULE_SENSOR.
hal-sensor-interface-1.h contains the v1.0 HAL interface.

Change-Id: I3f93cb8d9399bb0e78c97cc2b9b8cd1b14b76c6d
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
include/hal-sensor-interface-1.h [new file with mode: 0644]
include/hal-sensor-interface.h

diff --git a/include/hal-sensor-interface-1.h b/include/hal-sensor-interface-1.h
new file mode 100644 (file)
index 0000000..f700964
--- /dev/null
@@ -0,0 +1,36 @@
+/*
+ * HAL (Hardware Abstract Layer) Common API
+ *
+ * Copyright (c) 2021 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __HAL_SENSOR_INTERFACE_1__
+#define __HAL_SENSOR_INTERFACE_1__
+
+#include <hal/hal-common-interface.h>
+#include "hal-sensor-types.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef struct _hal_backend_sensor_funcs {
+  int (*create)(sensor_device_t **devices);
+} hal_backend_sensor_funcs;
+
+#ifdef __cplusplus
+}
+#endif
+#endif /* __HAL_SENSOR_INTERFACE_1__ */
index 6a6b807f448784d777dd0b581f3ce077a57ed54a..d2e931e5cd086a4f85ddf4ca78ff3687e74961d8 100644 (file)
 #ifndef __HAL_SENSOR_INTERFACE__
 #define __HAL_SENSOR_INTERFACE__
 
-#include <hal/hal-common-interface.h>
-#include "hal-sensor-types.h"
+#include "hal-sensor-interface-1.h"
 
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef struct _hal_backend_sensor_funcs {
-  int (*create)(sensor_device_t **devices);
-} hal_backend_sensor_funcs;
-
-#ifdef __cplusplus
-}
-#endif
 #endif /* __HAL_SENSOR_INTERFACE__ */