summaryrefslogtreecommitdiffstats
path: root/systemservice/resource_manager/client
diff options
context:
space:
mode:
Diffstat (limited to 'systemservice/resource_manager/client')
-rwxr-xr-xsystemservice/resource_manager/client/Makefile58
-rwxr-xr-xsystemservice/resource_manager/client/RESMGR.api12
-rwxr-xr-xsystemservice/resource_manager/client/include/resmgr_api_resourcemanagerlog.h78
-rwxr-xr-xsystemservice/resource_manager/client/libresm.ver28
-rwxr-xr-xsystemservice/resource_manager/client/src/#resmgr_api_lib.c#142
-rwxr-xr-xsystemservice/resource_manager/client/src/resmgr_api_lib.c142
6 files changed, 0 insertions, 460 deletions
diff --git a/systemservice/resource_manager/client/Makefile b/systemservice/resource_manager/client/Makefile
deleted file mode 100755
index a2bde46..0000000
--- a/systemservice/resource_manager/client/Makefile
+++ /dev/null
@@ -1,58 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# 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.
-#
-
-######### add source path #############
-VPATH += ./
-VPATH += ./src
-VPATH += ./include
-VPATH += ../server/include
-VPATH += ../server/include/system_service
-
-######### install headers(*.h) #############
-INST_HEADERS += resm.h
-INST_HEADERS += resm_type.h
-INST_HEADERS += resource_manager.h
-
-######### installed program #############
-
-
-######### installed library(*.a) #############
-INST_LIBS =
-
-######### installed shared library(*.so) #############
-INST_SHLIBS = libresm
-RPC_API := RESMGR
-
-######### compiled sources #############
-libresm_SRCS += resmgr_api_stub.c
-libresm_SRCS += resmgr_api_lib.c
-
-######### add include path #############
-CPPFLAGS += -I./
-CPPFLAGS += -I./include
-CPPFLAGS += -I../server/include
-
-######## add compile option ########
-
-######### add library path #############
-LDFLAGS += -Wl,--no-as-needed
-
-######### linked library (dynamic) #############
-LDLIBS += -lrpc
-LDLIBS += -Wl,-Bdynamic -lev
-LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
-
-include ../../system_service.mk
diff --git a/systemservice/resource_manager/client/RESMGR.api b/systemservice/resource_manager/client/RESMGR.api
deleted file mode 100755
index 7bd9734..0000000
--- a/systemservice/resource_manager/client/RESMGR.api
+++ /dev/null
@@ -1,12 +0,0 @@
-/*
- * Resource Manager API
- */
-
-INCLUDE <system_service/resm.h>
-
-RPC_Result RESM_ReqEvent(uint32_t ssnld, const RESM_REQ_EVENT_t* p_reqEvent);
-RPC_Result RESM_GetStatus(uint32_t ssnld, RESM_STATUS_t* p_status);
-RPC_Result RESM_SV_Open(const RESM_RSV_t* p_prim, uint32_t* p_ssnld);
-RPC_Result RESM_SV_Close(uint32_t ssnld);
-RPC_Result RESM_SV_ChkSsnId(uint32_t ssnld);
-
diff --git a/systemservice/resource_manager/client/include/resmgr_api_resourcemanagerlog.h b/systemservice/resource_manager/client/include/resmgr_api_resourcemanagerlog.h
deleted file mode 100755
index b9d66fa..0000000
--- a/systemservice/resource_manager/client/include/resmgr_api_resourcemanagerlog.h
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * 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 _resmgr_api_resourcemanagerlog_h_ // NOLINT
-#define _resmgr_api_resourcemanagerlog_h_
-
-#include <native_service/ns_logger_if.h>
-
-#define ZONE_INIT ZONEMASK(10) // LIB common definition
-#define ZONE_FUNC ZONEMASK(11) // LIB common definition
-#define ZONE_MEM ZONEMASK(12) // LIB common definition
-#define ZONE_13 ZONEMASK(13)
-#define ZONE_14 ZONEMASK(14)
-#define ZONE_15 ZONEMASK(15)
-#define ZONE_16 ZONEMASK(16)
-#define ZONE_17 ZONEMASK(17)
-#define ZONE_18 ZONEMASK(18)
-#define ZONE_19 ZONEMASK(19)
-#define ZONE_20 ZONEMASK(20)
-#define ZONE_21 ZONEMASK(21)
-#define ZONE_22 ZONEMASK(22)
-#define ZONE_23 ZONEMASK(23)
-#define ZONE_24 ZONEMASK(24)
-#define ZONE_25 ZONEMASK(25)
-#define ZONE_26 ZONEMASK(26)
-#define ZONE_27 ZONEMASK(27)
-#define ZONE_28 ZONEMASK(28)
-#define ZONE_INFO ZONEMASK(29) // LIB common definition
-#define ZONE_WARN ZONEMASK(30) // LIB common definition
-#define ZONE_ERR ZONEMASK(31) // LIB common definition
-
-#define ZONE_TEXT_10 "Init"
-#define ZONE_TEXT_11 "Function"
-#define ZONE_TEXT_12 "Memory"
-#define ZONE_TEXT_13 ""
-#define ZONE_TEXT_14 ""
-#define ZONE_TEXT_15 ""
-#define ZONE_TEXT_16 ""
-#define ZONE_TEXT_17 ""
-#define ZONE_TEXT_18 ""
-#define ZONE_TEXT_19 ""
-#define ZONE_TEXT_20 ""
-#define ZONE_TEXT_21 ""
-#define ZONE_TEXT_22 ""
-#define ZONE_TEXT_23 ""
-#define ZONE_TEXT_24 ""
-#define ZONE_TEXT_25 ""
-#define ZONE_TEXT_26 ""
-#define ZONE_TEXT_27 ""
-#define ZONE_TEXT_28 ""
-#define ZONE_TEXT_29 "Info"
-#define ZONE_TEXT_30 "Warning"
-#define ZONE_TEXT_31 "Error"
-
-#define ALL_ZONES_BUT_IPC_INFO 0xEFFFFFFF
-
-#ifndef FRAMEWORKUNIFIEDLOGOPTIONS
-#define FRAMEWORKUNIFIEDLOGOPTIONS (LSHAREDMEM) // LPRINT, LSHAREDMEM
-#endif
-
-#ifndef FRAMEWORKUNIFIEDLOGAPPZONES
-#define FRAMEWORKUNIFIEDLOGAPPZONES ZONE_WARN, ZONE_ERR, ZONE_INFO
-#endif /* FRAMEWORKUNIFIEDLOGAPPZONES */
-
-#endif /* !_resmgr_api_resourcemanagerlog_h_ */ // NOLINT
diff --git a/systemservice/resource_manager/client/libresm.ver b/systemservice/resource_manager/client/libresm.ver
deleted file mode 100755
index fc56632..0000000
--- a/systemservice/resource_manager/client/libresm.ver
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * 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.
- */
-
-#
-# libresm version script
-#
-{
- global:
- ### .text section ###
- RESM_*;
- ### .data section ###
- local:
- *;
-};
-
diff --git a/systemservice/resource_manager/client/src/#resmgr_api_lib.c# b/systemservice/resource_manager/client/src/#resmgr_api_lib.c#
deleted file mode 100755
index 02e84e4..0000000
--- a/systemservice/resource_manager/client/src/#resmgr_api_lib.c#
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * 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.
- */
-
-#include <other_service/rpc.h>
-#include "resm_internal.h"
-#include "resmgr_api.h"
-#include "resmgr_api_resourcemanagerlog.h"
-
-/**********************************************
- * External variable definitions
- **********************************************/
-RPC_ID __thread rpcId;
-
-/*******************************************************************************
- * RPC public API
- *******************************************************************************/
-/* Connection */
-RESM_ERR_t
-RESM_Open(const RESM_RSV_t* p_prim, uint32_t* p_ssnId)
-{
-
- RESM_ERR_t resmRet;
- EV_ERR evRet;
-
- // Argument check
- if( p_ssnId == NULL ) {
- return RESM_E_PAR;
- }
-
- // RPC resources
- if( RPC_OK != RPC_START_CLIENT(&rpcId) ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr Open: RPC_START Error"); // LCOV_EXCL_BR_LINE 15:marco defined in "native_service/ns_logger_if.h"
- return RESM_E_NG;
- }
-
-
- // Session connection
- resmRet = RESM_SV_Open(p_prim, p_ssnId);
- if( resmRet != RESM_E_OK ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr Open: Open Session Error. ret[%d]", resmRet); // LCOV_EXCL_BR_LINE 15:marco defined in "native_service/ns_logger_if.h"
- return RESM_E_NG;
- }
-
- // Create Event Flag
- evRet = EV_create_flag(Resm_Flag_ID_Base + *p_ssnId);
- if( evRet != EV_OK ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr Open: create_flag Error. ret[%d]", evRet);
- return RESM_E_NG;
- }
-
- return RESM_E_OK;
-}
-
-/* Disconnection */
-RESM_ERR_t
-RESM_Close(uint32_t ssnId)
-{
-
- RESM_ERR_t resmRet;
-
- // Disconnect session
- resmRet = RESM_SV_Close(ssnId);
- if( resmRet != RESM_E_OK ) {
- return resmRet;
- }
-
- // Destroy RPC Resources
- RPC_end(rpcId);
-
- return RESM_E_OK;
-}
-
-/* Get event FD */
-RESM_ERR_t
-RESM_GetEventFd(uint32_t ssnId, int32_t* p_fd)
-{
-
- RESM_ERR_t resmRet;
-
- // Argument check
- if( p_fd == NULL ) {
- return RESM_E_PAR;
- }
- // Session ID check
- resmRet = RESM_SV_ChkSsnId(ssnId);
- if( resmRet != RESM_E_OK ) {
- return RESM_E_PAR;
- }
-
- if( EV_OK != EV_get_flag_fd(Resm_Flag_ID_Base + ssnId, p_fd) ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr GetEventFd Error");
- return RESM_E_NG;
- }
-
- return RESM_E_OK;
-}
-
-/* Get event */
-RESM_ERR_t
-RESM_GetEvent(uint32_t ssnId, RESM_EV_t* p_evFlag)
-{
-
- RESM_ERR_t resmRet;
- EV_Flag flag;
-
- // Argument check
- if( p_evFlag == NULL ) {
- return RESM_E_PAR;
- }
- // Session ID Check
- resmRet = RESM_SV_ChkSsnId(ssnId);
- if( resmRet != RESM_E_OK ) {
- return RESM_E_PAR;
- }
-
- if( EV_OK != EV_get_flag(Resm_Flag_ID_Base + ssnId, &flag)) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr GetEvent(get_flag) Error");
- return RESM_E_NG;
- }
-
- if( flag.bits == 0 ) {
- // No event
- return RESM_E_NG;
- }
-
- *p_evFlag = flag.bits;
-
- return RESM_E_OK;
-}
diff --git a/systemservice/resource_manager/client/src/resmgr_api_lib.c b/systemservice/resource_manager/client/src/resmgr_api_lib.c
deleted file mode 100755
index 02e84e4..0000000
--- a/systemservice/resource_manager/client/src/resmgr_api_lib.c
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * 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.
- */
-
-#include <other_service/rpc.h>
-#include "resm_internal.h"
-#include "resmgr_api.h"
-#include "resmgr_api_resourcemanagerlog.h"
-
-/**********************************************
- * External variable definitions
- **********************************************/
-RPC_ID __thread rpcId;
-
-/*******************************************************************************
- * RPC public API
- *******************************************************************************/
-/* Connection */
-RESM_ERR_t
-RESM_Open(const RESM_RSV_t* p_prim, uint32_t* p_ssnId)
-{
-
- RESM_ERR_t resmRet;
- EV_ERR evRet;
-
- // Argument check
- if( p_ssnId == NULL ) {
- return RESM_E_PAR;
- }
-
- // RPC resources
- if( RPC_OK != RPC_START_CLIENT(&rpcId) ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr Open: RPC_START Error"); // LCOV_EXCL_BR_LINE 15:marco defined in "native_service/ns_logger_if.h"
- return RESM_E_NG;
- }
-
-
- // Session connection
- resmRet = RESM_SV_Open(p_prim, p_ssnId);
- if( resmRet != RESM_E_OK ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr Open: Open Session Error. ret[%d]", resmRet); // LCOV_EXCL_BR_LINE 15:marco defined in "native_service/ns_logger_if.h"
- return RESM_E_NG;
- }
-
- // Create Event Flag
- evRet = EV_create_flag(Resm_Flag_ID_Base + *p_ssnId);
- if( evRet != EV_OK ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr Open: create_flag Error. ret[%d]", evRet);
- return RESM_E_NG;
- }
-
- return RESM_E_OK;
-}
-
-/* Disconnection */
-RESM_ERR_t
-RESM_Close(uint32_t ssnId)
-{
-
- RESM_ERR_t resmRet;
-
- // Disconnect session
- resmRet = RESM_SV_Close(ssnId);
- if( resmRet != RESM_E_OK ) {
- return resmRet;
- }
-
- // Destroy RPC Resources
- RPC_end(rpcId);
-
- return RESM_E_OK;
-}
-
-/* Get event FD */
-RESM_ERR_t
-RESM_GetEventFd(uint32_t ssnId, int32_t* p_fd)
-{
-
- RESM_ERR_t resmRet;
-
- // Argument check
- if( p_fd == NULL ) {
- return RESM_E_PAR;
- }
- // Session ID check
- resmRet = RESM_SV_ChkSsnId(ssnId);
- if( resmRet != RESM_E_OK ) {
- return RESM_E_PAR;
- }
-
- if( EV_OK != EV_get_flag_fd(Resm_Flag_ID_Base + ssnId, p_fd) ) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr GetEventFd Error");
- return RESM_E_NG;
- }
-
- return RESM_E_OK;
-}
-
-/* Get event */
-RESM_ERR_t
-RESM_GetEvent(uint32_t ssnId, RESM_EV_t* p_evFlag)
-{
-
- RESM_ERR_t resmRet;
- EV_Flag flag;
-
- // Argument check
- if( p_evFlag == NULL ) {
- return RESM_E_PAR;
- }
- // Session ID Check
- resmRet = RESM_SV_ChkSsnId(ssnId);
- if( resmRet != RESM_E_OK ) {
- return RESM_E_PAR;
- }
-
- if( EV_OK != EV_get_flag(Resm_Flag_ID_Base + ssnId, &flag)) {
- FRAMEWORKUNIFIEDLOG(ZONE_NS_ERR, __FUNCTION__, "[RESM_ERR]ResMgr GetEvent(get_flag) Error");
- return RESM_E_NG;
- }
-
- if( flag.bits == 0 ) {
- // No event
- return RESM_E_NG;
- }
-
- *p_evFlag = flag.bits;
-
- return RESM_E_OK;
-}