Taking Control of Low Level Resources

I must learn how the Linux GPU and network drivers work and how to communicate with them. The ones running on my machine obviously are specific to my hardware, but once I know one I can easily generalize to support other devices.

To access these drivers from userspace I will use syscalls, ioctls to be specific. I must understand how linux dispatches syscalls to the driver. I must also understand how an executable is built and how it is executed by the OS.

The goal is to make an executable that can be conveniently run from userspace that makes use of the drivers for my desired purposes such as network communication and graphics rendering. Once I know the entry points of the driver that are relevant to me I can proceed by tracing how these entry points are implemented, and possibly create my own minimal drivers that implement only the functionality I want, the way I want it. This will allow the production of a minimal OS-game that does not contain any bloat-code.

The linux driver for Intel GPUs is called i915. How do I find the entry points to the driver? Study the structure of the driver itself. Both the C codebase and the part of the linux image (have to locate it).

On the whole, I need to map out the linux binary image. Need to be able to locate components inside it, track flow through it. That’s critical. I must make a tool for this.