2 * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #include <system_service/tskm_data_init.h>
19 #include "libss_data_init_taskmanagerlog.h"
22 #define ZONE_INFO ZONEMASK(29)
25 const char *serviceName;
26 EFrameworkunifiedStatus (*dataInitFunc)(T_SS_SM_START_DataStructType *arg);
31 const FUNC_INFO_t g_funcTbl[] = {
35 static T_SS_SM_START_ExtDataStructType extBootInfo;
37 TSKM_ERR_t TSKM_GetExtBootInfo(T_SS_SM_START_ExtDataStructType *p_info){
38 TSKM_ERR_t ret = TSKM_E_OK;
41 FRAMEWORKUNIFIEDLOG(ZONE_ERR,__FUNCTION__,"p_info = NULL");
44 memcpy(p_info, &extBootInfo, sizeof(*p_info));
50 void tskm_dataInitAll(T_SS_SM_START_DataStructType *arg, T_SS_SM_START_ExtDataStructType *extArg){
52 int itemNum = sizeof(g_funcTbl)/sizeof(FUNC_INFO_t) - 1;
54 memcpy(&extBootInfo, extArg, sizeof(extBootInfo));
56 // LCOV_EXCL_START 10: Depends on reference information when building software
57 for(i=0;i<itemNum;i++){
58 FRAMEWORKUNIFIEDLOG(ZONE_INFO,__FUNCTION__,"call datainit for %s",g_funcTbl[i].serviceName);
59 g_funcTbl[i].dataInitFunc(arg);
64 } // LCOV_EXCL_BR_LINE 10: Final line