halapi: Add new get_backend and put_backend with specific library name 98/254798/6 submit/tizen/20210316.010905
authorChanwoo Choi <cw00.choi@samsung.com>
Tue, 9 Mar 2021 05:01:59 +0000 (14:01 +0900)
committerChanwoo Choi <cw00.choi@samsung.com>
Mon, 15 Mar 2021 02:41:59 +0000 (11:41 +0900)
commit714866a63f2349895f7ceab173a08df0789ca530
treeb7c548780c077af113f84af23d1aa6ef8695a784
parentf8c7d65a404d22e0020bb5f05210ef15dcd6ff49
halapi: Add new get_backend and put_backend with specific library name

Basically, hal_common_get_backend has used the promised libray name
for HAL backend like 'libhal-backend-[moodule name].so'. But, there are
some requirements that need to select the one HAL backend among the
multiple HAL backends on same device according to the role of use.

So that add the following two functions with new library_name argument.
- int hal_common_get_backend_with_library_name(enum hal_module module,
void **data, const char *library_name);
- int hal_common_put_backend_with_library_name(enum hal_module module,
void *data, const char *library_name);

[Constraints of library name]
This library_name argument must keep the naming rule as following:
-  'libhal-backend-[moodule name]-[extented name].so

Change-Id: Ia6c69597a718f5a4ae9de2f879f7c4337874b1ee
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
include/hal-common.h
src/common.h
src/hal-api-common.c
src/hal-api-conf.c
src/hal-api-conf.h
tests/unittest/test_hal.cc