OSDev.org
https://forum.osdev.org/

Good microkernel for x86_64
https://forum.osdev.org/viewtopic.php?f=1&t=33767
Page 1 of 1

Author:  GMorgan [ Sun Jul 14, 2019 4:59 pm ]
Post subject:  Good microkernel for x86_64

Hi Guys,

I'm wondering if anyone has successfully got anywhere getting a basic microkernel up and running for development? I've done some searching but most of the Google results are "wish there was documentation for this". Mostly I'm trying to get to the point where I can successfully launch an elf64 binary and output "Hello, world!" to the screen or serial port.

So far I've been trying with L4Ka:Pistachio. I've pulled in the Pistachio code from the github repository and followed a guide both linked below. There were a number of compile errors (I notice the repo is untouched for 5 years, most of the errors are related to trying to compare a char* to '\0' which doesn't seem to be allowed in the current GCC. I changed '\0' to "\0" to pass the error) which I made what seemed like reasonable fixes for them. When I boot my iso though I get an endless boot loop with the output below dumped into the serial console. I have no idea if this is what is intended or not because the guide neglects to mention what pingpong (the demo program) is actually supposed to do.

Anyone manage to either get this working or get something similar working with another micro kernel?

Thanks in advance.

Code:
KickStart 0.1374389535
Detected multiboot compliant loader
kernel    (0x0011f000-0x001791f0)   => 0x00d17000
  (0x0011f160-0x001486c0) -> 0x00600000-0x00629560
  (0x001486c0-0x00148fc3) -> 0x00800000-0x00800903
  (0x00149000-0x0014e1b4) -> 0x00a00000-0x00a051b4
  (0x0014f000-0x00165470) -> 0x00c00000-0x00c16470
  (0x00166000-0x0016dca0) -> 0x00d17000-0x00d1eca0
sigma0    (0x0017a000-0x001a0c48)   => 0x00f00000
  (0x0017a0c0-0x001802a0) -> 0x00f00000-0x00f061e0
roottask  (0x001a1000-0x001cc698)   => 0x01000820
  (0x001a10b0-0x001b20c8) -> 0x01000000-0x01011018


https://github.com/l4ka/pistachio

https://www.l4ka.org/english/120.php

Author:  Korona [ Mon Jul 15, 2019 12:24 am ]
Post subject:  Re: Good microkernel for x86_64

There should be quite a lot of microkernels that can boot a "Hello world!". Aside from the "classical" ones like Mach and L4, you could also look at Minix or Fuchsia. If you feel like experimenting a bit more, you could look at smaller hobby OSes (e.g., those written by members of this forum). The microkernel-based OS in my signature, for example, can boot to either kmscon or Weston (although the boot process is not documented very well, either).

In general, however, modifying a microkernel to boot into some non-default environment will always be harder than booting a monolithic kernel. Microkernels often rely on support code in userspace, e.g., to enumerate devices, load drivers, or even to provide the basic libc functionality.

Author:  bzt [ Mon Jul 15, 2019 2:13 am ]
Post subject:  Re: Good microkernel for x86_64

Hi,

GMorgan wrote:
Mostly I'm trying to get to the point where I can successfully launch an elf64 binary and output "Hello, world!" to the screen or serial port.
Check out my bootloader, that was specifically designed for 64 bit and micro-kernels. Here's its forum thread with all the features detailed.

It loads an initrd into memory, maps the kernel executable inside into higher half and transfers control to it. It sets up the framebuffer as well as the serial port. It is well documented, and comes with an example "Hello World" kernel.
Image

Cheers,
bzt

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/