diff options
Diffstat (limited to 'config/library/system_manager_config/include')
4 files changed, 343 insertions, 0 deletions
diff --git a/config/library/system_manager_config/include/system_service/ss_access_if_private.h b/config/library/system_manager_config/include/system_service/ss_access_if_private.h new file mode 100644 index 00000000..85a92865 --- /dev/null +++ b/config/library/system_manager_config/include/system_service/ss_access_if_private.h @@ -0,0 +1,80 @@ +/* + * @copyright Copyright (c) 2016-2019 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. + */ +/** + * @file ss_access_if_private.h + * @brief \~english This file contains declaration of structures RAM_AccessPrivate and ROM_AccessPrivate + */ +/** @addtogroup BaseSystem + * @{ + */ +/** @addtogroup system_service + * @ingroup BaseSystem + * @{ + */ +/** @addtogroup config + * @ingroup system_service + * @{ + */ +#ifndef CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_ACCESS_IF_PRIVATE_H_ +#define CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_ACCESS_IF_PRIVATE_H_ + +#include <system_service/ss_sm_rom_access.h> +#include <system_service/ss_sm_ram_access.h> + +// Should be design the data so that the default value is 0. + +// Product private area for DRAM BACKUP + +/** + * @struct RAM_AccessPrivate + * @brief \~english RAM Access Private data define + */ +typedef struct { + union { + //! \~english _CWORD80_ error define + struct { + /* + * Note. + * This feature needs to be defined depending on the product specification by the vendor. + */ + }; + //! \~english RAM product private max + uint8_t max[RAM_PRODUCT_PRIVATE_MAX]; + }; +} RAM_AccessPrivate; + +/** + * @struct ROM_AccessPrivate + * @brief \~english ROM Access Private data define + */ +typedef struct { + union { + // Since data is accessed with 32 bit width at the low level, data must be allocated using 32 bits algin + struct { + /* + * Note. + * This feature needs to be defined depending on the product specification by the vendor. + */ + }; + //! \~english ROM product private max + uint8_t max[ROM_PRODUCT_PRIVATE_MAX]; + }; +} ROM_AccessPrivate; + +#endif // CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_ACCESS_IF_PRIVATE_H_ +/** @}*/ +/** @}*/ +/** @}*/ diff --git a/config/library/system_manager_config/include/system_service/ss_package.h b/config/library/system_manager_config/include/system_service/ss_package.h new file mode 100644 index 00000000..cec4c6b2 --- /dev/null +++ b/config/library/system_manager_config/include/system_service/ss_package.h @@ -0,0 +1,92 @@ +/* + * @copyright Copyright (c) 2016-2019 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. + */ +/** + * @file ss_package.h + * @brief \~english This file contains declaration of common package values + */ +/** @addtogroup BaseSystem + * @{ + */ +/** @addtogroup system_service + * @ingroup BaseSystem + * @{ + */ +/** @addtogroup system_manager + * @ingroup system_service + * @{ + */ +#ifndef CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_PACKAGE_H_ +#define CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_PACKAGE_H_ + +// _CWORD71_ package name list + +#define SS_PKG_SPI_LOADER "SPI_LOADER" // define SPI_LOADER for spi_loader +#define SS_PKG_UBOOT "UBOOT" // define UBOOT for uboot +#define SS_PKG_SECURE_LOADER "SECURE_LOADER" // define SECURE_LOADER for secure_loader + +#define SS_PKG_SYS_UCOM "SYS_UCOM" // define SYS_UCOM for sys_ucom +#define SS_PKG_CAN_UCOM "CAN_UCOM" // define CAN_UCOM for can_ucom +#define SS_PKG__CWORD52__UCOM "_CWORD52__UCOM" // define _CWORD52__UCOM for _CWORD52__ucom +#define SS_PKG__CWORD52__DATA "_CWORD52__DATA" // define _CWORD52__DATA for _CWORD52__data +#define SS_PKG__CWORD52__FIXEQ "_CWORD52__FIXEQ" // define _CWORD52__FIXEQ for _CWORD52__fixeq + +#define SS_PKG_MAIN_EMMC "MAIN_EMMC" // define MAIN_EMMC for main_emmc +#define SS_PKG_TARGETBOARD "TARGETBOARD" // define TARGETBOARD for target boar + +#define SS_PKG_MAIN_PRODUCT_SI "MAIN_PRODUCT_SI" // define MAIN_PRODUCT_SI for main_product_si +#define SS_PKG_MAIN_COMP_SI "MAIN_COMP_SI" // define MAIN_COMP_SI for main_comp_si +#define SS_PKG_MAIN_LPF_SI "MAIN_LPF_SI" // define MAIN_LPF_SI for main_lpf_si + +#define SS_PKG_FACTORY_FROM "FACTORY_FROM" // define FACTORY_FROM for factory_from +#define SS_PKG_FACTORY_FROM2 "FACTORY_FROM2" // define FACTORY_FROM2 for factory_from2 +#define SS_PKG_FACTORY_EEPROM "FACTORY_EEPROM" // define FACTORY_EEPROM for factory_eeprom +#define SS_PKG_DECK "DECK" // define DECK for deck +#define SS_PKG_REAGION_CODE "REAGION_CODE" // define REAGION_CODE for reagion_code +#define SS_PKG__CWORD8__DB "_CWORD8__DB" // define _CWORD8__DB for _CWORD8__db +#define SS_PKG_CAPACITIVE_TP "CAPACITIVE_TP" // define CAPACITIVE_TP for capacitive_tp +#define SS_PKG__CWORD52___CWORD32_ "_CWORD52___CWORD32_" // define _CWORD52___CWORD32_ for _CWORD52___CWORD32_ +#define SS_PKG_RADIO_PARAMETER "RADIO_PARAMETER" // define RADIO_PARAMETER for radio_parameter +#define SS_PKG_VR_DATA "VR_DATA" // define VR_DATA for vr_data +#define SS_PKG_NAVI_GPS "NAVI_GPS" // define NAVI_GPS for navi_gps +#define SS_PKG_DTV_MAIN "DTV_MAIN" // define DTV_MAIN for dtv_main +#define SS_PKG_DTV_EEPROM "DTV_EEPROM" // define DTV_EEPROM for dtv_eeprom +#define SS_PKG_DTV_BOOT "DTV_BOOT" // define DTV_BOOT for dtv_boot +#define SS_PKG_DTV_STATION_DB "DTV_STATION_DB" // define DTV_STATION_DB for dtv_station_db +#define SS_PKG_XM_TYPE_ID "XM_TYPE_ID" // define XM_TYPE_ID for xm_type_id +#define SS_PKG_XM_HW "XM_HW" // define XM_HW for xm_hw +#define SS_PKG_XM_SW "XM_SW" // define XM_SW for xm_sw +#define SS_PKG_XM_SXI "XM_SXI" // define XM_SXI for xm_sxi +#define SS_PKG_XM_BB "XM_BB" // define XM_BB for xm_bb +#define SS_PKG_XM_HDEC "XM_HDEC" // define XM_HDEC for xm_hdec +#define SS_PKG_XM_RF "XM_RF" // define XM_RF for xm_rf +#define SS_PKG_XM_SPL "XM_SPL" // define XM_SPL for xm_spl +#define SS_PKG_XM_AREA "XM_AREA" // define XM_AREA for xm_area +#define SS_PKG_NAVI_PROGRAM "NAVI_PROGRAM" // define NAVI_PROGRAM for navi_program +#define SS_PKG_NAVI_MAP "NAVI_MAP" // define NAVI_MAP for navi_map +#define SS_PKG_PHASE_INFO "PHASE_INFO" // define PHASE_INFO for phase_info + +#define SS_PKG_SERIES_INFO "SERIES_INFO" +#define SS_PKG_FPGA "FPGA" // define FPGA for fpga +#define SS_PKG_VP_CONFIG "VP_VEHICLEPARAMETERLIBRARY" // define VP_VEHICLEPARAMETERLIBRARY for vp_vehicleparameterlibrary +#define SS_PKG_VP__CWORD31_ "VP__CWORD31_" // define VP__CWORD31_ for vp__CWORD31_ +#define SS_PKG_PREINSTALL_DATA "PREINSTALL_DATA" // define PREINSTALL_DATA for preinstall_data + +#define MSG_PSM_REBOOT_NOTIFY 0x11 // define ps_psmshadow reboot notice id + +#endif // CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_PACKAGE_H_ +/** @}*/ +/** @}*/ +/** @}*/ diff --git a/config/library/system_manager_config/include/system_service/ss_system_manager_conf.h b/config/library/system_manager_config/include/system_service/ss_system_manager_conf.h new file mode 100644 index 00000000..d0125869 --- /dev/null +++ b/config/library/system_manager_config/include/system_service/ss_system_manager_conf.h @@ -0,0 +1,145 @@ +/* + * @copyright Copyright (c) 2016-2019 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. + */ +/** + * @file ss_system_manager_conf.h + * @brief \~english This file contains declaration of structures T_SS_SM_INIT_HOOK_IN_PARAM, T_SS_SM_INIT_HOOK_OUT_PARAM and api initial Hook + */ +/** @addtogroup BaseSystem + * @{ + */ +/** @addtogroup system_service + * @ingroup BaseSystem + * @{ + */ +/** @addtogroup config + * @ingroup system_service + * @{ + */ +#ifndef CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_SYSTEM_MANAGER_CONF_H_ +#define CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_SYSTEM_MANAGER_CONF_H_ + +#include <native_service/frameworkunified_types.h> +#include <vector> +#include <string> + +/** + * @struct T_SS_SM_INIT_HOOK + * @brief \~english Version up mode, Callback function + */ +typedef struct T_SS_SM_INIT_HOOK { + //! \~english Version up mode + BOOL bIsVupMode; + //! \~english Call back function + EFrameworkunifiedStatus (*cbRebootNoticeFunc)(HANDLE hApp); + + T_SS_SM_INIT_HOOK() + : bIsVupMode(FALSE), + cbRebootNoticeFunc(NULL) { + } +} T_SS_SM_INIT_HOOK_IN_PARAM; + + +/** + * @struct T_SS_SM_INIT_HOOK_OUT_PARAM + * @brief \~english Not in OOM Killer's service object, Group Relaunch service. + */ +typedef struct { + std::vector<std::string> protectedSvcs; + //! \~english Not in OOM Killer's service object. + std::vector<std::string> groupRelaunchSvcs; + //! \~english Group Relaunch service. +} T_SS_SM_INIT_HOOK_OUT_PARAM; + +///////////////////////////////////////////////////////////////////////////////////// +/// \ingroup ss_sm_initHook +/// \~english @par Summary +/// +/// \~english @param [in] hApp +/// HANDLE - HANDLE Application +/// \~english @param [in] inPrm +/// T_SS_SM_INIT_HOOK_IN_PARAM - +/// \~english @param [in] outPrm +/// T_SS_SM_INIT_HOOK_OUT_PARAM - +/// \~english @par +/// T_SS_SM_INIT_HOOK_IN_PARAM struct +/// \~english @code +/// typedef struct T_SS_SM_INIT_HOOK { +/// BOOL bIsVupMode; /* version up model */ +/// EFrameworkunifiedStatus (*cbRebootNoticeFunc)(HANDLE hApp); /* call back function */ +/// T_SS_SM_INIT_HOOK() +/// : bIsVupMode(FALSE), +/// cbRebootNoticeFunc(NULL) { +/// } /* constructor */ +/// } T_SS_SM_INIT_HOOK_IN_PARAM; +/// @endcode +/// \~english @par +/// T_SS_SM_INIT_HOOK_IN_PARAM struct +/// \~english @code +/// typedef struct { +/// std::vector<std::string> protectedSvcs; /* OOM Killer's protected service */ +/// std::vector<std::string> groupRelaunchSvcs; /* group relunch service */ +/// } T_SS_SM_INIT_HOOK_OUT_PARAM; +/// @endcode +/// \~english @retval eFrameworkunifiedStatusOK Success +/// \~english @retval eFrameworkunifiedStatusInvldParam Invalid parameter +/// \~english @retval eFrameworkunifiedStatusNullPointer Invalid pointer +/// \~english @retval eFrameworkunifiedStatusInvldHandle Invalid handle +/// \~english @retval eFrameworkunifiedStatusInvldHndlType Invalid type of handle +/// \~english @retval eFrameworkunifiedStatusMsgQFull Message queue is full +/// \~english @retval eFrameworkunifiedStatusErrNoEBADF Invalid File-Descriptor +/// \~english @retval eFrameworkunifiedStatusErrNoEINTR An interrupt is generated by the system call (signal) +/// \~english @retval eFrameworkunifiedStatusInvldBufSize Invalid buffer-size +/// \~english @retval eFrameworkunifiedStatusFail Some sort of error occurred +/// \~english @retval eFrameworkunifiedStatusErrOther Other error(It failed to open/allocation of shared memory) +/// \~english @par Preconditions +/// - None +/// \~english @par Change of the internal state +/// - save inPrm->cbRebootNoticeFunc to s_confCtx.cbRebootNoticeFunc. +/// \~english @par Causes of failures +/// - +/// - System Manager of the session does not exist. [eFrameworkunifiedStatusNullPointer] +/// - System Manager handle for the session is NULL. [eFrameworkunifiedStatusInvldHandle] +/// - System Manager handle type for the session is not a transmission type. [eFrameworkunifiedStatusInvldHndlType] +/// - System Manager message queue for the session is full. [eFrameworkunifiedStatusMsgQFull] +/// - Transmission for the file descriptor of System Manager message for the session is invalid. \n +/// [eFrameworkunifiedStatusErrNoEBADF] +/// - Place to interrupt by the system call (signal) has occurred during the transmission of \n +/// the System Manager message for the session. [eFrameworkunifiedStatusErrNoEINTR] +/// - Size of the transmission buffer of the System Manager message for the session is invalid. \n +/// [eFrameworkunifiedStatusInvldBufSize] +/// - Any error has occurred at the time of transmission of the System Manager message for the session. \n +/// [eFrameworkunifiedStatusFail] +/// - Transmission of System Manager message for the session fails to shared memory access. \n +/// [eFrameworkunifiedStatusErrOther] +/// \~english @par Classification +/// Public +/// \~english @par Type +/// Sync +/// \~english @par Detail +/// get env val from application,and write these to Launch Config file. +/// \~english @par +/// eFrameworkunifiedStatus:Result +/// - eFrameworkunifiedStatusOK:Success +/// - Except eFrameworkunifiedStatusOK:Fail +/// \~english @see None +//////////////////////////////////////////////////////////////////////////////////// +EFrameworkunifiedStatus ss_sm_initHook(HANDLE hApp, const T_SS_SM_INIT_HOOK_IN_PARAM *inPrm, + T_SS_SM_INIT_HOOK_OUT_PARAM *outPrm); + +#endif // CONFIG_LIBRARY_SYSTEM_MANAGER_CONFIG_INCLUDE_SYSTEM_SERVICE_SS_SYSTEM_MANAGER_CONF_H_ +/** @}*/ +/** @}*/ +/** @}*/ diff --git a/config/library/system_manager_config/include/system_service/system_manager_config.h b/config/library/system_manager_config/include/system_service/system_manager_config.h new file mode 100644 index 00000000..332a0bf0 --- /dev/null +++ b/config/library/system_manager_config/include/system_service/system_manager_config.h @@ -0,0 +1,26 @@ +/* + * @copyright Copyright (c) 2017-2019 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. + */ +/** + * @file + */ +#ifndef SYSTEMSERVICE_SYSTEMMANAGERCONFIG_H_ // NOLINT(build/header_guard) +#define SYSTEMSERVICE_SYSTEMMANAGERCONFIG_H_ // NOLINT(build/header_guard) + +#include <system_service/ss_access_if_private.h> +#include <system_service/ss_package.h> +#include <system_service/ss_system_manager_conf.h> + +#endif // SYSTEMSERVICE_SYSTEMMANAGERCONFIG_H_ |