Oddbean new post about | logout
 Can anyone recommend a good technical book for OS development or kernel development? Preferably UNIX or Linux systems.

#devstr #asknostr #askstr 
 ChatGPT maybe? 
 I prefer word of mouth from people who have worked on these things. 
 "Linux kernel development" by Robert Love is the classic, it's a bit dated but still mostly relevant
Another one is "Parallel Programming Hard, And, If So, What Can You Do About It?" by Paul McKenney, specifically focused on parallel programming in the Linux kernel, it's a free download at https://mirrors.edge.kernel.org/pub/linux/kernel/people/paulmck/perfbook/perfbook.html 
 Thank you so much. I’m certain your advice will prove very useful to me in the future. 
 In priority order: 

The Linux Programming Interface - Michael Kerrisk
https://github.com/sysprog21/lkmpg
Linux System Programming - Robert Love
Linux Kernel Module Programming Guide (Outdated, 1999)

I think I have a few more 
 I have the book by Robert Love. What I’m looking is kernel development. In other words, developing the kernel, developing the operating system itself. 
 My next question was going to be scope. So developing an operating system in general or like specifically Linux internals?  
 For now, in general. Closer to the hardware. My aim is to learn the amd64 (aka x86_64) architecture and OS fundamentals in practice.

Ultimately I’d like to move on towards Linux specifics. But this is not yet my current immediate aim. 
 the usual CS textbooky approach would be to start with something like Minix, or some small microkernels such as seL4
other "mini operating systems" are bootloaders like GRUB and u-boot

then combine it with some more general Operating Systems book that explains the fundamentals (i know no recent ones, sorry, that's too long ago for me)

but don't be too intimidated by Linux, it's not all very complex code, and it's fairly well documented, though there *is* a lot of it 
 Very well, I shall take this into account. My aim here isn’t to build anything specific yet. It’s more about learning. The textbooky approach seems good enough for me. Thank you! 
 Okay, let me do some searching and digging and Ill see what else I have saved that might help!

Have you looked into FreeRTOs? I had to dabble the tiniest bit when working on a school project a while ago. Then I got into directly working with Atmel hardware bare metal. From 2018-2023 I spent learning early 8065 (pre x86 but tightly coupled to early stuff)

Something also worth looking into is the Cosmo LibC project https://github.com/jart/cosmopolitan. Justine is awesome and so is her discord! I mention this because most of her library is highly hardware optimized and plenty of asm to go around. 

There are a couple other folks in the discord like ahgamut and paulclinger along with some other peeps from NIST and other orgs that are just awesome to read and chat with too 
 You just unlocked a memory. I’ve worked with FreeRTOS on Atmega chips for competitions and school projects as well, but that was such a long time ago. 
 I just check this repo’s readme, I love the idea. I’m gonna follow them. Thanks for the suggestion. 
 NP! The ELF stuff is way over my head, but they have done some pretty wicked OS "hacking"  
 Everything is “over our heads” before we get into it ! 
 t-y Chip Turner 
 Is not that I personally looked into it. But I would say for this purpose LFS (Linux from scratch) could may help:
https://linuxfromscratch.org/ 
 Sounds like what I’m looking for, thanks. 
 CC: @bitpunk.fm I'm not sure if this is your space but figured I'd tag you! 
 Obv 😀

https://i.nostr.build/8fkDGdwzLTDf2e9C.jpg 
 Awesome. I shall get myself a copy. Thank you ! 
 Me too! I thought I already had it but I do not 
 Just ordered a copy