db81f606da8f5e6ba05416f261074fb34273388b
Add a simple test to validate basic functionalities of the VirtIO 9p device driver, `dev/virtio/9p`. For now the test attaches to the first v9p device and try to read the file `LICENSE` under the shared folder. Therefore, if you set the shared folder to the git root of `lk`, it will read the `LICENSE` of the littlekernel and dump it to the console after running `v9p_tests`. For example: ``` starting internet servers starting app shell entering main console loop ] v9p_tests 0x80013c08: 2f 2a 0a 20 2a 20 43 6f 70 79 72 69 67 68 74 20 |/*. * Copyright 0x80013c18: 28 63 29 20 32 30 30 38 2d 32 30 31 35 20 54 72 |(c) 2008-2015 Tr 0x80013c28: 61 76 69 73 20 47 65 69 73 65 6c 62 72 65 63 68 |avis Geiselbrech 0x80013c38: 74 0a 20 2a 0a 20 2a 20 50 65 72 6d 69 73 73 69 |t. *. * Permissi 0x80013c48: 6f 6e 20 69 73 20 68 65 72 65 62 79 20 67 72 61 |on is hereby gra ... ``` Signed-off-by: Cody Wong <codycswong@google.com>
The Little Kernel Embedded Operating System
The LK kernel is an SMP-aware kernel designed for small systems ported to a variety of platforms and cpu architectures.
See https://github.com/littlekernel/lk for the latest version.
High Level Features
- Fully-reentrant multi-threaded preemptive kernel
- Portable to many 32 and 64 bit architectures
- Support for wide variety of embedded and larger platforms
- Powerful modular build system
- Large number of utility components selectable at build time
Supported architectures
- ARM32
-
- Cortex-M class cores (armv6m - armv8m)
-
- ARMv7+ Cortex-A class cores
- ARM64
-
- ARMv8 and ARMv9 cores
- RISC-V 32 and 64bit bit in machine and supervisor mode
- x86-32 and x86-64 386 up through modern cores
- Motorola 68000
- Microblaze
- MIPS
- OpenRISC 1000
- VAX (experimental)
TODO
To build and test for ARM on linux
- install or build qemu. v2.4 and above is recommended.
- install gcc for embedded arm (see note 1)
- run scripts/do-qemuarm (from the lk directory)
- you should see 'welcome to lk/MP'
This will get you a interactive prompt into LK which is running in qemu arm machine 'virt' emulation. type 'help' for commands.
Note: for ubuntu x86-64: sudo apt-get install gcc-arm-none-eabi or fetch a prebuilt toolchain from https://newos.org/toolchains/x86_64-elf-13.2.0-Linux-x86_64.tar.xz
Languages
C
80.6%
C++
10.8%
Assembly
3.6%
Makefile
3.4%
Python
1%
Other
0.6%