ab0e1fd3a164ac3dedcd61810dd33863b42cd9da
For both 32 and 64bit x86, have each of the exception stubs which push a few words and branch to the common isr routine be simply 16 byte aligned to make it easy to calculate the offset from the main isr table. This cleans up some complexity that was actually broken for interrupts >= 0x80. Also: -Switch alignment directives to .balign -Expand the x86-32 exception table to a full 256 -Remove an extraneous define -Make sure the IDT is 8 or 16 byte aligned -Use END_DATA and END_FUNCTION in the exception and gdt asm files
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%