log: change file name "peripheral_common.h" to "peripheral_log.h" 60/160960/1
authorSegwon <segwon.han@samsung.com>
Tue, 21 Nov 2017 01:46:52 +0000 (10:46 +0900)
committerSegwon <segwon.han@samsung.com>
Tue, 21 Nov 2017 01:46:52 +0000 (10:46 +0900)
Change-Id: I4cbf8be541b34d592b95c47d2a9a975935b65a95
Signed-off-by: Segwon <segwon.han@samsung.com>
17 files changed:
src/daemon/include/peripheral_common.h [deleted file]
src/daemon/include/peripheral_log.h [new file with mode: 0644]
src/daemon/peripheral_bus.c
src/daemon/peripheral_bus_board.c
src/daemon/peripheral_bus_gdbus_gpio.c
src/daemon/peripheral_bus_gdbus_i2c.c
src/daemon/peripheral_bus_gdbus_pwm.c
src/daemon/peripheral_bus_gdbus_spi.c
src/daemon/peripheral_bus_gdbus_uart.c
src/daemon/peripheral_bus_gpio.c
src/daemon/peripheral_bus_i2c.c
src/daemon/peripheral_bus_pwm.c
src/daemon/peripheral_bus_spi.c
src/daemon/peripheral_bus_uart.c
src/daemon/peripheral_bus_util.c
src/daemon/privilege_checker.c
src/interface/include/peripheral_interface_common.h

diff --git a/src/daemon/include/peripheral_common.h b/src/daemon/include/peripheral_common.h
deleted file mode 100644 (file)
index 9c3b8fe..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (c) 2016-2017 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 __PERIPHERAL_COMMON_H__
-#define __PERIPHERAL_COMMON_H__
-
-#include <unistd.h>
-#include <dlog.h>
-
-#undef LOG_TAG
-#define LOG_TAG "PERIPHERAL-BUS"
-
-#define _E(fmt, arg...) LOGE(fmt, ##arg)
-#define _D(fmt, arg...) LOGD(fmt, ##arg)
-#define _W(fmt, arg...) LOGW(fmt, ##arg)
-
-#define RET_IF(expr) \
-       do { \
-               if (expr) { \
-                       _E("(%s)", #expr); \
-                       return; \
-               } \
-       } while (0)
-#define RETV_IF(expr, val) \
-       do {\
-               if (expr) { \
-                       _E("(%s)", #expr); \
-                       return (val); \
-               } \
-       } while (0)
-#define RETM_IF(expr, fmt, arg...) \
-       do {\
-               if (expr) { \
-                       _E(fmt, ##arg); \
-                       return; \
-               } \
-       } while (0)
-#define RETVM_IF(expr, val, fmt, arg...) \
-       do {\
-               if (expr) { \
-                       _E(fmt, ##arg); \
-                       return (val); \
-               } \
-       } while (0)
-
-#endif /* __PERIPHERAL_COMMON_H__ */
diff --git a/src/daemon/include/peripheral_log.h b/src/daemon/include/peripheral_log.h
new file mode 100644 (file)
index 0000000..7198845
--- /dev/null
@@ -0,0 +1,58 @@
+/*
+ * Copyright (c) 2016-2017 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 __PERIPHERAL_LOG_H__
+#define __PERIPHERAL_LOG_H__
+
+#include <unistd.h>
+#include <dlog.h>
+
+#undef LOG_TAG
+#define LOG_TAG "PERIPHERAL-BUS"
+
+#define _E(fmt, arg...) LOGE(fmt, ##arg)
+#define _D(fmt, arg...) LOGD(fmt, ##arg)
+#define _W(fmt, arg...) LOGW(fmt, ##arg)
+
+#define RET_IF(expr) \
+       do { \
+               if (expr) { \
+                       _E("(%s)", #expr); \
+                       return; \
+               } \
+       } while (0)
+#define RETV_IF(expr, val) \
+       do {\
+               if (expr) { \
+                       _E("(%s)", #expr); \
+                       return (val); \
+               } \
+       } while (0)
+#define RETM_IF(expr, fmt, arg...) \
+       do {\
+               if (expr) { \
+                       _E(fmt, ##arg); \
+                       return; \
+               } \
+       } while (0)
+#define RETVM_IF(expr, val, fmt, arg...) \
+       do {\
+               if (expr) { \
+                       _E(fmt, ##arg); \
+                       return (val); \
+               } \
+       } while (0)
+
+#endif /* __PERIPHERAL_COMMON_H__ */
index 6c18e58e583776f2b94052001bca54a68cf59f3c..7f6643467e23cdb2e36e1d28b79de84938e584e3 100644 (file)
@@ -24,7 +24,7 @@
 
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_gdbus_gpio.h"
 #include "peripheral_bus_gdbus_i2c.h"
 #include "peripheral_bus_gdbus_pwm.h"
index b2abbc7b2373f379abe095008b4d362ada17ffc8..48e2a0d98df8b3e9d53cdb864e2bf9cf8ad974f1 100644 (file)
@@ -24,7 +24,7 @@
 #include <peripheral_io.h>
 
 #include "peripheral_bus_board.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 
 #define STR_BUF_MAX 255
 
index b45115b032aef127d75666b0545a0eb7e738cbc6..b864c1d1b35fc4bc53b4b44257cb57d173511740 100644 (file)
@@ -20,7 +20,7 @@
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
 #include "peripheral_bus_gpio.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 #include "peripheral_bus_gdbus_gpio.h"
 
index 8a55bd5ea329d20a5a6066eadbab3d465fe3ffa1..6e0bfbb4e854ce9c1a70e6e4a1540ad50f5b419a 100644 (file)
@@ -19,7 +19,7 @@
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
 #include "peripheral_bus_i2c.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 #include "peripheral_bus_gdbus_i2c.h"
 
index 9560829579084aa329d592029acb9c1deecc09ac..47ead35ab7d3bba4ca6a0557026e8eca39cc7ce5 100644 (file)
@@ -19,7 +19,7 @@
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
 #include "peripheral_bus_pwm.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 #include "peripheral_bus_gdbus_pwm.h"
 
index 11eb0e68df7b92a90380d44ff51459e3a71d8a15..f609690a699ae599e7cd7ff1d38a849d20aacc7a 100644 (file)
@@ -19,7 +19,7 @@
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
 #include "peripheral_bus_spi.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 #include "peripheral_bus_gdbus_spi.h"
 
index 811d2eb1068fe00848dee13f2456d436cc16e689..3aa3ea2f4c382f6d388f1188bab40f37c6ff1a66 100644 (file)
@@ -19,7 +19,7 @@
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
 #include "peripheral_bus_uart.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 #include "peripheral_bus_gdbus_uart.h"
 
index 057cac65959573047d613717af1b8005211a24c9..6ac8d20bff79f34392917918d4004d93d054bd66 100644 (file)
@@ -26,7 +26,7 @@
 #include "peripheral_interface_gpio.h"
 #include "peripheral_bus.h"
 #include "peripheral_bus_gdbus_gpio.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 
 static bool peripheral_bus_gpio_is_available(int pin, peripheral_bus_s *pb_data)
index e0edbd5ea7120fe29a66c065e2b35013b5dd7875..88f8156a42ecf45d0f273736f41bdaf54e09a0f3 100644 (file)
@@ -22,7 +22,7 @@
 
 #include "peripheral_interface_i2c.h"
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 
 #define INITIAL_BUFFER_SIZE 128
index 6bf13dd4dd29602f334bdc1d42a73e243ffe25f5..a9c657c5e99df415b04902565c9d662a422d11d0 100644 (file)
@@ -22,7 +22,7 @@
 
 #include "peripheral_interface_pwm.h"
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 
 static bool peripheral_bus_pwm_is_available(int chip, int pin, peripheral_bus_s *pb_data)
index f982c2af9572d20146c4dde88f8a42be97cf1b48..e1d7f072f3dbe1a2a226f1e6857a97ddaaf6e18c 100644 (file)
@@ -22,7 +22,7 @@
 
 #include "peripheral_interface_spi.h"
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 
 static bool __peripheral_bus_spi_is_available(int bus, int cs, peripheral_bus_s *pb_data)
index 1ca35e7956c42c63e30869ec818f2ca833643490..a73007adab092c795eb11d9c22a6b878b056204a 100644 (file)
@@ -23,7 +23,7 @@
 #include "peripheral_interface_uart.h"
 #include "peripheral_io_gdbus.h"
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 #include "peripheral_bus_util.h"
 
 #define INITIAL_BUFFER_SIZE 128
index 8204885f8181c547c5ae78bbbf037e9648dc901e..eb270241759b79d6dc72e779100e1b92705b9dd9 100644 (file)
@@ -24,7 +24,7 @@
 #include <cynara-session.h>
 
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 
 #include "privilege_checker.h"
 
index 20c3760e330f53a3acc84445c40acec62f0053c7..e35298d0ad5224f3d0d2d884951e65685c59c520 100644 (file)
@@ -27,7 +27,7 @@
 #include <cynara-session.h>
 
 #include "peripheral_bus.h"
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 
 #define CACHE_SIZE  100
 
index e51f611ba6d38b30af798fab0c485fb8a5442719..d411ae703f54e0b1ebe88a3bc5f13515bc8f6715 100644 (file)
@@ -23,7 +23,7 @@
 #include <fcntl.h>
 #include <peripheral_io.h>
 
-#include "peripheral_common.h"
+#include "peripheral_log.h"
 
 #define MAX_ERR_LEN 255
 #define MAX_BUF_LEN 64