[opensuse-kernel] how to control/modify early framebuffer & resolution on UEFI-booted kernel 3.19.2?
I'll start here -- because it is opensuse and kernel-related -- but don't know if this is the ultimately right place to ask. I'm working on setting console video resolution on an opensuse 13.2 server. I want 'hi-res' (to the extent possible), text-only display from grub menu, through completion of linux boot. My eventual questions are (1) why is 'efifb' used? it's supposed to be Mac-only (2) how do I change 'efifb' resolution? (3) can nouveaufb replace efifb completely? I have installed uname -r 3.19.2-3.gd8856ce-default It's booting UEFI dmesg | grep "efi: EFI" [ 0.000000] efi: EFI v2.31 by American Megatrends The mobo/cpu is SuperMicro + Intel Xeon Haswell v3. The video card is lspci -vnn | grep -i vga 02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119 [GeForce GT 610] [10de:104a] (rev a1) (prog-if 00 [VGA controller]) 'nouveau' driver is in use rpm -qa | grep nouveau libdrm_nouveau2-2.4.58-1.1.x86_64 hwinfo --gfxcard | egrep "[ ]*Model:|[ ]*Driver" Model: "nVidia GF119 [GeForce GT 610]" Driver: "nouveau" Driver Modules: "drm" Driver Info #0: Driver Status: nouveau is active Driver Activation Cmd: "modprobe nouveau" The boot sequence display starts with 'efifb', @ availble (low) res dmesg | egrep "efifb:|fb[0-9]:" | grep -vi "command line" [ 2.936016] efifb: probing for efifb [ 2.939612] efifb: framebuffer at 0xd1000000, mapped to 0xffffc9000b800000, using 1876k, total 1875k [ 2.948732] efifb: mode is 800x600x32, linelength=3200, pages=1 [ 2.954648] efifb: scrolling: redraw [ 2.958223] efifb: Truecolor: size=8:8:8:8, shift=24:16:8:0 [ 2.975291] fb0: EFI VGA frame buffer device [ 18.366826] nouveau 0000:02:00.0: fb0: nouveaufb frame buffer device at the last line ^^ it then hands-off to 'nouveaufb' dmesg | grep nouveaufb [ 26.934467] fb: switching to nouveaufb from EFI VGA [ 27.530632] fbcon: nouveaufb (fb0) is primary device [ 27.612790] nouveau 0000:02:00.0: fb0: nouveaufb frame buffer device In GRUB2 config I am able to set the video resolution (in my case, to 1920x1080) only AFTER the handoff to 'nouveaudb' Given grep . /sys/class/drm/card*-*/modes | head -n 3 /sys/class/drm/card0-HDMI-A-1/modes:1920x1080 /sys/class/drm/card0-HDMI-A-1/modes:1680x1050 /sys/class/drm/card0-HDMI-A-1/modes:1280x1024 setting GRUB_CMDLINE_LINUX="... video=HDMI-A-1:1920x1080@60" works as intended. But, from grub menu display up until that point, i.e. prior to the fb handoff, the display resolution used by 'efifb' is currently limited to 800x600. Available EFI video modes are grub> videoinfo List of supported video modes: Legend: mask/position=red/green/blue/reserved ... Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 According to https://www.kernel.org/doc/Documentation/fb/efifb.txt "... efifb is only for EFI booted Intel Macs. ..." This is not a Mac, so why is the 'efifb' being used? Since this is post-grub2-menu, it seems something in the opensuse install/setup is possibly misidentifying the hardware. Randomly trying each of video=efifb:0x001 video=efifb:1024x768 video=efifb:1024x768x32 to GRUB_CMDLINE_LINUX="... video=efifb:<...> video=HDMI-A-1:1920x1080@60" had no effect. 'nouveaufb' clearly has the mode support I need. Is it possible to get the efi-booted kernel to use it @ early display, immediately post-grub2-menu? LT -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
At Fri, 27 Mar 2015 11:22:01 -0700, lyndat3@your-mail.com wrote:
I'll start here -- because it is opensuse and kernel-related -- but don't know if this is the ultimately right place to ask.
I'm working on setting console video resolution on an opensuse 13.2 server.
I want 'hi-res' (to the extent possible), text-only display from grub menu, through completion of linux boot.
My eventual questions are
(1) why is 'efifb' used? it's supposed to be Mac-only
No. It's a generic fb used for EFI boot.
(2) how do I change 'efifb' resolution?
Not easy, and unlikely working. Forget about it. efifb simply takes over the resolution from the EFI boot loader.
(3) can nouveaufb replace efifb completely?
Only when you disable efifb in the kernel build configuration. then you'll have a blank screen for certain time from the boot up until nouveau fb gets initialized.
In GRUB2 config I am able to set the video resolution (in my case, to 1920x1080) only AFTER the handoff to 'nouveaudb'
Given
grep . /sys/class/drm/card*-*/modes | head -n 3 /sys/class/drm/card0-HDMI-A-1/modes:1920x1080 /sys/class/drm/card0-HDMI-A-1/modes:1680x1050 /sys/class/drm/card0-HDMI-A-1/modes:1280x1024
setting
GRUB_CMDLINE_LINUX="... video=HDMI-A-1:1920x1080@60"
works as intended.
This is a boot option for kernel. It's no configuration of grub2 itself.
But, from grub menu display up until that point, i.e. prior to the fb handoff, the display resolution used by 'efifb' is currently limited to 800x600.
Available EFI video modes are
grub> videoinfo List of supported video modes: Legend: mask/position=red/green/blue/reserved ... Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
According to
https://www.kernel.org/doc/Documentation/fb/efifb.txt
"... efifb is only for EFI booted Intel Macs. ..."
This is not a Mac, so why is the 'efifb' being used? Since this is post-grub2-menu, it seems something in the opensuse install/setup is possibly misidentifying the hardware.
Too old documentation, scratch that. Takashi -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
(1) why is 'efifb' used? it's supposed to be Mac-only
No. It's a generic fb used for EFI boot. ...
Too old documentation, scratch that.
Sigh. Thanks.
(2) how do I change 'efifb' resolution?
Not easy, and unlikely working. Forget about it. efifb simply takes over the resolution from the EFI boot loader.
I conflated the two. I understand now that they're separate items.
(3) can nouveaufb replace efifb completely?
Only when you disable efifb in the kernel build configuration. then you'll have a blank screen for certain time from the boot up until nouveau fb gets initialized.
Okay. Not a useful state.
GRUB_CMDLINE_LINUX="... video=HDMI-A-1:1920x1080@60" works as intended.
This is a boot option for kernel. It's no configuration of grub2 itself.
Point taken.
Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
The result here is insensitive to GRUB_GFXMODE, despite what I see wih 'videoinfo'. Then, consistent with 800x600 as a fallback. All clear, now. My boot-console's close enough to my goal now. And, I end up at login prompt in reasonable type size and full screen real-estate. Makes emergency mode more manageable. Add to that serial console, and I'm all set. Thanks. Next, Xen ... LT -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
В Fri, 27 Mar 2015 21:49:21 +0100
Takashi Iwai
But, from grub menu display up until that point, i.e. prior to the fb handoff, the display resolution used by 'efifb' is currently limited to 800x600.
Available EFI video modes are
grub> videoinfo List of supported video modes: Legend: mask/position=red/green/blue/reserved ... Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
I'd still expect it to select 1024x768 here; normally grub prefers the best possible resolution if told to autodetect. It may make sense to open bug report to investigate why it is stuck on 800x600. -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
At Sat, 28 Mar 2015 07:57:01 +0300, Andrei Borzenkov wrote:
В Fri, 27 Mar 2015 21:49:21 +0100 Takashi Iwai
пишет: But, from grub menu display up until that point, i.e. prior to the fb handoff, the display resolution used by 'efifb' is currently limited to 800x600.
Available EFI video modes are
grub> videoinfo List of supported video modes: Legend: mask/position=red/green/blue/reserved ... Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
I'd still expect it to select 1024x768 here; normally grub prefers the best possible resolution if told to autodetect. It may make sense to open bug report to investigate why it is stuck on 800x600.
This must be a fallback when the BIOS firmware doesn't give the preferred resolution. 800x600 is chosen because of safety reason. So, blame BIOS instead :) Takashi -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
В Sat, 28 Mar 2015 08:42:47 +0100
Takashi Iwai
At Sat, 28 Mar 2015 07:57:01 +0300, Andrei Borzenkov wrote:
В Fri, 27 Mar 2015 21:49:21 +0100 Takashi Iwai
пишет: But, from grub menu display up until that point, i.e. prior to the fb handoff, the display resolution used by 'efifb' is currently limited to 800x600.
Available EFI video modes are
grub> videoinfo List of supported video modes: Legend: mask/position=red/green/blue/reserved ... Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
I'd still expect it to select 1024x768 here; normally grub prefers the best possible resolution if told to autodetect. It may make sense to open bug report to investigate why it is stuck on 800x600.
This must be a fallback when the BIOS firmware doesn't give the preferred resolution. 800x600 is chosen because of safety reason.
Nope, grub does not fall back to 800x600 on its own. If requested resolution cannot be set, it would fail to load gfxterm. This could happen if resolution is not explicitly requested and firmware returns EDID with preferred resolution 800x600 or does not return anything at all - then grub would use 800x600 indeed.
So, blame BIOS instead :)
That's right, at the end it is firmware that gives us information. -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
At Sat, 28 Mar 2015 12:25:04 +0300, Andrei Borzenkov wrote:
В Sat, 28 Mar 2015 08:42:47 +0100 Takashi Iwai
пишет: At Sat, 28 Mar 2015 07:57:01 +0300, Andrei Borzenkov wrote:
В Fri, 27 Mar 2015 21:49:21 +0100 Takashi Iwai
пишет: But, from grub menu display up until that point, i.e. prior to the fb handoff, the display resolution used by 'efifb' is currently limited to 800x600.
Available EFI video modes are
grub> videoinfo List of supported video modes: Legend: mask/position=red/green/blue/reserved ... Adapter 'EFI GOP Driver': * 0x000 800 x 600 x 32 (3200) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24 0x001 1024 x 768 x 32 (4096) Direct color, mask: 8/8/8/8/ pos: 16/8/0/24
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
I'd still expect it to select 1024x768 here; normally grub prefers the best possible resolution if told to autodetect. It may make sense to open bug report to investigate why it is stuck on 800x600.
This must be a fallback when the BIOS firmware doesn't give the preferred resolution. 800x600 is chosen because of safety reason.
Nope, grub does not fall back to 800x600 on its own. If requested resolution cannot be set, it would fail to load gfxterm.
This could happen if resolution is not explicitly requested and firmware returns EDID with preferred resolution 800x600 or does not return anything at all - then grub would use 800x600 indeed.
I meant this behavior of efi_gop as fallback. Takashi -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
So, the problem is here. If the EFI firmware can't support your preferred resolution, efifb also can't use it, obviously. Check more whether the resolution is really available. If yes, you can specify it in /etc/default/grub, e.g. via GRUB_GFXMODE. As default, grub2 tries to pick up the native resolution, and use 800x600 as a fallback.
I've not managed to determine how to 'check more'. Of course I *see* the result -- output in 800x600 only. Any guidance on a specific diagnostic would help. LT -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org
participants (3)
-
Andrei Borzenkov
-
lyndat3@your-mail.com
-
Takashi Iwai