[SOLVED] Laptop backlight dims to zero on boot with kernel 5.14.0
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Laptop backlight dims to zero on boot with kernel 5.14.0
I am going to assume this is some how caused by kernel 5.14.0 since the problem only started occurring after that upgrade. The laptop I have is an nvidia/AMD vega graphics hybrid, the problem is during boot once amdgpudrmfb takes over the backlight of the laptop drops to 0 and is barely visible. As a workaround for now I added this to rc.local
This will bring the backlight back up to max, but this was not necessary before 5.14.0. Any ideas on how to fix this are appreciated. Here is some dmesg output. I didn't find anything useful in it though
Code:
[ 6.324280] [drm] amdgpu kernel modesetting enabled.
[ 6.330234] amdgpu: Virtual CRAT table created for CPU
[ 6.331078] amdgpu: Topology: Add CPU node
[ 6.331926] fb0: switching to amdgpudrmfb from EFI VGA
[ 6.332815] amdgpu 0000:06:00.0: vgaarb: deactivate vga console
[ 6.332839] amdgpu 0000:06:00.0: enabling device (0006 -> 0007)
[ 6.332884] amdgpu 0000:06:00.0: amdgpu: Trusted Memory Zone (TMZ) feature enabled
[ 6.334177] amdgpu 0000:06:00.0: amdgpu: Fetched VBIOS from VFCT
[ 6.334180] amdgpu: ATOM BIOS: 113-RENOIR-026
[ 6.334623] amdgpu 0000:06:00.0: amdgpu: VRAM: 512M 0x000000F400000000 - 0x000000F41FFFFFFF (512M used)
[ 6.334626] amdgpu 0000:06:00.0: amdgpu: GART: 1024M 0x0000000000000000 - 0x000000003FFFFFFF
[ 6.334628] amdgpu 0000:06:00.0: amdgpu: AGP: 267419648M 0x000000F800000000 - 0x0000FFFFFFFFFFFF
[ 6.334670] [drm] amdgpu: 512M of VRAM memory ready
[ 6.334672] [drm] amdgpu: 3072M of GTT memory ready.
[ 6.335443] amdgpu 0000:06:00.0: amdgpu: PSP runtime database doesn't exist
[ 7.040261] amdgpu 0000:06:00.0: amdgpu: RAS: optional ras ta ucode is not available
[ 7.047797] amdgpu 0000:06:00.0: amdgpu: RAP: optional rap ta ucode is not available
[ 7.047808] amdgpu 0000:06:00.0: amdgpu: SECUREDISPLAY: securedisplay ta ucode is not available
[ 7.048940] amdgpu 0000:06:00.0: amdgpu: SMU is initialized successfully!
[ 7.159638] kfd kfd: amdgpu: Allocated 3969056 bytes on gart
[ 7.173434] amdgpu: HMM registered 512MB device memory
[ 7.173493] amdgpu: SRAT table not found
[ 7.173498] amdgpu: Virtual CRAT table created for GPU
[ 7.173819] amdgpu: Topology: Add dGPU node [0x1636:0x1002]
[ 7.173834] kfd kfd: amdgpu: added device 1002:1636
[ 7.173845] amdgpu 0000:06:00.0: amdgpu: SE 1, SH per SE 2, CU per SH 18, active_cu_number 26
[ 7.176896] fbcon: amdgpu (fb0) is primary device
[ 7.218403] amdgpu 0000:06:00.0: [drm] fb0: amdgpu frame buffer device
[ 7.223883] amdgpu 0000:06:00.0: amdgpu: ring gfx uses VM inv eng 0 on hub 0
[ 7.223907] amdgpu 0000:06:00.0: amdgpu: ring comp_1.0.0 uses VM inv eng 1 on hub 0
[ 7.223929] amdgpu 0000:06:00.0: amdgpu: ring comp_1.1.0 uses VM inv eng 4 on hub 0
[ 7.223946] amdgpu 0000:06:00.0: amdgpu: ring comp_1.2.0 uses VM inv eng 5 on hub 0
[ 7.223963] amdgpu 0000:06:00.0: amdgpu: ring comp_1.3.0 uses VM inv eng 6 on hub 0
[ 7.223980] amdgpu 0000:06:00.0: amdgpu: ring comp_1.0.1 uses VM inv eng 7 on hub 0
[ 7.223997] amdgpu 0000:06:00.0: amdgpu: ring comp_1.1.1 uses VM inv eng 8 on hub 0
[ 7.224014] amdgpu 0000:06:00.0: amdgpu: ring comp_1.2.1 uses VM inv eng 9 on hub 0
[ 7.224031] amdgpu 0000:06:00.0: amdgpu: ring comp_1.3.1 uses VM inv eng 10 on hub 0
[ 7.224048] amdgpu 0000:06:00.0: amdgpu: ring kiq_2.1.0 uses VM inv eng 11 on hub 0
[ 7.224065] amdgpu 0000:06:00.0: amdgpu: ring sdma0 uses VM inv eng 0 on hub 1
[ 7.224089] amdgpu 0000:06:00.0: amdgpu: ring vcn_dec uses VM inv eng 1 on hub 1
[ 7.224106] amdgpu 0000:06:00.0: amdgpu: ring vcn_enc0 uses VM inv eng 4 on hub 1
[ 7.224123] amdgpu 0000:06:00.0: amdgpu: ring vcn_enc1 uses VM inv eng 5 on hub 1
[ 7.224140] amdgpu 0000:06:00.0: amdgpu: ring jpeg_dec uses VM inv eng 6 on hub 1
[ 7.225750] [drm] Initialized amdgpu 3.42.0 20150101 for 0000:06:00.0 on minor 1
This started happening on my AMD laptop (with AMD GPU) with the 5.14.0 update as well. It returns to normal brightness after resuming from suspend. Funny enough, xbacklight does not recognize any outputs with the backlight property on this machine, but I can control the brightness with xrander --brightness. The xrander command uses the dimmed level as the baseline and won't restore full brightness until the machine resumes from suspend.
For my intel backlight I use this /etc/udev/rules.d/ file
Code:
# 81-backlight.rules:
#
# Set the initial backlight level.
# When present, use the 'acpi_video0' control in preference to
# the vendor 'intel_backlight' control.
#
SUBSYSTEM!="backlight", GOTO="backlight_end"
ACTION!="add", GOTO="backlight_end"
KERNEL=="intel_backlight", TEST!="/sys/class/backlight/acpi_video0/brightness", ATTR{brightness}="364"
KERNEL=="acpi_video0", ATTR{brightness}="39"
LABEL="backlight_end"
You could modify it to suit your amd hardware.
Still doesn't explain why yours is being set to 0 all of a sudden, but it's a little less crude than a rc.local hack.
For my intel backlight I use this /etc/udev/rules.d/ file
Code:
# 81-backlight.rules:
#
# Set the initial backlight level.
# When present, use the 'acpi_video0' control in preference to
# the vendor 'intel_backlight' control.
#
SUBSYSTEM!="backlight", GOTO="backlight_end"
ACTION!="add", GOTO="backlight_end"
KERNEL=="intel_backlight", TEST!="/sys/class/backlight/acpi_video0/brightness", ATTR{brightness}="364"
KERNEL=="acpi_video0", ATTR{brightness}="39"
LABEL="backlight_end"
You could modify it to suit your amd hardware.
Still doesn't explain why yours is being set to 0 all of a sudden, but it's a little less crude than a rc.local hack.
Just tested on my laptop. They fn+f11/f12 keys are working in mate,kde, and xfce. In non X they don't function, but I had never tried them out side of X before so that may be normal.
Just tested on my laptop. They fn+f11/f12 keys are working in mate,kde, and xfce. In non X they don't function, but I had never tried them out side of X before so that may be normal.
In KDE, no matter if my brightness is 0% or 100%, the brightness is still full
Well spoke too soon. Like you, changing brightness with keyboarding was not working on battery, and the laptop was not dimming on idle. Went back to the udev rule route. Still all fixed though
For me it started with kernel 5.14. Not sure what commit may have caused this, but the uvdev rule posted above fixes the issue for me.
I'm running Void on an Ideapad Flex 5 14ARE05, but experiencing the same thing. Issue introduced with the recent upgrade from the 5.13.9 kernel to the 5.14.8 kernel. amdgpu.backlight=1 kernel param in GRUB CMD restores full screen brightness, including in the pre-boot environment and my disk encryption password prompt, however, it breaks the functionality of the screen backlight keyboard function keys (using acpilight; the brightness - key simply turns off the display, and the brightness + key restores it to 100% full brightness with no steps inbetween; my Fn keys are mapped to exec:xbacklight -inc 10 and exec:xbacklight -dec 10; using JWM, no DE). For the time being I am using the udev rule ITT as a workaround. Screen backlight keyboard function keys work properly with correct stepping, and I get full screen brightness once the kernel has loaded, but it it is still set to its lowest brightness level during my disk encryption password prompt and the first couple lines of the boot sequence. Annoying but tolerable. On the bright side (pun semi-intended), battery life on this kernel is noticeably better.
Last edited by thunderweasel; 09-30-2021 at 09:00 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.