23 #ifndef __POK_PARTITION_H__
24 #define __POK_PARTITION_H__
26 #ifdef POK_NEEDS_PARTITIONS
41 POK_PARTITION_MODE_INIT_COLD = 1,
43 POK_PARTITION_MODE_INIT_WARM = 2,
45 POK_PARTITION_MODE_NORMAL = 3,
49 POK_PARTITION_MODE_IDLE = 4,
50 POK_PARTITION_MODE_RESTART = 5,
51 POK_PARTITION_MODE_STOPPED = 6,
52 }pok_partition_mode_t;
57 PARTITION_RESTART = 1,
58 HM_MODULE_RESTART = 2,
59 HM_PARTITION_RESTART = 3
60 }pok_start_condition_t;
95 #if defined(POK_NEEDS_LOCKOBJECTS) || defined(POK_NEEDS_ERROR_HANDLING)
101 #ifdef POK_NEEDS_SCHED_HFPPS
105 #ifdef POK_NEEDS_ERROR_HANDLING
107 pok_error_status_t error_status;
111 pok_partition_mode_t mode;
119 pok_start_condition_t start_condition;
129 #define POK_CURRENT_PARTITION pok_partitions[POK_SCHED_CURRENT_PARTITION]
135 #define POK_CHECK_PTR_IN_PARTITION(pid,ptr) (\
136 ((((uint32_t)ptr)>=pok_partitions[pid].base_addr)&& \
137 (((uint32_t)ptr)<=(pok_partitions[pid].base_addr+pok_partitions[pid].size)))?1:0\
145 pok_ret_t pok_partition_set_mode (
const uint8_t pid,
const pok_partition_mode_t mode);
146 pok_ret_t pok_partition_set_mode_current (
const pok_partition_mode_t mode);
151 void pok_partition_reinit (
const uint8_t);
153 void pok_partition_setup_main_thread (
const uint8_t);
155 void pok_partition_setup_scheduler (
const uint8_t pid);
165 pok_ret_t pok_current_partition_get_operating_mode (pok_partition_mode_t *op_mode);
169 pok_ret_t pok_current_partition_get_start_condition (pok_start_condition_t *start_condition);