Bug#401685: DirectFB should always use the vesa fb device on i386
package: rootskel-gtk
severity: normal
tags: patch
At boot time, on i386, "video=vesa" is passed to the kernel to start the
framebuffer device /dev/fb0 via vesafb driver (built into the kernel).
Later in the boot process, the vga16fb module is loaded, and a second
framebuffer device, /dev/fb1 is created, but sometimes, why i don't
know, the fb devices minor numbers end up swapped.
By default DirectFB accesses the first available fb device (/dev/fb0)
and as 4 bit modes provided by vga16 are not supported, it fails
initializing.
The attached patch takes care of adding to DirectFB configuration file
(/etc/directfbrc) a line indicating what fb device has to be used (the
one provided by vesafb).
A miniiso [1] including this patch is available for testing.
Attilio Fiandrotti
[1] https://debian.polito.it/downloads/mini_vesafbonly.iso
Index: src/lib/debian-installer.d/S61choose-fb-device-x86
===================================================================
--- src/lib/debian-installer.d/S61choose-fb-device-x86 (revisione 0)
+++ src/lib/debian-installer.d/S61choose-fb-device-x86 (revisione 0)
@@ -0,0 +1,7 @@
+#This script takes care of making DirectFB use the vesa fb device, as other
+#fb devices may exist
+
+if [ "$DEBIAN_FRONTEND" = gtk ] ; then
+ FB_INDEX=$(grep -i vesa /proc/fb | cut -d " " -f 1 )
+ echo "fbdev=/dev/fb"$FB_INDEX >> /etc/directfbrc
+fi
Index: src/lib/debian-installer.d/Makefile
===================================================================
--- src/lib/debian-installer.d/Makefile (revisione 43160)
+++ src/lib/debian-installer.d/Makefile (copia locale)
@@ -20,7 +20,8 @@
ifneq (,$(filter i386 amd64,$(DEB_HOST_ARCH_CPU)))
files += \
- S61mouse-support-x86
+ S61mouse-support-x86\
+ S61choose-fb-device-x86
endif
ifneq (,$(filter powerpc,$(DEB_HOST_ARCH_CPU)))
files += \
Reply to: