Failed to start Load/Save Screen Backlight Brightness of amdgpu_bl1

Ok I managed to solve the problem by myself
I was looking for what was causing the problem that I found this:

sudo systemctl status systemd-backlight@backlight:amdgpu_bl0

● systemd-backlight@backlight:amdgpu_bl0.service - Load/Save Screen Backlight Brightness of backlight:amdgpu_bl0
     Loaded: loaded (/usr/lib/systemd/system/systemd-backlight@.service; static)
     Active: failed (Result: exit-code) since Thu 2020-12-10 19:22:42 +0330; 23s ago
       Docs: man:systemd-backlight@.service(8)
    Process: 956 ExecStart=/usr/lib/systemd/systemd-backlight load backlight:amdgpu_bl0 (code=exited, status=1/FAILURE)
   Main PID: 956 (code=exited, status=1/FAILURE)

Dec 10 19:22:42 Mtn-Lap systemd[1]: Starting Load/Save Screen Backlight Brightness of backlight:amdgpu_bl0...
Dec 10 19:22:42 Mtn-Lap systemd-backlight[956]: amdgpu_bl0: Failed to write system 'brightness' attribute: No such device or address
Dec 10 19:22:42 Mtn-Lap systemd[1]: systemd-backlight@backlight:amdgpu_bl0.service: Main process exited, code=exited, status=1/FAILURE
Dec 10 19:22:42 Mtn-Lap systemd[1]: systemd-backlight@backlight:amdgpu_bl0.service: Failed with result 'exit-code'.
Dec 10 19:22:42 Mtn-Lap systemd[1]: Failed to start Load/Save Screen Backlight Brightness of backlight:amdgpu_bl0.

Ok so I simply tried to run that manually

sudo systemctl start systemd-backlight@backlight:amdgpu_bl0

And that’s it!!!
It solved the problem
But I had to create a systemd service so that it runs on every boot
I searched a lot and found these two links:

  1. How do I make a systemd service and enable it?
  2. Cannot restore backlight on AMD VGA after systemd upgrade / Kernel & Hardware / Arch Linux Forums

Then I tried to combine them and I wrote this service:

sudo nano /etc/systemd/system/startup-brightness.service

[Unit]
Description= Fixing screen brightness on boot

[Service]
Type=oneshot
ExecStart=/opt/fix-brightness.sh

[Install]
WantedBy=systemd-backlight@backlight:amdgpu_bl0.service

And then:

sudo systemctl enable --now startup-brightness

The problem with saving brightness is now SOLVED
But still I see the error on boot screen
That’s the only problem left
I have three questions:

  1. How can I edit that service so that I don’t need to write another script to just run that one line of code
  2. Why didn’t the systemd do that itself?
  3. If the problem is solved, then why do I still see that error on boot screen? Is that because of the line
    WantedBy=systemd-backlight@backlight:amdgpu_bl0.service ?
1 Like