ODeV framework  v2
IBootVtbl.h
Go to the documentation of this file.
1 
31 #ifndef INCLUDE_SERVICES_IBOOTVTBL_H_
32 #define INCLUDE_SERVICES_IBOOTVTBL_H_
33 
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
37 
38 #include "systp.h"
39 #include "systypes.h"
40 #include "syserror.h"
41 
45 typedef struct _IBoot_vtbl IBoot_vtbl;
46 
50 struct _IBoot_vtbl {
51  sys_error_code_t (*Init)(IBoot *this);
52  boolean_t (*CheckDFUTrigger)(IBoot *this);
53  uint32_t (*GetAppAdderss)(IBoot *this);
54  sys_error_code_t (*OnJampToApp)(IBoot *this, uint32_t nAppDress);
55 };
56 
61 struct _IBoot {
65  const IBoot_vtbl *vptr;
66 };
67 
68 
69 // Inline functions definition
70 // ***************************
71 
72 SYS_DEFINE_INLINE
74  return this->vptr->Init(this);
75 }
76 
77 SYS_DEFINE_INLINE
78 boolean_t IBootCheckDFUTrigger(IBoot *this) {
79  return this->vptr->CheckDFUTrigger(this);
80 }
81 
82 SYS_DEFINE_INLINE
83 uint32_t IBootGetAppAdderss(IBoot *this) {
84  return this->vptr->GetAppAdderss(this);
85 }
86 
87 SYS_DEFINE_INLINE
88 sys_error_code_t IBootOnJampToApp(IBoot *this, uint32_t nAppDress) {
89  return this->vptr->OnJampToApp(this, nAppDress);
90 }
91 
92 
93 #ifdef __cplusplus
94 }
95 #endif
96 
97 #endif /* INCLUDE_SERVICES_IBOOTVTBL_H_ */
Define the global error management API.
Definition: IBootVtbl.h:50
const IBoot_vtbl * vptr
Definition: IBootVtbl.h:65
Definition: IBootVtbl.h:61
SYS_DEFINE_INLINE sys_error_code_t IBootOnJampToApp(IBoot *this, uint32_t nAppDress)
Definition: IBootVtbl.h:88
SYS_DEFINE_INLINE uint32_t IBootGetAppAdderss(IBoot *this)
Definition: IBootVtbl.h:83
SYS_DEFINE_INLINE boolean_t IBootCheckDFUTrigger(IBoot *this)
Definition: IBootVtbl.h:78
Common type declaration.
unsigned short sys_error_code_t
Definition: syserror.h:45
SYS_DEFINE_INLINE sys_error_code_t IBootInit(IBoot *this)
Definition: IBootVtbl.h:73
Target platform definition.