Advanced Operating Systems
COMP9242 2018/S2 |
UNSW
CRICOS Provider Number: 00098G |
Printer-Friendly
Version
|
Milestone 0: FamiliarisationThis is a simple exercise designed to get you started on seL4 and set up your hardware kit. It contains very detailed instructions, together with the existing source code and the seL4 manual you should have no problem doing it. Your EnvironmentIf you haven't already you may want to take a look at Odroid C2 Lab, which provides details on the contents of your kit. Log into the CSE lab machine before you plug in the hardware, as this triggers the machine to run specific scripts for your project to work, on your account. If you have permission/tftp issues down the line, try unplugging/replugging the usb/serial adapter and ethernet adapter while logged in. The required tools can be set up on a CSE lab machine by running weill% 9242 Collecting jinja2 Using cached https://files.pythonhosted.org/packages/7f/ff/ae64bacdfc95f27a016a7bed8e8686763ba4d277a78ca76f32659220a731/Jinja2-2.10-py2.py3-none-any.whl Collecting MarkupSafe>=0.23 (from jinja2) Installing collected packages: MarkupSafe, jinja2 Successfully installed MarkupSafe-1.0 jinja2-2.10 Collecting future Downloading https://files.pythonhosted.org/packages/00/2b/8d082ddfed935f3608cc61140df6dcbf0edea1bc3ab52fb6c29ae3e81e85/future-0.16.0.tar.gz (824kB) 100% |################################| 829kB 827kB/s Building wheels for collected packages: future Running setup.py bdist_wheel for future ... done Stored in directory: /import/adams/1/cs9242/.cache/pip/wheels/bf/c9/a3/c538d90ef17cf7823fa51fc701a7a7a910a80f6a405bf15b1a Successfully built future Installing collected packages: future Successfully installed future-0.16.0 Collecting ply Downloading https://files.pythonhosted.org/packages/a3/58/35da89ee790598a0700ea49b2a66594140f44dec458c07e8e3d4979137fc/ply-3.11-py2.py3-none-any.whl (49kB) 100% |################################| 51kB 1.9MB/s Installing collected packages: ply Successfully installed ply-3.11 newclass starting new subshell for class COMP9242... weill% aarch64-linux-gnu-ld aarch64-linux-gnu-ld: no input files The above updates your path to include the cross compilers and other tools located in the cs9242 home directory, and python packages that the seL4 build depends on for your local user account. You will need to run Get the sourceGet yourself a copy of the skeleton SOS. We use
You can find some pointers on using On a CSE machine
On other machinesIf you are not using a lab machine, you will need to ensure that Once your PATH is setup, you can check out the code:
Building SOSDependenciesThe CSE lab machines have already been configured with all dependencies. To set up another machine, please see the Linux instructions or the virtual machine instructions for using a VM to run Linux in order to build the project. Build the projectWe use Cmake and ninja as our build system, which you can read more about
on the seL4 docsite. Importantly, this build system does not build in the source tree: you create another directory (in this case build to build code in, and develop in the source directories.
Follow these instructions to build SOS:
There will be some ELFCLASS_32 errors on cse lab machines. These can safely be ignored By default ninja builds in parallel. If you have a lot of build errors, trhis can cause confusing output. use ninja -j1 to build with only one thread, which will make the build slower but also serialise the output. Getting it GoingBooting your Odroid-c2 for the first time is easy:
setenv ipaddr 192.168.168.2 setenv serverip 192.168.168.1 setenv bootcmd 'tftpboot 0x10000000 sos-image-arm-odroidc2 && go 0x10000000' saveenv # write the new settings to the eMMC Development cycleWe have developed a few tools to speed the development cycle along. The makefile can copy the sos operating system, known as a bootimage to your tftp directory and reset the OdroidC2. Below is a typical development cycle, assuming the path changes to your login script: $ ../reset.sh && nc -lp 26718 The MilestoneThe example skeleton operating system includes an application
The example includes a The second part of milestone zero is to find a partner for the rest of the project. The project is to be completed, in pairs, unless prior permission has been obtained from the LiC. Before you complete this milestone, be sure to spend time becoming familiar with the seL4 Debugging Guide. It will save you a lot of debugging effort throughout the project. Recommended procedureAssessmentMilestone submissionSee the milestone submission guidelines for instructions on submitting your milestone solution. Milestone DemonstrationYou will need to demonstrate user applications printing to the 2nd console via libserial, running on the OdroidC2 hardware to the tutor during the demonstration period. You should be prepared to show your tutor which files you modified in your solution, and explain any design decisions you made. Note that since you do not have consistent virtual memory management yet, your protocol will be fairly simple for now. However, it should be upgraded as more parts of the system are completed. Your tutor will be particularly interested in the details of your IPC interface with different sized blocks of data etc, and how you plan to improve it in future. Hint: sending a byte at a time is not a good solution. You will let the tutor know who your partner is so that group accounts can be created for you. Last modified: 07 Aug 2018. |