You are not logged in.

#1 2023-06-08 11:51:07

pCandKa
Member
Registered: 2023-06-08
Posts: 9

Lenovo notebook uses function keys to cause system shutdown

  1. Laptop model: Lenovo R7000P 2023
         

  2. Tested environment: arch KDE,arch GNOME,manjaro KDE minimal,ubuntu 22.04.2. All images of the latest version are installed.
       

  3. The tested linux kernel: arch linux 6.3.6,arch linux 6.1.32-lts,ubuntu linux 5.19.0-generic。
         

  4. Problem Description:

    • Press [fn + space](Adjust the brightness of the keyboard backlight).There's a chance the system will crash and shut down.

    • Press [fn + F5/F6](Adjust screen brightness).There's a chance the system will crash and shut down. When accessing the Bluetooth keyboard, the screen brightness will not be shut down when using the Bluetooth keyboard.

    • Press [fn + F10](Disable/enable the touchpad).The system has a small probability of crashing and shutting down.

    • This problem does not occur in windows11 or BIOS Settings.

    • All in all, when using some function keys on the keyboard, the system will crash and shut down (shut down instantly), maybe the hardware is too new to adapt well? Should I wait for a new kernel version? sad

         

  5. The following errors accompanied at boot time but not searched in the network can cause the above problems:

    6月 07 17:19:29 archlinux kernel: ACPI BIOS Error (bug): Could not resolve symbol [\_SB.PCI0.GP18.SATA], AE_NOT_FOUND (20220331/dswload2-162) 
    6月 07 17:19:29 archlinux kernel: fbcon: Taking over console 
    6月 07 17:19:29 archlinux kernel: ACPI Error: AE_NOT_FOUND, During name lookup/catalog (20220331/psobject-220) 
    6月 07 17:19:29 archlinux kernel: ACPI: Skipping parse of AML opcode: Scope (0x0010) 
    6月 07 17:19:29 archlinux kernel: ACPI BIOS Error (bug): Failure creating named object [\_SB.PCI0.GPP6.WLAN._S0W], AE_ALREADY_EXISTS (20220331/dswload2-326) 
    6月 07 17:19:29 archlinux kernel: ACPI Error: AE_ALREADY_EXISTS, During name lookup/catalog (20220331/psobject-220)
    and unknown chipset。

         

  6. The logs for the period before the crash shutdown looked like this, but I didn't find anything useful:

    6月 07 17:24:32 archlinux kgx[1981]: _gtk_css_corner_value_get_y: assertion 'corner->class == &GTK_CSS_VALUE_CORNER' failed
    6月 07 17:24:56 archlinux dbus-daemon[1159]: [session uid=1000 pid=1159] Activating service name='org.gnome.Nautilus' requested by ':1.11' (uid=1000 pid=1225>
    6月 07 17:24:56 archlinux nautilus[2362]: Connecting to org.freedesktop.Tracker3.Miner.Files
    6月 07 17:24:56 archlinux dbus-daemon[1159]: [session uid=1000 pid=1159] Successfully activated service 'org.gnome.Nautilus'
    6月 07 17:24:56 archlinux dbus-daemon[1159]: [session uid=1000 pid=1159] Activating service name='org.gnome.DiskUtility' requested by ':1.98' (uid=1000 pid=2>
    6月 07 17:24:56 archlinux gnome-shell[1225]: meta_window_set_stack_position_no_sync: assertion 'window->stack_position >= 0' failed
    6月 07 17:24:56 archlinux dbus-daemon[1159]: [session uid=1000 pid=1159] Successfully activated service 'org.gnome.DiskUtility'
    6月 07 17:25:23 archlinux systemd[1138]: Started VTE child process 2440 launched by kgx process 1981.
    6月 07 17:25:43 archlinux nautilus[2362]: Attempted to add a non-existent file to the view.
    6月 07 17:25:54 archlinux kgx[1981]: adw_tab_view_get_n_pages: assertion 'ADW_IS_TAB_VIEW (self)' failed

         

  7. The computer configuration is as follows:

    CPU:    AMD Ryzen 7 7840H w/ Radeon 780M Graphics 8 cores
    Main board:    Lenovo LNVNB161216
    RAM:    Hynix 16GB DDR5 5600MHZ ( 8GB + 8GB )
    GPU:    AMD Radeon(TM) 780M ( 512MB / Lenovo ),NVIDIA GeForce RTX 4060 Laptop GPU ( 8GB / Lenovo )
    Display screen:    NE160QDM-NYC [ BOE BOEOB38] ( 15.7 inch )
    Hard disk:    UMIS RPEYJI T24MKN2QWY ( 1024GB ),WD_BLACK SN750 SE 500GB ( 500GB )
    sound card:    AMD High Definition Audio Device,Realtek High Definition Audio,NVIDIA High Definition Audio
    Network card:    ReaItek PCIe GbE Family Controller,RZ616 Wi-Fi 6E 160MHz
  8. Replenishment:

Last edited by pCandKa (2023-06-08 12:04:55)

Offline

#2 2023-06-08 14:32:32

seth
Member
Registered: 2012-09-03
Posts: 61,632

Offline

#3 2023-06-23 15:14:47

anysets
Member
Registered: 2023-06-19
Posts: 1

Re: Lenovo notebook uses function keys to cause system shutdown

My device is Legion R7000P 2023 as well, and I have the same problem with you.

Have you found a solution to this problem?

Offline

#4 2023-10-03 08:02:15

SergeyZherebcov
Member
Registered: 2023-10-03
Posts: 1

Re: Lenovo notebook uses function keys to cause system shutdown

My device "Lenovo Legion Slim 5". Ubuntu 22.04.3 LTS, modificate "screen brightness control"(Fn+F5 or Fn+F6) causes the laptop to shut down every time. Other controlling buttons periodically as well (turning on/off the touchpad and others).

Offline

#5 2023-11-30 17:39:19

jdcsen
Member
Registered: 2023-11-30
Posts: 4

Re: Lenovo notebook uses function keys to cause system shutdown

Same, Lenovo Legion Slim 5. Shuts down and power light rapidly blinks blue for a few seconds if Fn+F5 is pressed (decrease brightness). Latest archlinux at the time of posting, running Sway, kernel 6.6.3-arch1-1.

product: 82Y9 (LENOVO_MT_82Y9_BU_idea_FM_Legion Slim 5 16APH8)
vendor: LENOVO
version: Legion Slim 5 16APH8

Offline

#6 2023-11-30 18:39:30

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

Run "sudo libinput debug-events", point a camera at the monitor (since you'll likely have no time to read that yourself) and press Fn+F5
For the camera, use tripod - eg. makeshift one by angling your phone between two heavy books: -\_

Offline

#7 2023-12-01 05:09:29

jdcsen
Member
Registered: 2023-11-30
Posts: 4

Re: Lenovo notebook uses function keys to cause system shutdown

The output is:

-event3   KEYBOARD_KEY            +5.287s	KEY_BRIGHTNESSDOWN (224) pressed
 event3   KEYBOARD_KEY            +5.287s	KEY_BRIGHTNESSDOWN (224) released
 event3   KEYBOARD_KEY            +6.897s	KEY_BRIGHTNESSDOWN (224) pressed
 event3   KEYBOARD_KEY            +6.897s	KEY_BRIGHTNESSDOWN (224) released

Also checked journalctl and there's nothing weird going on there. I have the same ACPI kernel messages as OP, though. Might be incidental.

Offline

#8 2023-12-01 08:41:28

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

ACPI errors are unfortuntely common and usually meaningless.
They *might* hint at this very problem, but are no major red flag per sē.

The key is unsuspicious and generates exactly the events you'd expect.
Does the system shut down if you change the backlight via software resp. the kernel interface directly?
https://wiki.archlinux.org/title/Backli … interfaces

Offline

#9 2023-12-01 09:43:16

jdcsen
Member
Registered: 2023-11-30
Posts: 4

Re: Lenovo notebook uses function keys to cause system shutdown

The light utility can change the level of the backlight with impunity, so I don't think it's related to the backlight itself. In order to get that to work, I had to add 'acpi_backlight=nvidia_wmi_ec' to the kernel parameters.

As such it's not a blocking issue for me, but it's definitely a weird and interesting one, so I'll try to keep providing whatever debug information people need.

Last edited by jdcsen (2023-12-01 10:06:23)

Offline

#10 2023-12-01 10:06:13

jdcsen
Member
Registered: 2023-11-30
Posts: 4

Re: Lenovo notebook uses function keys to cause system shutdown

Ok, interesting.

The issue only presents itself when connected to AC power. I've tested this ~10 times, and I can replicate the screen brightness (fn+f5/6) and touchpad enable/disable (fn+f10) cases when connected to AC power. When on battery, I can not replicate any cases. I was unable to replicate the keyboard backlight issue under any circumstance.

Also tried a BIOS update. No effect (other than nuking my bootloader because I did it from my Windows partition, thanks Lenovo.)

Last edited by jdcsen (2023-12-01 10:07:21)

Offline

#11 2023-12-01 15:23:05

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

1. Does the system shut down cleanly or does it simply power off
2. What doesyour /etc/systemd/logind.conf and what happens if you set it to ignore Power, Reboot Suspend and Hibernate Keys and the LidSwitch? (maybe the keyboard short circuits you one of those in addition)

Offline

#12 2023-12-03 12:28:39

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

Hello.
I have exactly the same problem. Even when on battery when fn + f5-12 is pressed system instantly shuts down, as if you pressed and held power button.

Offline

#13 2023-12-03 12:41:38

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

To you have to keep fn+fx pressed like the powerbutton for this to happen or does it occur "on the touch"?
HandlePowerKeyLongPress defaults to "ignore" so basically the only thing that can happen here is that the keyboard short circuits.
Do you get the same behavior when booting some live distro (or maybe even windows)?

Speaking of which: if there's a parallel windows, see the 3rd link below. Mandatory.
Disable it (it's NOT the BIOS setting!) and reboot windows and linux twice for voodo reasons.

Offline

#14 2023-12-03 12:59:22

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

In windows, everything works.
System shuts down as soon as any of fn + f4-12 is pressed, before key is released.

Offline

#15 2023-12-03 13:04:46

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

It is worth adding that the same behavior is observed when lid is closed.

Offline

#16 2023-12-03 13:30:33

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

Did you notice the very relevant comment about disabling windows fast-start?
It might be windows that's shutting down your system when pressing those keys…

Offline

#17 2023-12-03 14:18:57

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

My windows is on separate drive and not connected with Linux. Even when windows was removed the same behavior was observed.

Offline

#18 2023-12-03 14:32:57

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

That's completely irrelevant - the problem isn't "the drive" but the ACPI.
Disabling windows fast-start isn't optional, you cannot run one OS while another one is hibernating and expect things to work.

Even if it's eventually not the cause of this specific phenomenon (though we're very much in the ballpark of "shit that might happen") you've to disable it to prevent other side effects.

Offline

#19 2023-12-03 14:45:08

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

Ohh. I see. Apologies. Thank you for clarification.

Also, changing brightness by writing to nvidia in /sys/class/backlight works fine.

Last edited by mishach (2023-12-03 14:48:21)

Offline

#20 2023-12-03 21:57:08

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

No need to apologize.
Did you  disable fast-start and do the voodoo dance (this is only half-joking, by isolated anecdotes it even takes 3 reboots to "unconfuse" the BIOS)
And did that have any discernable impact on the issue at hand?

Offline

#21 2023-12-04 08:34:52

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

I turned off Fast-Start and d id voodoo dance, but it did not change anything. The system still shuts down.

Offline

#22 2023-12-04 11:33:11

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

Maybe the key is irrelevant, is it also a ryzen system?
https://wiki.archlinux.org/title/Ryzen#Random_reboots

Offline

#23 2023-12-04 12:31:35

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

yep, 7840h.

Offline

#24 2023-12-04 13:00:32

seth
Member
Registered: 2012-09-03
Posts: 61,632

Re: Lenovo notebook uses function keys to cause system shutdown

And do you get such MCEs and can you alter the voltage in your UEFI/BIOS?

Offline

#25 2023-12-04 13:05:58

mishach
Member
Registered: 2023-12-03
Posts: 13

Re: Lenovo notebook uses function keys to cause system shutdown

No mce messages and no voltage control in BIOS.
I suspected that it has something to do with ACPI BIOS tables. I compiled kernel with "ACPI_DEBUG y" and played with different debug settings to see if I can get detailed messages from fn key presses, but with no success and many parts are over my head.

Last edited by mishach (2023-12-04 13:16:07)

Offline

Board footer

Powered by FluxBB