Messages in this thread | | | Date | Tue, 9 Aug 2022 12:50:31 +0200 | From | Pavel Machek <> | Subject | Re: [PATCH v3 1/6] asus-wmi: Implement TUF laptop keyboard RGB control |
| |
Hi!
> Adds support for TUF laptop RGB control via the multicolor LED API. > > As this is the bas for adjusting only the RGB values, it sets the > default mode of the keyboard to static since there is no way to read > any existing settings from the device. These defaults overwrite the > booted state of the keyboard when the module is loaded.
> + if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_TUF_RGB_MODE)) { > + struct mc_subled *mc_led_info = asus->keyboard_rgb_mode.subled_info; > + struct led_classdev_mc *mc_cdev = &asus->keyboard_rgb_mode.dev; > + struct device *dev = &asus->platform_device->dev; > + u8 led_brightness = 255; > + > + /* > + * asus::kbd_backlight still controls a base 3-level backlight and when > + * it is on 0, the RGB is not visible at all. RGB should be treated as > + * an additional step. > + */
Ouch. Lets not do that? If rgb interface is available, hide the 3 level one, or something.
> + mc_cdev->led_cdev.name = "asus::multicolour::kbd_backlight";
Make this "rgb:kbd_backlight" or "inputX:rgb:kbd_backligh" and document it in Documentation/leds/well-known-leds.txt.
Thanks and best regards, Pavel -- People of Russia, stop Putin before his war on Ukraine escalates. [unhandled content-type:application/pgp-signature] | |