Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

platform/x86: asus-wmi: deprecate bios features

With the existence of the asus-armoury module the attributes no longer
need to live under the /sys/devices/platform/asus-nb-wmi/ path.

Deprecate all those that were implemented in asus-bioscfg with the goal
of removing them fully in the next LTS cycle.

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>
Link: https://patch.msgid.link/20251102215319.3126879-8-denis.benato@linux.dev
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

authored by

Luke D. Jones and committed by
Ilpo Järvinen
c683651b 7725a2dc

+124 -25
+17
Documentation/ABI/testing/sysfs-platform-asus-wmi
··· 63 63 KernelVersion: 6.1 64 64 Contact: "Luke Jones" <luke@ljones.dev> 65 65 Description: 66 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 66 67 Switch the GPU hardware MUX mode. Laptops with this feature can 67 68 can be toggled to boot with only the dGPU (discrete mode) or in 68 69 standard Optimus/Hybrid mode. On switch a reboot is required: ··· 76 75 KernelVersion: 5.17 77 76 Contact: "Luke Jones" <luke@ljones.dev> 78 77 Description: 78 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 79 79 Disable discrete GPU: 80 80 * 0 - Enable dGPU, 81 81 * 1 - Disable dGPU ··· 86 84 KernelVersion: 5.17 87 85 Contact: "Luke Jones" <luke@ljones.dev> 88 86 Description: 87 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 89 88 Enable the external GPU paired with ROG X-Flow laptops. 90 89 Toggling this setting will also trigger ACPI to disable the dGPU: 91 90 ··· 98 95 KernelVersion: 5.17 99 96 Contact: "Luke Jones" <luke@ljones.dev> 100 97 Description: 98 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 101 99 Enable an LCD response-time boost to reduce or remove ghosting: 102 100 * 0 - Disable, 103 101 * 1 - Enable ··· 108 104 KernelVersion: 6.5 109 105 Contact: "Luke Jones" <luke@ljones.dev> 110 106 Description: 107 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 111 108 Get the current charging mode being used: 112 109 * 1 - Barrel connected charger, 113 110 * 2 - USB-C charging ··· 119 114 KernelVersion: 6.5 120 115 Contact: "Luke Jones" <luke@ljones.dev> 121 116 Description: 117 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 122 118 Show if the egpu (XG Mobile) is correctly connected: 123 119 * 0 - False, 124 120 * 1 - True ··· 129 123 KernelVersion: 6.5 130 124 Contact: "Luke Jones" <luke@ljones.dev> 131 125 Description: 126 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 132 127 Change the mini-LED mode: 133 128 * 0 - Single-zone, 134 129 * 1 - Multi-zone ··· 140 133 KernelVersion: 6.10 141 134 Contact: "Luke Jones" <luke@ljones.dev> 142 135 Description: 136 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 143 137 List the available mini-led modes. 144 138 145 139 What: /sys/devices/platform/<platform>/ppt_pl1_spl ··· 148 140 KernelVersion: 6.5 149 141 Contact: "Luke Jones" <luke@ljones.dev> 150 142 Description: 143 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 151 144 Set the Package Power Target total of CPU: PL1 on Intel, SPL on AMD. 152 145 Shown on Intel+Nvidia or AMD+Nvidia based systems: 153 146 ··· 159 150 KernelVersion: 6.5 160 151 Contact: "Luke Jones" <luke@ljones.dev> 161 152 Description: 153 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 162 154 Set the Slow Package Power Tracking Limit of CPU: PL2 on Intel, SPPT, 163 155 on AMD. Shown on Intel+Nvidia or AMD+Nvidia based systems: 164 156 ··· 170 160 KernelVersion: 6.5 171 161 Contact: "Luke Jones" <luke@ljones.dev> 172 162 Description: 163 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 173 164 Set the Fast Package Power Tracking Limit of CPU. AMD+Nvidia only: 174 165 * min=5, max=250 175 166 ··· 179 168 KernelVersion: 6.5 180 169 Contact: "Luke Jones" <luke@ljones.dev> 181 170 Description: 171 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 182 172 Set the APU SPPT limit. Shown on full AMD systems only: 183 173 * min=5, max=130 184 174 ··· 188 176 KernelVersion: 6.5 189 177 Contact: "Luke Jones" <luke@ljones.dev> 190 178 Description: 179 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 191 180 Set the platform SPPT limit. Shown on full AMD systems only: 192 181 * min=5, max=130 193 182 ··· 197 184 KernelVersion: 6.5 198 185 Contact: "Luke Jones" <luke@ljones.dev> 199 186 Description: 187 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 200 188 Set the dynamic boost limit of the Nvidia dGPU: 201 189 * min=5, max=25 202 190 ··· 206 192 KernelVersion: 6.5 207 193 Contact: "Luke Jones" <luke@ljones.dev> 208 194 Description: 195 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 209 196 Set the target temperature limit of the Nvidia dGPU: 210 197 * min=75, max=87 211 198 ··· 215 200 KernelVersion: 6.10 216 201 Contact: "Luke Jones" <luke@ljones.dev> 217 202 Description: 203 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 218 204 Set if the BIOS POST sound is played on boot. 219 205 * 0 - False, 220 206 * 1 - True ··· 225 209 KernelVersion: 6.10 226 210 Contact: "Luke Jones" <luke@ljones.dev> 227 211 Description: 212 + DEPRECATED, WILL BE REMOVED SOON: please use asus-armoury 228 213 Set if the MCU can go in to low-power mode on system sleep 229 214 * 0 - False, 230 215 * 1 - True
+11
drivers/platform/x86/Kconfig
··· 298 298 To compile this driver as a module, choose M here: the module will 299 299 be called asus-wmi. 300 300 301 + config ASUS_WMI_DEPRECATED_ATTRS 302 + bool "BIOS option support in WMI platform (DEPRECATED)" 303 + depends on ASUS_WMI 304 + default y 305 + help 306 + Say Y to expose the configurable BIOS options through the asus-wmi 307 + driver. 308 + 309 + This can be used with or without the asus-armoury driver which 310 + has the same attributes, but more, and better features. 311 + 301 312 config ASUS_NB_WMI 302 313 tristate "Asus Notebook WMI Driver" 303 314 depends on ASUS_WMI
+96 -25
drivers/platform/x86/asus-wmi.c
··· 338 338 /* Global to allow setting externally without requiring driver data */ 339 339 static enum asus_ally_mcu_hack use_ally_mcu_hack = ASUS_WMI_ALLY_MCU_HACK_INIT; 340 340 341 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 342 + static void asus_wmi_show_deprecated(void) 343 + { 344 + pr_notice_once("Accessing attributes through /sys/bus/platform/asus_wmi is deprecated and will be removed in a future release. Please switch over to /sys/class/firmware_attributes.\n"); 345 + } 346 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 347 + 341 348 /* WMI ************************************************************************/ 342 349 343 350 static int asus_wmi_evaluate_method3(u32 method_id, ··· 737 730 } 738 731 739 732 /* Charging mode, 1=Barrel, 2=USB ******************************************/ 733 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 740 734 static ssize_t charge_mode_show(struct device *dev, 741 735 struct device_attribute *attr, char *buf) 742 736 { ··· 748 740 if (result < 0) 749 741 return result; 750 742 743 + asus_wmi_show_deprecated(); 744 + 751 745 return sysfs_emit(buf, "%d\n", value & 0xff); 752 746 } 753 747 754 748 static DEVICE_ATTR_RO(charge_mode); 749 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 755 750 756 751 /* dGPU ********************************************************************/ 752 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 757 753 static ssize_t dgpu_disable_show(struct device *dev, 758 754 struct device_attribute *attr, char *buf) 759 755 { ··· 767 755 result = asus_wmi_get_devstate_simple(asus, ASUS_WMI_DEVID_DGPU); 768 756 if (result < 0) 769 757 return result; 758 + 759 + asus_wmi_show_deprecated(); 770 760 771 761 return sysfs_emit(buf, "%d\n", result); 772 762 } ··· 823 809 return count; 824 810 } 825 811 static DEVICE_ATTR_RW(dgpu_disable); 812 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 826 813 827 814 /* eGPU ********************************************************************/ 815 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 828 816 static ssize_t egpu_enable_show(struct device *dev, 829 817 struct device_attribute *attr, char *buf) 830 818 { ··· 836 820 result = asus_wmi_get_devstate_simple(asus, ASUS_WMI_DEVID_EGPU); 837 821 if (result < 0) 838 822 return result; 823 + 824 + asus_wmi_show_deprecated(); 839 825 840 826 return sysfs_emit(buf, "%d\n", result); 841 827 } ··· 895 877 return count; 896 878 } 897 879 static DEVICE_ATTR_RW(egpu_enable); 880 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 898 881 899 882 /* Is eGPU connected? *********************************************************/ 883 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 900 884 static ssize_t egpu_connected_show(struct device *dev, 901 885 struct device_attribute *attr, char *buf) 902 886 { ··· 909 889 if (result < 0) 910 890 return result; 911 891 892 + asus_wmi_show_deprecated(); 893 + 912 894 return sysfs_emit(buf, "%d\n", result); 913 895 } 914 896 915 897 static DEVICE_ATTR_RO(egpu_connected); 898 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 916 899 917 900 /* gpu mux switch *************************************************************/ 901 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 918 902 static ssize_t gpu_mux_mode_show(struct device *dev, 919 903 struct device_attribute *attr, char *buf) 920 904 { ··· 928 904 result = asus_wmi_get_devstate_simple(asus, asus->gpu_mux_dev); 929 905 if (result < 0) 930 906 return result; 907 + 908 + asus_wmi_show_deprecated(); 931 909 932 910 return sysfs_emit(buf, "%d\n", result); 933 911 } ··· 989 963 return count; 990 964 } 991 965 static DEVICE_ATTR_RW(gpu_mux_mode); 966 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 992 967 993 968 /* TUF Laptop Keyboard RGB Modes **********************************************/ 994 969 static ssize_t kbd_rgb_mode_store(struct device *dev, ··· 1113 1086 }; 1114 1087 1115 1088 /* Tunable: PPT: Intel=PL1, AMD=SPPT *****************************************/ 1089 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 1116 1090 static ssize_t ppt_pl2_sppt_store(struct device *dev, 1117 1091 struct device_attribute *attr, 1118 1092 const char *buf, size_t count) ··· 1151 1123 char *buf) 1152 1124 { 1153 1125 struct asus_wmi *asus = dev_get_drvdata(dev); 1126 + 1127 + asus_wmi_show_deprecated(); 1154 1128 1155 1129 return sysfs_emit(buf, "%u\n", asus->ppt_pl2_sppt); 1156 1130 } ··· 1195 1165 char *buf) 1196 1166 { 1197 1167 struct asus_wmi *asus = dev_get_drvdata(dev); 1168 + 1169 + asus_wmi_show_deprecated(); 1198 1170 1199 1171 return sysfs_emit(buf, "%u\n", asus->ppt_pl1_spl); 1200 1172 } ··· 1241 1209 { 1242 1210 struct asus_wmi *asus = dev_get_drvdata(dev); 1243 1211 1212 + asus_wmi_show_deprecated(); 1213 + 1244 1214 return sysfs_emit(buf, "%u\n", asus->ppt_fppt); 1245 1215 } 1246 1216 static DEVICE_ATTR_RW(ppt_fppt); ··· 1285 1251 char *buf) 1286 1252 { 1287 1253 struct asus_wmi *asus = dev_get_drvdata(dev); 1254 + 1255 + asus_wmi_show_deprecated(); 1288 1256 1289 1257 return sysfs_emit(buf, "%u\n", asus->ppt_apu_sppt); 1290 1258 } ··· 1331 1295 { 1332 1296 struct asus_wmi *asus = dev_get_drvdata(dev); 1333 1297 1298 + asus_wmi_show_deprecated(); 1299 + 1334 1300 return sysfs_emit(buf, "%u\n", asus->ppt_platform_sppt); 1335 1301 } 1336 1302 static DEVICE_ATTR_RW(ppt_platform_sppt); ··· 1375 1337 char *buf) 1376 1338 { 1377 1339 struct asus_wmi *asus = dev_get_drvdata(dev); 1340 + 1341 + asus_wmi_show_deprecated(); 1378 1342 1379 1343 return sysfs_emit(buf, "%u\n", asus->nv_dynamic_boost); 1380 1344 } ··· 1421 1381 { 1422 1382 struct asus_wmi *asus = dev_get_drvdata(dev); 1423 1383 1384 + asus_wmi_show_deprecated(); 1385 + 1424 1386 return sysfs_emit(buf, "%u\n", asus->nv_temp_target); 1425 1387 } 1426 1388 static DEVICE_ATTR_RW(nv_temp_target); 1389 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 1427 1390 1428 1391 /* Ally MCU Powersave ********************************************************/ 1429 1392 ··· 1467 1424 } 1468 1425 EXPORT_SYMBOL_NS_GPL(set_ally_mcu_powersave, "ASUS_WMI"); 1469 1426 1427 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 1470 1428 static ssize_t mcu_powersave_show(struct device *dev, 1471 1429 struct device_attribute *attr, char *buf) 1472 1430 { ··· 1477 1433 result = asus_wmi_get_devstate_simple(asus, ASUS_WMI_DEVID_MCU_POWERSAVE); 1478 1434 if (result < 0) 1479 1435 return result; 1436 + 1437 + asus_wmi_show_deprecated(); 1480 1438 1481 1439 return sysfs_emit(buf, "%d\n", result); 1482 1440 } ··· 1515 1469 return count; 1516 1470 } 1517 1471 static DEVICE_ATTR_RW(mcu_powersave); 1472 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 1518 1473 1519 1474 /* Battery ********************************************************************/ 1520 1475 ··· 2389 2342 } 2390 2343 2391 2344 /* Panel Overdrive ************************************************************/ 2345 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 2392 2346 static ssize_t panel_od_show(struct device *dev, 2393 2347 struct device_attribute *attr, char *buf) 2394 2348 { ··· 2399 2351 result = asus_wmi_get_devstate_simple(asus, ASUS_WMI_DEVID_PANEL_OD); 2400 2352 if (result < 0) 2401 2353 return result; 2354 + 2355 + asus_wmi_show_deprecated(); 2402 2356 2403 2357 return sysfs_emit(buf, "%d\n", result); 2404 2358 } ··· 2438 2388 return count; 2439 2389 } 2440 2390 static DEVICE_ATTR_RW(panel_od); 2391 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 2441 2392 2442 2393 /* Bootup sound ***************************************************************/ 2443 - 2394 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 2444 2395 static ssize_t boot_sound_show(struct device *dev, 2445 2396 struct device_attribute *attr, char *buf) 2446 2397 { ··· 2451 2400 result = asus_wmi_get_devstate_simple(asus, ASUS_WMI_DEVID_BOOT_SOUND); 2452 2401 if (result < 0) 2453 2402 return result; 2403 + 2404 + asus_wmi_show_deprecated(); 2454 2405 2455 2406 return sysfs_emit(buf, "%d\n", result); 2456 2407 } ··· 2489 2436 return count; 2490 2437 } 2491 2438 static DEVICE_ATTR_RW(boot_sound); 2439 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 2492 2440 2493 2441 /* Mini-LED mode **************************************************************/ 2442 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 2494 2443 static ssize_t mini_led_mode_show(struct device *dev, 2495 2444 struct device_attribute *attr, char *buf) 2496 2445 { ··· 2522 2467 break; 2523 2468 } 2524 2469 } 2470 + 2471 + asus_wmi_show_deprecated(); 2525 2472 2526 2473 return sysfs_emit(buf, "%d\n", value); 2527 2474 } ··· 2595 2538 return sysfs_emit(buf, "0 1 2\n"); 2596 2539 } 2597 2540 2541 + asus_wmi_show_deprecated(); 2542 + 2598 2543 return sysfs_emit(buf, "0\n"); 2599 2544 } 2600 2545 2601 2546 static DEVICE_ATTR_RO(available_mini_led_mode); 2547 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 2602 2548 2603 2549 /* Quirks *********************************************************************/ 2604 2550 ··· 3889 3829 return throttle_thermal_policy_write(asus); 3890 3830 } 3891 3831 3832 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 3892 3833 static ssize_t throttle_thermal_policy_show(struct device *dev, 3893 3834 struct device_attribute *attr, char *buf) 3894 3835 { ··· 3933 3872 * Throttle thermal policy: 0 - default, 1 - overboost, 2 - silent 3934 3873 */ 3935 3874 static DEVICE_ATTR_RW(throttle_thermal_policy); 3875 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 3936 3876 3937 3877 /* Platform profile ***********************************************************/ 3938 3878 static int asus_wmi_platform_profile_get(struct device *dev, ··· 4535 4473 &dev_attr_camera.attr, 4536 4474 &dev_attr_cardr.attr, 4537 4475 &dev_attr_touchpad.attr, 4538 - &dev_attr_charge_mode.attr, 4539 - &dev_attr_egpu_enable.attr, 4540 - &dev_attr_egpu_connected.attr, 4541 - &dev_attr_dgpu_disable.attr, 4542 - &dev_attr_gpu_mux_mode.attr, 4543 4476 &dev_attr_lid_resume.attr, 4544 4477 &dev_attr_als_enable.attr, 4545 4478 &dev_attr_fan_boost_mode.attr, 4546 - &dev_attr_throttle_thermal_policy.attr, 4547 - &dev_attr_ppt_pl2_sppt.attr, 4548 - &dev_attr_ppt_pl1_spl.attr, 4549 - &dev_attr_ppt_fppt.attr, 4550 - &dev_attr_ppt_apu_sppt.attr, 4551 - &dev_attr_ppt_platform_sppt.attr, 4552 - &dev_attr_nv_dynamic_boost.attr, 4553 - &dev_attr_nv_temp_target.attr, 4554 - &dev_attr_mcu_powersave.attr, 4555 - &dev_attr_boot_sound.attr, 4556 - &dev_attr_panel_od.attr, 4557 - &dev_attr_mini_led_mode.attr, 4558 - &dev_attr_available_mini_led_mode.attr, 4479 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 4480 + &dev_attr_charge_mode.attr, 4481 + &dev_attr_egpu_enable.attr, 4482 + &dev_attr_egpu_connected.attr, 4483 + &dev_attr_dgpu_disable.attr, 4484 + &dev_attr_gpu_mux_mode.attr, 4485 + &dev_attr_ppt_pl2_sppt.attr, 4486 + &dev_attr_ppt_pl1_spl.attr, 4487 + &dev_attr_ppt_fppt.attr, 4488 + &dev_attr_ppt_apu_sppt.attr, 4489 + &dev_attr_ppt_platform_sppt.attr, 4490 + &dev_attr_nv_dynamic_boost.attr, 4491 + &dev_attr_nv_temp_target.attr, 4492 + &dev_attr_mcu_powersave.attr, 4493 + &dev_attr_boot_sound.attr, 4494 + &dev_attr_panel_od.attr, 4495 + &dev_attr_mini_led_mode.attr, 4496 + &dev_attr_available_mini_led_mode.attr, 4497 + &dev_attr_throttle_thermal_policy.attr, 4498 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 4559 4499 NULL 4560 4500 }; 4561 4501 ··· 4579 4515 devid = ASUS_WMI_DEVID_LID_RESUME; 4580 4516 else if (attr == &dev_attr_als_enable.attr) 4581 4517 devid = ASUS_WMI_DEVID_ALS_ENABLE; 4582 - else if (attr == &dev_attr_charge_mode.attr) 4518 + else if (attr == &dev_attr_fan_boost_mode.attr) 4519 + ok = asus->fan_boost_mode_available; 4520 + 4521 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 4522 + if (attr == &dev_attr_charge_mode.attr) 4583 4523 devid = ASUS_WMI_DEVID_CHARGE_MODE; 4584 4524 else if (attr == &dev_attr_egpu_enable.attr) 4585 4525 ok = asus->egpu_enable_available; ··· 4621 4553 ok = asus->mini_led_dev_id != 0; 4622 4554 else if (attr == &dev_attr_available_mini_led_mode.attr) 4623 4555 ok = asus->mini_led_dev_id != 0; 4556 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 4624 4557 4625 4558 if (devid != -1) { 4626 4559 ok = !(asus_wmi_get_devstate_simple(asus, devid) < 0); ··· 4877 4808 } 4878 4809 4879 4810 /* ensure defaults for tunables */ 4811 + #if IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) 4880 4812 asus->ppt_pl2_sppt = 5; 4881 4813 asus->ppt_pl1_spl = 5; 4882 4814 asus->ppt_apu_sppt = 5; ··· 4900 4830 asus->gpu_mux_dev = ASUS_WMI_DEVID_GPU_MUX; 4901 4831 else if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_GPU_MUX_VIVO)) 4902 4832 asus->gpu_mux_dev = ASUS_WMI_DEVID_GPU_MUX_VIVO; 4903 - 4904 - if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_TUF_RGB_MODE)) 4905 - asus->kbd_rgb_dev = ASUS_WMI_DEVID_TUF_RGB_MODE; 4906 - else if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_TUF_RGB_MODE2)) 4907 - asus->kbd_rgb_dev = ASUS_WMI_DEVID_TUF_RGB_MODE2; 4833 + #endif /* IS_ENABLED(CONFIG_ASUS_WMI_DEPRECATED_ATTRS) */ 4908 4834 4909 4835 if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_THROTTLE_THERMAL_POLICY)) 4910 4836 asus->throttle_thermal_policy_dev = ASUS_WMI_DEVID_THROTTLE_THERMAL_POLICY; 4911 4837 else if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_THROTTLE_THERMAL_POLICY_VIVO)) 4912 4838 asus->throttle_thermal_policy_dev = ASUS_WMI_DEVID_THROTTLE_THERMAL_POLICY_VIVO; 4839 + 4840 + if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_TUF_RGB_MODE)) 4841 + asus->kbd_rgb_dev = ASUS_WMI_DEVID_TUF_RGB_MODE; 4842 + else if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_TUF_RGB_MODE2)) 4843 + asus->kbd_rgb_dev = ASUS_WMI_DEVID_TUF_RGB_MODE2; 4913 4844 4914 4845 err = fan_boost_mode_check_present(asus); 4915 4846 if (err)