| 45 | |
| 46 | = RTEMS startup as a guest = |
| 47 | |
| 48 | |
| 49 | In L4RTEMS the wrapper task loads the RTEMS elf-binary, stores the initial IP and SP in the vCPU registers and starts the vCPU. |
| 50 | Therefore the binary is passed as a command line argument. |
| 51 | |
| 52 | We need to keep in mind, that issue should NOT lead to hacks in the virtualization layer of RTEMS. |
| 53 | It is more of a hypervisor/host issue and needs to be resolved in this scope and this scope only. |
| 54 | |
| 55 | How can we start RTEMS on POK? |
| 56 | The closest abstraction to the L4-vCPU I have found in POK is the software partition itself. |
| 57 | However, if we can make it, we need to change the partitions SP,IP and EAX register, while running on it. |
| 58 | This looks like a hack and not like a careful design. |
| 59 | |
| 60 | But there are other options. |
| 61 | One I can think of is: |
| 62 | * compiling the library in POK. |
| 63 | * provide the lib to RTEMS and compile the application. |
| 64 | * pass the binary back to POK and combine kernel and binary. |
| 65 | |
| 66 | This approach was partly used in the GSoC 2012 project. |
| 67 | |
| 68 | Another approach would be : |
| 69 | * compile RTEMS and do a first linking run |
| 70 | * compile POK and pass the partly linked RTEMS file along |
| 71 | * The POK starter function would do the env setup and then call the RTEMS start() (0x10000c) |