Skip to content

Handle simple-framebuffer drivers and framebuffer_coreboot built as modules

Recent Debian kernels have the simplefb driver built-in on a few architectures, except in cloud flavours. It handles simple-framebuffer devices registered from elsewhere: possibly in a device-tree fragment, or from another driver like framebuffer_coreboot, or via SYSFB_SIMPLEFB. The more modern alternative to it is simpledrm which also handles the same simple-framebuffer devices.

We haven't switched to simpledrm, but if we do it's possible we will want it to be a module, since it depends on the drm subsystem and would require that to be built-in otherwise. Regardless of what we choose for Debian kernels, it's still possible for custom-built kernels to have either/both of simplefb and simpledrm as modules instead of built-in.

Include these modules in initramfs unconditionally when MODULES=dep. For MODULES=most, add the two drivers to the framebuffer modules list.

When MODULES=dep and these drives are (probed) modules, our check for platform framebuffers always finds a module directory in the driver's sysfs directory and incorrectly skips handling graphics modules, ignore the false positive.

Unfortunately, these drivers sometimes do not get probed automatically. One such case is efifb with SYSFB_SIMPLEFB=y, which is quite important. Add a init-top script that tries to probe simpledrm, with a fallback to simplefb.

Furthermore, we might encounter framebuffer_coreboot as a module either in Debian or with custom-built kernels. For MODULES=dep, check for the coreboot framebuffer in a different block from other platform drivers, and include the framebuffer_coreboot module if we find the device. For MODULES=most, add driver to the framebuffer modules list. Since it requires a driver for the simple-framebuffer device, add simpledrm and simplefb as its hidden dependencies.

Merge request reports

Loading