File tree Expand file tree Collapse file tree 1 file changed +13
-10
lines changed Expand file tree Collapse file tree 1 file changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -163,6 +163,16 @@ MODULE_LICENSE("GPL");
163
163
164
164
static const char * const ashs_ids [] = { "ATK4001" , "ATK4002" , NULL };
165
165
166
+ static bool ashs_present (void )
167
+ {
168
+ int i = 0 ;
169
+ while (ashs_ids [i ]) {
170
+ if (acpi_dev_found (ashs_ids [i ++ ]))
171
+ return true;
172
+ }
173
+ return false;
174
+ }
175
+
166
176
struct bios_args {
167
177
u32 arg0 ;
168
178
u32 arg1 ;
@@ -1025,6 +1035,9 @@ static int asus_new_rfkill(struct asus_wmi *asus,
1025
1035
1026
1036
static void asus_wmi_rfkill_exit (struct asus_wmi * asus )
1027
1037
{
1038
+ if (asus -> driver -> wlan_ctrl_by_user && ashs_present ())
1039
+ return ;
1040
+
1028
1041
asus_unregister_rfkill_notifier (asus , "\\_SB.PCI0.P0P5" );
1029
1042
asus_unregister_rfkill_notifier (asus , "\\_SB.PCI0.P0P6" );
1030
1043
asus_unregister_rfkill_notifier (asus , "\\_SB.PCI0.P0P7" );
@@ -2121,16 +2134,6 @@ static int asus_wmi_fan_init(struct asus_wmi *asus)
2121
2134
return 0 ;
2122
2135
}
2123
2136
2124
- static bool ashs_present (void )
2125
- {
2126
- int i = 0 ;
2127
- while (ashs_ids [i ]) {
2128
- if (acpi_dev_found (ashs_ids [i ++ ]))
2129
- return true;
2130
- }
2131
- return false;
2132
- }
2133
-
2134
2137
/*
2135
2138
* WMI Driver
2136
2139
*/
You can’t perform that action at this time.
0 commit comments