View previous topic :: View next topic |
Author |
Message |
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sat Aug 13, 2022 7:33 pm Post subject: [Solved] Black screen after Grub (Gentoo with systemd) |
|
|
Hello,
I have just made a fresh installation of Gentoo with a desktop profile (systemd), but on the first system boot, I have a black screen just after displaying the Grub menu.
The Grub menu is displayed, after validation to launch the kernel a message “Loading linux-5.15.59-gentoo” is displayed, but afterwards, nothing happens. It's just a black screen.
I found and consulted several threads on the Gentoo English forum. There is talk of enabling some options for Framebuffer support.
During kernel configuration, I did enable necessary options for Framebuffer support, as below.
Device Drivers →
Graphics support →
Frame buffer Devices →
<*>Support for frame buffer devices
<*> VGA 16-color graphics support
[*] VESA VGA graphics support
[*] EFI-based Framebuffer Support
<*> Single framebuffer support
Enabling support for Framebuffer and the Framebuffer support sub-options work fine for Gentoo with OpenRC but they don't work for Gentoo with Systemd.
The Linux kernel is installed from source. Kernel configuration is done manually. During installation, I followed the official Gentoo AMD64 Handbook documentation in English.
Here is some information that may be needed.
Boot mode is UEFI/EFI
Partitioning table is in GPT
I created three Partitions:
/dev/sda1 /boot
/dev/sda2 swap
/dev/sda3/
The profile is: [10] default/linux/amd64/17.1/desktop/systemd (stable) *
lspci: http://pastebin.fr/108640
lsusb: http://pastebin.fr/108641
/usr/src/linux/.config: http://pastebin.fr/108683
emerge --info: http://pastebin.fr/108638
/etc/portage/make.conf: http://pastebin.fr/108642
/boot/grub/grub.cfg: http://pastebin.fr/108644
/etc/fstab: http://pastebin.fr/108643
I am new to Gentoo. I don't know the Gentoo system very well.
I need help to find the cause and solve this blockage.
I'm sorry for my English, I used Google translator. I hope what I write is understandable.
Cordially
Last edited by kahraman on Sun Aug 14, 2022 10:25 am; edited 2 times in total |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sat Aug 13, 2022 8:12 pm Post subject: |
|
|
kahraman,
One of those framebuffer is required but its not sufficient.
When the kernel loads and starts the console, it just the kernel and optionally, the initrd/initramfs in memory.
The kernel uses the console before the initrd is used even, so it has to be able to do it on its own, the init system is not yet started.
Let me look at your kernel.
From lspci you have Sunrise Point chipset. Your kernel needs PINCTRL_SUNRISEPOINT. Not much at all works without that.
Your kernel has Code: | # CONFIG_PINCTRL is not set | which is a menu. Its inside that menu.
Code: | # CONFIG_X86_INTEL_LPSS is not set | is good to have too.
Takes some of the guesswork of of the kernel configuration.
The -k shows the drivers in use.
The -nn adds the PCI Vendor and Device IDs. The kernel drivers use those to bind to a device. e.g.
Code: | 0e:00.3 USB controller [0c03]: Advanced Micro Devices, Inc. [AMD] Matisse USB 3.0 Host Controller [1022:149c]
Subsystem: ASUSTeK Computer Inc. Device [1043:87c0]
Kernel driver in use: xhci_hcd |
Code: | CONFIG_SND_HDA=y
CONFIG_SND_HDA_INTEL=y | may be correct. The is now a SOF version too, so it might not.
That's the PCI end. You will also need one one or more CODECS but the are all off.
Code: | # CONFIG_SND_HDA_CODEC_REALTEK is not set
# CONFIG_SND_HDA_CODEC_ANALOG is not set
# CONFIG_SND_HDA_CODEC_SIGMATEL is not set
# CONFIG_SND_HDA_CODEC_VIA is not set
# CONFIG_SND_HDA_CODEC_HDMI is not set
# CONFIG_SND_HDA_CODEC_CIRRUS is not set
# CONFIG_SND_HDA_CODEC_CS8409 is not set
# CONFIG_SND_HDA_CODEC_CONEXANT is not set
# CONFIG_SND_HDA_CODEC_CA0110 is not set
# CONFIG_SND_HDA_CODEC_CA0132 is not set
# CONFIG_SND_HDA_CODEC_CMEDIA is not set
# CONFIG_SND_HDA_CODEC_SI3054 is not set | set them all to <*> until you know which one you need.
I'm sure that's not everything but it will help. It gets a lot easier once the console works. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sat Aug 13, 2022 8:58 pm Post subject: |
|
|
NeddySeagoon
Ok, thank you for taking the time to read and analyze my case. I will review and activate the points you specified. We'll see if it helps to get started or not. |
|
Back to top |
|
|
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sun Aug 14, 2022 12:24 am Post subject: |
|
|
I enabled PINCTRL and X86_INTEL_LPSS options, but still got black screen after Grub.
Here is the new kernel configuration file and detailed output from the lspci command :
/usr/src/linux/.config : http://pastebin.fr/108694
lspci -nnk : http://pastebin.fr/108695 |
|
Back to top |
|
|
MrSmoer n00b
Joined: 19 Jan 2022 Posts: 5
|
Posted: Sun Aug 14, 2022 2:09 am Post subject: |
|
|
Hi, I'm experiencing a similar, if not the same problem. It happened after a kernel upgrade from linux-5.15.52-gentoo to linux-5.15.59-gentoo. I verified that I only changed the new settings against those cache side effects.
My machine starts kde plasma afterwards, I think it does not display the framebuffer at all, and the starting of the services happens in the background, until the DE takes over.
If I press ctrl+alt+f2 to change to another tty, I will only get a black screen, but I can change back to plasma.
You could certainly try to use the old kernel version, it's just a few days older. Downgrading worked for me. (sys-kernel/gentoo-sources:5.15.52).
To install the older kernel just:
Code: | emerge -a sys-kernel/gentoo-sources:5.15.52
|
Then you can select the right kernel with the right line number (probably 1) or the name of it Code: | eselect kernel list
eselect kernel set linux-5.15.52-gentoo
|
This points your /usr/src/linux symlink to the older kernel directory.
It may be necessary to rebuild modules like the nvidia-drivers for the old kernel.
Code: | emerge --ask @module-rebuild |
From there you can just proceed as you did with configuring your kernel in the first place, or copy your .config from /usr/src/linux-5.15.59-gentoo/ to /usr/src/linux-5.15.52-gentoo/ and remove the options that were added with from version .52 to .59.
/usr/src/linux/scripts/diffconfig is a handy tool for comparing two .config-files. As it seems to me those were the added options, if you did not change something extraordinary, (but no guarantees):
Code: |
CC_HAS_RETURN_THUNK y
CPU_IBPB_ENTRY y
CPU_IBRS_ENTRY y
CPU_UNRET_ENTRY y
RETHUNK y
SPECULATION_MITIGATIONS y |
Then it's just the usual mounting of the boot partition, compile and install (don't forget the -j option to speed up the compile). For my system it would be:
Code: | mount /dev/sda1 /boot
make -j5 && make modules_install && make install | you may need to re-run grub-mkconfig, but the make install step should do it.
While booting, be sure to select the right kernel in grub-menu.
If you are interested, here is an article about upgrading your kernel, which is a pretty similar process, and it also explains the purpose of the steps: https://wiki.gentoo.org/wiki/Kernel/Upgrade |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Aug 14, 2022 9:13 am Post subject: |
|
|
kahraman,
Your new lspci shows both
Code: | # CONFIG_INTEL_UNCORE_FREQ_CONTROL is not set
# CONFIG_INTEL_PCH_THERMAL is not set | set.
They are both related to your chipset control.
Code: | # CONFIG_MISC_RTSX_PCI is not set | is the driver for your
Code: | 03:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTL8411B PCI Express Card Reader [10ec:5287] (rev 01)
Subsystem: Acer Incorporated [ALI] Acer Aspire E5-575G [1025:1094]
Kernel driver in use: rtsx_pci
Kernel modules: rtsx_pci | so you may as well have that now too.
Your sound card does indeed need Code: | 00:1f.3 Audio device [0403]: Intel Corporation Sunrise Point-LP HD Audio [8086:9d71] (rev 21)
Subsystem: Acer Incorporated [ALI] Acer Aspire E5-575G [1025:1094]
Kernel driver in use: snd_hda_intel
| Just as well you turned on the codecs now. It will save a kernel rebuild later.
Code: | 00:16.0 Communication controller [0780]: Intel Corporation Sunrise Point-LP CSME HECI #1 [8086:9d3a] (rev 21)
Subsystem: Acer Incorporated [ALI] Acer Aspire E5-575G [1025:115f]
Kernel driver in use: mei_me
Kernel modules: mei_me | This one is a bit controversial. MEI is Management Engine Interface. It's used in a corporate environment to take remote control of your system. You may not even know that its in use.
At the moment, you have Code: | # CONFIG_INTEL_MEI_ME is not set | Leave it that way unless you have a use for remote control of your system.
To save clutter and compile time, turn off all of
Code: | CONFIG_PCCARD=y
CONFIG_PCMCIA=y
CONFIG_PCMCIA_LOAD_CIS=y
CONFIG_CARDBUS=y
#
# PC-card bridges
#
CONFIG_YENTA=y
CONFIG_YENTA_O2=y
CONFIG_YENTA_RICOH=y
CONFIG_YENTA_TI=y
CONFIG_YENTA_ENE_TUNE=y
CONFIG_YENTA_TOSHIBA=y | They all predate USB2 and were popular in laptops about 20 years ago as they are fast compared to USB1.
You don't have any of that hardware.
I hope you are not editing the .config file with a text editor. All of the kernel configuration tools obey the Depends on: and Selects: directives.
One flip of an option in make menuconfig can flip as many as nine .config file settings. You would miss that and end up with an illegal kernel config.
If you are lucky, it won't build. If not, you get run time errors that nobody has ever seen before. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sun Aug 14, 2022 10:23 am Post subject: |
|
|
Hello,
MrSmoer,
Thank you very much for taking the time to read and try to help me. The problem is solved by changing option CONFIG_EXPERT=y to CONFIG_EXPERT=n
NeddySeagoon
Thank you very much for taking the time to read me and trying to help me.
I have taken note of all your advice and will do what is necessary.
Kernel modifications I do from a Debian live usb in chroot (https://wiki.gentoo.org/wiki/Chroot), with the traditional method :
cd /usr/src/linux ---> make menuconfig ---> ... ---> make && make module_install - --> make install ---> grub-mkconfig -o /boot/grub/grub.cfg
Best regards |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Aug 14, 2022 11:22 am Post subject: |
|
|
MrSmoer,
Code: | CC_HAS_RETURN_THUNK y
CPU_IBPB_ENTRY y
CPU_IBRS_ENTRY y
CPU_UNRET_ENTRY y
RETHUNK y
SPECULATION_MITIGATIONS y | These options are to mitigate against return speculation data leaks.
Are you really sure you don't need them?
Start reading at Retbleed. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sun Aug 14, 2022 12:40 pm Post subject: |
|
|
NeddySeagoon
For me, the options you specify are enabled by default.
CONFIG_CC_HAS_RETURN_THUNK=y
CONFIG_CPU_IBPB_ENTRY=y
CONFIG_CPU_IBRS_ENTRY=y
CONFIG_CPU_UNRET_ENTRY=y
CONFIG_RETHUNK=y
CONFIG_SPECULATION_MITIGATIONS=y
Do you recommend that I turn them off? |
|
Back to top |
|
|
MrSmoer n00b
Joined: 19 Jan 2022 Posts: 5
|
Posted: Sun Aug 14, 2022 1:35 pm Post subject: |
|
|
I do not recommend you to turn them off, I was recommending to downgrade the kernel, and as it seemed I had to add these options with my kernel upgrade from 5.15.52 to 5.15.59.
This upgrade from .52 to .59 introduced the problem that framebuffer stopped working for me, even though nothing (other than these new options) in my .config changed.
Framebuffer did work, when booting the old kernel for me, that's why I suggested to downgrade kernel.
During the upgrade with make olddefconfig I was promted with these new options and I can not find these options in the search of make menuconfig of .52, I concluded that they were added with this upgrade to .59, as I know that this vulnerability is fairly new.
I expected that your .config from the .59, which as you said has these options enabled by default, would not build properly with the .52 kernel. You would probably have to remove them to get a working .52 kernel.
If your .59 kernel framebuffer works now, I recommend you to enable these options.
I'm sorry for the miscommunication,
MrSmoer |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Aug 14, 2022 2:05 pm Post subject: |
|
|
kahraman,
They are a security feature that is missing in older kernels. They should be enabled if they exist.
When you use make oldconfig to move a .config file to a different (newer or older) kernel, it silently drops all the options that do not exist, sets unchanged option as the were for the original kernel and asks about anything new. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sun Aug 14, 2022 2:10 pm Post subject: |
|
|
MrSmoer
Thank you very much for your explanations. I understand better now. I apologize for the misinterpretation. |
|
Back to top |
|
|
pietinger Moderator
Joined: 17 Oct 2006 Posts: 4152 Location: Bavaria
|
Posted: Sun Aug 14, 2022 5:00 pm Post subject: |
|
|
MrSmoer wrote: | During the upgrade with make olddefconfig [...] |
If you really use "olddefconfig" then maybe this is the reason for your problems. I recommend always "make oldconfig". You dont want defaults changing your settings ...
MrSmoer wrote: | I concluded that they were added with this upgrade to .59, as I know that this vulnerability is fairly new. |
It was introduced with 5.15.58 and should have no impact to Framebuffer configuration. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Aug 14, 2022 5:03 pm Post subject: |
|
|
pietinger,
Good catch.
I read what I expected to see. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
kahraman n00b
Joined: 10 Mar 2021 Posts: 52
|
Posted: Sun Aug 14, 2022 8:11 pm Post subject: |
|
|
NeddySeagoon
I particularly thank you, not only for your analyzes and for your help but also for your qualities as a teacher. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Aug 14, 2022 8:35 pm Post subject: |
|
|
kahraman,
There is a proverb about that. Quote: | Give a Man a Fish, and You Feed Him for a Day. Teach a Man To Fish, and You Feed Him for a Lifetime |
I try to teach fishing without letting any students drown. :) _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
|