Can someone explain why two sets of drivers are needed, one in the Linux kernel and one in X?
I understand that the device drivers are in the kernel, but what is the role of those in the xserver?
Does wayland require such drivers to run?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.
Sign up to join this communityLinux graphics support has been a heavily mutating thing for most of the life of the kernel. Initially, the kernel only talked to the graphics card for text mode purposes. Back then, X used its drivers to do everything, so it worked as a huge kernel-outside-the-kernel.
Later, with Direct Rendering Infrastructure (DRI), some of the code for accelerated graphics features moved kernel-side (called Direct Rendering Manager, DRM — nothing to do with digital rights management) to provide a consistent, abstracted interface to 3D acceleration features.
Currently, you don't need to have a kernel-side DRM module loaded. But if you don't have one, chances are your X session will fall back to software-rendered 3D which is considerably slower and power-hungrier than hardware 3D. Running glxinfo
will show info on this.
Wayland is a slightly different story. It sits between the kernel and client applications. With Wayland, the X server is another client application, displaying its root window as just another thing. Wayland takes on the duties of talking to the hardware (X talking to Wayland instead). Since the project is still heavily in development, there's no way to know where it'll end up, but the way I understand it is it still needs kernel support for 3D rendering.
It's obvious from the Wayland architecture diagrams, too: left is the current state of affairs for a modern X desktop, right is the proposed Wayland architecute. The Wayland compositor replaces the X Server as the thing that talks to the hardware, but it doesn't replace the kernel infrastructure — so you'd still need appropriate kernel support. In fact, given the aims of the project, more stuff should move to the kernel for even better abstraction. Wayland, like the X server, are still graphics hardware-dependent.
pnginfo
on the source file: the tEXt
chunk suggests it was done with Inkscape.