summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorINSUN PYO <insun.pyo@samsung.com>2020-02-05 06:12:43 (GMT)
committerHyotaek Shim <hyotaek.shim@samsung.com>2020-02-05 06:12:43 (GMT)
commit2db025193943590e40382eb81703bbe286c32a89 (patch)
tree0fd298291b7cf036c4d091ab387245fe4e724caf
parenta12b77f1b7f906004caeb163c0968fb69e6a1b5c (diff)
downloadlibdevice-node-2db025193943590e40382eb81703bbe286c32a89.zip
libdevice-node-2db025193943590e40382eb81703bbe286c32a89.tar.gz
libdevice-node-2db025193943590e40382eb81703bbe286c32a89.tar.bz2
device-manager-plugin-sc7730 use ARRAY_SIZE as symbol instead of simple define. E/DEVICE_NODE( 350): common.c: hw_get_info(63) > fail to open module : /usr/lib/hw/external_connection.so: undefined symbol: ARRAY_SIZE E/DEVICED ( 350): extcon.c: extcon_probe(411) > There is no extcon class. E/DEVICED ( 350): devices.c: devices_init(118) > [extcon] Failed to probe. E/DEVICE_NODE( 350): common.c: hw_get_info(63) > fail to open module : /usr/lib/hw/led.so: undefined symbol: ARRAY_SIZE E/DEVICED ( 350): rgb.c: rgb_probe(387) > There is no LED HAL. E/DEVICED ( 350): devices.c: devices_init(118) > [rgbled] Failed to probe. E/DEVICE_NODE( 350): common.c: hw_get_info(63) > fail to open module : /usr/lib/hw/led.so: undefined symbol: ARRAY_SIZE E/DEVICED ( 350): torch.c: led_service_load(160) > Failed to load led shared library: -2 E/DEVICED ( 350): devices.c: devices_init(118) > [torchled] Failed to probe. E/DEVICE_NODE( 350): common.c: hw_get_info(63) > fail to open module : /usr/lib/hw/led.so: undefined symbol: ARRAY_SIZE Change-Id: I621dbca201a36681e23ece03fbb9d7c12eb5d127 (cherry picked from commit 9a038fa3dfa3b8aea9606a7b9586d8f6103ecdc5)
-rw-r--r--hw/shared.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/shared.h b/hw/shared.h
index 990c55f..a0687e2 100644
--- a/hw/shared.h
+++ b/hw/shared.h
@@ -40,6 +40,8 @@
#define _E(x, ...) do { } while (0)
#endif
+#define ARRAY_SIZE(name) (sizeof(name)/sizeof(name[0]))
+
#define SHARED_H_BUF_MAX 255
static inline int sys_read_buf(char *file, char *buf, int len)