Changes between Version 23 and Version 24 of GSoC/2013/ParavirtualizationOfRTEMS

May 3, 2013, 1:32:43 PM (6 years ago)

/* RTEMS startup as a guest */ Build POK Partition binary in RTEMS


  • GSoC/2013/ParavirtualizationOfRTEMS

    v23 v24  
    9797Thanks to DrJoel:
    9898"If it is "ld -r", then it may still need a real linking with linkcmds to be at a known address range to insert into the Pok link."
     100==  Compile POK partition in RTEMS  ==
     103POK awaits ELF binaries to be included in the final linking stage.
     104If we can provide RTEMS with enough information (read include files) to build up a valid partition binary, we maybe could set the entry point into the RTEMS binary and get POK to execute it, as it would start every other partition.
     105As far as I can see, the ELF file compiled in the partX directories is taken and merged with the kernel binary.
     106At run-time the kernel the loads the partition_size table and loads the ELF binaries into memory.
     107I haven't come across checks, if the binary is a POK one.
     109I replaced the part1/part1.elf with the RTEMS hello.exe in the ''generated-code/cpu/Makefile'' and introduced a new Makefile target just invoking $(TARGET):
     111  1 export ARCH=x86
     112  2 export BSP=x86-qemu
     114  6 TARGET=$(shell pwd)/pok.elf
     115  7 #PARTITIONS= part1/part1.elf
     116  8 PARTITIONS= part1/hello.exe
     118 10 KERNEL=kernel/kernel.lo
     119 11 all: build-kernel partitions $(TARGET)
     120 12
     121 13 last: $(TARGET)
     125Invoking with ''make last'' produces the expected result: The size.c file contains the size of hello.exe and nm partitions.bin shows the RTEMS symbols.
     127However, POK fails at start up, I didn't figure out where exactly, yet, but it looks like an issue while loading the binary.
    99128=  Virtual CPU Issue  =