Skip to content

Commit 7725a2d

Browse files
flukejonesij-intel
authored andcommitted
platform/x86: asus-armoury: add screen auto-brightness toggle
Add screen_auto_brightness toggle supported on some laptops. Signed-off-by: Denis Benato <denis.benato@linux.dev> Signed-off-by: Luke D. Jones <luke@ljones.dev> Reviewed-by: Mario Limonciello <mario.limonciello@amd.com> Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Link: https://patch.msgid.link/20251102215319.3126879-7-denis.benato@linux.dev Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
1 parent 9c7dacf commit 7725a2d

2 files changed

Lines changed: 5 additions & 0 deletions

File tree

drivers/platform/x86/asus-armoury.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -707,6 +707,9 @@ ASUS_ATTR_GROUP_BOOL_RW(panel_od, "panel_overdrive", ASUS_WMI_DEVID_PANEL_OD,
707707
"Set the panel refresh overdrive");
708708
ASUS_ATTR_GROUP_BOOL_RW(panel_hd_mode, "panel_hd_mode", ASUS_WMI_DEVID_PANEL_HD,
709709
"Set the panel HD mode to UHD<0> or FHD<1>");
710+
ASUS_ATTR_GROUP_BOOL_RW(screen_auto_brightness, "screen_auto_brightness",
711+
ASUS_WMI_DEVID_SCREEN_AUTO_BRIGHTNESS,
712+
"Set the panel brightness to Off<0> or On<1>");
710713
ASUS_ATTR_GROUP_BOOL_RO(egpu_connected, "egpu_connected", ASUS_WMI_DEVID_EGPU_CONNECTED,
711714
"Show the eGPU connection status");
712715

@@ -722,6 +725,7 @@ static const struct asus_attr_group armoury_attr_groups[] = {
722725
{ &mcu_powersave_attr_group, ASUS_WMI_DEVID_MCU_POWERSAVE },
723726
{ &panel_od_attr_group, ASUS_WMI_DEVID_PANEL_OD },
724727
{ &panel_hd_mode_attr_group, ASUS_WMI_DEVID_PANEL_HD },
728+
{ &screen_auto_brightness_attr_group, ASUS_WMI_DEVID_SCREEN_AUTO_BRIGHTNESS },
725729
};
726730

727731
static int asus_fw_attr_add(void)

include/linux/platform_data/x86/asus-wmi.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@
8282
#define ASUS_WMI_DEVID_LID_FLIP_ROG 0x00060077
8383
#define ASUS_WMI_DEVID_MINI_LED_MODE 0x0005001E
8484
#define ASUS_WMI_DEVID_MINI_LED_MODE2 0x0005002E
85+
#define ASUS_WMI_DEVID_SCREEN_AUTO_BRIGHTNESS 0x0005002A
8586

8687
/* Storage */
8788
#define ASUS_WMI_DEVID_CARDREADER 0x00080013

0 commit comments

Comments
 (0)