mirror of
https://salsa.debian.org/kernel-team/initramfs-tools.git
synced 2026-01-26 07:37:54 +00:00
Handle framebuffer_coreboot driver built as a module
The driver for coreboot firmware-initialized framebuffer can be built as a module. Debian kernels so far have it as built-in because they would not be probed automatically when built as a module. This is fixed now, likely with a patchset included in v6.9-rc1, so we might encounter it 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. Explicitly try to probe the module for break=top because it would not automatically probe there otherwise. Since it requires a driver for the "simple-framebuffer" device, add simpledrm and simplefb as its hidden dependencies. Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
This commit is contained in:
parent
d11ba241dc
commit
72899f8d89
@ -639,14 +639,20 @@ dep_add_modules()
|
||||
for device in /sys/bus/platform/drivers/efi-framebuffer/* \
|
||||
/sys/bus/platform/drivers/platform-framebuffer/* \
|
||||
/sys/bus/platform/drivers/simple-framebuffer/* \
|
||||
/sys/bus/platform/drivers/vesa-framebuffer/* \
|
||||
/sys/bus/coreboot/drivers/framebuffer/*; do
|
||||
/sys/bus/platform/drivers/vesa-framebuffer/*; do
|
||||
if [ -d "$device" ] && [ "$(basename "$device")" != "module" ]; then
|
||||
walk_graphics=no
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
for device in /sys/bus/coreboot/drivers/framebuffer/*; do
|
||||
if [ -d "$device" ] && [ "$(basename "$device")" != "module" ]; then
|
||||
modules="$modules framebuffer_coreboot"
|
||||
walk_graphics=no
|
||||
fi
|
||||
done
|
||||
|
||||
# It's possible that a generic framebuffer device works, but is taken
|
||||
# over by a more capable driver and no longer available in /sys. We
|
||||
# have no reliable consistent way to detect that, so apply heuristics.
|
||||
@ -850,7 +856,7 @@ auto_add_modules()
|
||||
modules="$modules =drivers/usb/storage"
|
||||
;;
|
||||
fb)
|
||||
modules="$modules simpledrm simplefb"
|
||||
modules="$modules simpledrm simplefb framebuffer_coreboot"
|
||||
# For machines that don't have a generic framebuffer device.
|
||||
modules="$modules rockchipdrm pwm-cros-ec pwm_bl pwm-rockchip panel-simple"
|
||||
modules="$modules analogix-anx6345 pwm-sun4i sun4i-drm sun8i-mixer panel-edp"
|
||||
@ -942,6 +948,10 @@ hidden_dep_add_modules()
|
||||
# DP devices which don't have devlinks
|
||||
echo pmic_glink_altmode gpio_sbu_mux qrtr
|
||||
;;
|
||||
framebuffer_coreboot)
|
||||
# Either one, we don't know which is a module
|
||||
echo simpledrm simplefb
|
||||
;;
|
||||
esac
|
||||
done
|
||||
)
|
||||
|
||||
@ -103,7 +103,7 @@ maybe_break()
|
||||
/sbin/modprobe ${opts} -a i8042 atkbd ehci-pci ehci-orion \
|
||||
ehci-hcd ohci-hcd ohci-pci uhci-hcd usbhid xhci \
|
||||
xhci-pci xhci-hcd
|
||||
/sbin/modprobe ${opts} -a simpledrm simplefb
|
||||
/sbin/modprobe ${opts} -a simpledrm simplefb framebuffer_coreboot
|
||||
sleep 2
|
||||
for modalias in /sys/bus/hid/devices/*/modalias; do
|
||||
if [ -f "${modalias}" ]; then
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user