Changeset 289 for soft/giet_vm/giet_kernel/kernel_init.c
- Timestamp:
- Feb 4, 2014, 2:16:37 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
soft/giet_vm/giet_kernel/kernel_init.c
r281 r289 64 64 65 65 //////////////////////////////////////////////////////////////////////////////////// 66 // staks for the "idle" tasks ( 256bytes for each processor)66 // staks for the "idle" tasks (512 bytes for each processor) 67 67 //////////////////////////////////////////////////////////////////////////////////// 68 68 69 69 __attribute__((section (".kdata"))) 70 unsigned int _idle_stack[X_SIZE *Y_SIZE * NB_PROCS_MAX * 128];70 unsigned int _idle_stack[X_SIZE * Y_SIZE * NB_PROCS_MAX * 128 ]; 71 71 72 72 //////////////////////////////////////////////////////////////////////////////////// … … 343 343 // step 5 : each processor updates the idle_task context: 344 344 // (only CTX_SP, CTX_RA, CTX_EPC). 345 // The stack size is 256bytes, reserved in seg_kdata.345 // The stack size is 512 bytes, reserved in seg_kdata. 346 346 // The PTPR register, the CTX_PTPR and CTX_PTAB slots 347 347 // have been initialised in boot code. 348 348 349 unsigned int stack = (unsigned int)_idle_stack + ((global_pid + 1)<<9); 349 unsigned int x = cluster_xy >> Y_WIDTH; 350 unsigned int y = cluster_xy & ((1<<Y_WIDTH)-1); 351 unsigned int p = ((x * Y_SIZE) + y) * NB_PROCS_MAX + local_pid; 352 353 unsigned int stack = (unsigned int)_idle_stack + ((p + 1)<<9); 350 354 351 355 _set_task_slot( global_pid, IDLE_TASK_INDEX, CTX_SP_ID, stack);
Note: See TracChangeset
for help on using the changeset viewer.