Revision 1.67 made acpithinkpad not take over screen backlight control and let inteldrm or some other driver handle it. This was done to support fine-grained levels of backlight control rather than the dozen steps that the native EC interface supports.
Unfortunately this has the drawback of the EC getting confused about what the backlight level actually is and it still tries to change the backlight automatically in response to Fn+F# keys or plug/unplug events. Notably if you have the laptop plugged in with a backlight value of something high, then unplug it and later lower it with xbacklight, when you plug it back in, the EC automatically adjusts the backlight up to that high value. I don't know how to tell the EC to stop adjusting the backlight automatically on power changes, so I would like to revert this change and go back to only having native EC-controlled backlight with xbacklight or wsconsctl. patrick@ confirmed that he can still change backlight values on the ThinkPad X395 with this backed out, even though part of the reason for this initial change was to help that machine. Index: acpithinkpad.c =================================================================== RCS file: /cvs/src/sys/dev/acpi/acpithinkpad.c,v retrieving revision 1.70 diff -u -p -u -p -r1.70 acpithinkpad.c --- acpithinkpad.c 6 Apr 2022 18:59:27 -0000 1.70 +++ acpithinkpad.c 17 Feb 2023 14:41:26 -0000 @@ -321,10 +321,8 @@ thinkpad_attach(struct device *parent, s wskbd_set_backlight = thinkpad_set_kbd_backlight; } - /* On version 2 and newer, let *drm or acpivout control brightness */ - if (sc->sc_hkey_version == THINKPAD_HKEY_VERSION1 && - (aml_evalinteger(sc->sc_acpi, sc->sc_devnode, "PBLG", - 0, NULL, &sc->sc_brightness) == 0)) { + if (aml_evalinteger(sc->sc_acpi, sc->sc_devnode, "PBLG", + 0, NULL, &sc->sc_brightness) == 0) { ws_get_param = thinkpad_get_param; ws_set_param = thinkpad_set_param; }