Can postmarketOS use 2 kernels?

6 months ago by mecen to c/postmarketos

Can some functionalities for os be passed to second kernel?

For example there could be docker or some other VM with Halium kernel to use some apps for example WiFi, camera and SIM calling?

Example can be qubesos which uses separate VM to do networking and other functions.

paper_moon 4 points 6 months ago

I've been wondering about this since I saw this patch get posted https://lwn.net/Articles/1038815/

If this is possible to run multiple kernels then I would think it would be the best approach postmarketos could take, yes it would be less secure because of the old outdated android kernel, but we could possibly have working phones then. Like you said, use the android kernel for hardware access and mainline linux kernel for software support. As it stands right now, fairphone 5 is close with mainline, but still doesn't really have working cameras and volte still doesn't work so no calling in the US.

path: 0 23217702, hotness: undefined, score: 4, children: 1
mecen 1 point 6 months ago

Looks cool I wonder how it would work in action.

path: 0 23217702 23219038, hotness: undefined, score: 1, children: 0
balsoft 3 points 6 months ago

Extremely theoretically - yes. You could run other kernels in VMs with hardware passthru. Not docker, because that's containerization that runs on the host kernel, but something like QEMU.

Realistically - no, there is no support for this, I don't think it's planned, and I don't think it would be useful anyways. Old phone hardware which pmOS currently supports doesn't do hardware virtualization well in the first place. Even if it did, getting all the hardware passthru working right is extremely non-trivial, and performance would probably be horrible because of constricted RAM.

path: 0 23216979, hotness: undefined, score: 3, children: 10
mecen 2 points 6 months ago

Doesn't kernel require just tens of MB?

path: 0 23216979 23217408, hotness: undefined, score: 2, children: 9
balsoft 2 points 6 months ago

You'd need to run a lot of duplicate services on top of that kernel for it to be any useful. Besides, the VM adds its own memory overhead too.

path: 0 23216979 23217408 23217676, hotness: undefined, score: 2, children: 8
paper_moon 2 points 6 months ago path: 0 23216979 23217408 23217676 23217732, hotness: undefined, score: 2, children: 7
balsoft 1 point 6 months ago

First of all, AFAIR it only really works on x86 for now. Besides, I don't see much benefit in running two kernels side-by-side like this in this situation, you would once again have to run a lot of services twice (eating up RAM) and you don't even get any security benefits in return. The only slight benefit is better software compatibility on a newer kernel but in all likelyhood it's easier to backport the software to the old kernel, rather than get this exceptionally weird multikernel setup running on already quirky phone hardware.

path: 0 23216979 23217408 23217676 23217732 23218035, hotness: undefined, score: 1, children: 6
postmarketos
postmarketos

@lemmy.world

login for more options
345
33
82

Moved to: !nura@lemmy.world

go to feed...