File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,10 @@ static int wapf = -1;
41
41
module_param (wapf , uint , 0444 );
42
42
MODULE_PARM_DESC (wapf , "WAPF value" );
43
43
44
+ static int tablet_mode_sw = -1 ;
45
+ module_param (tablet_mode_sw , uint , 0444 );
46
+ MODULE_PARM_DESC (tablet_mode_sw , "Tablet mode detect: -1:auto 0:disable 1:kbd-dock 2:lid-flip" );
47
+
44
48
static struct quirk_entry * quirks ;
45
49
46
50
static bool asus_q500a_i8042_filter (unsigned char data , unsigned char str ,
@@ -477,6 +481,21 @@ static void asus_nb_wmi_quirks(struct asus_wmi_driver *driver)
477
481
else
478
482
wapf = quirks -> wapf ;
479
483
484
+ switch (tablet_mode_sw ) {
485
+ case 0 :
486
+ quirks -> use_kbd_dock_devid = false;
487
+ quirks -> use_lid_flip_devid = false;
488
+ break ;
489
+ case 1 :
490
+ quirks -> use_kbd_dock_devid = true;
491
+ quirks -> use_lid_flip_devid = false;
492
+ break ;
493
+ case 2 :
494
+ quirks -> use_kbd_dock_devid = false;
495
+ quirks -> use_lid_flip_devid = true;
496
+ break ;
497
+ }
498
+
480
499
if (quirks -> i8042_filter ) {
481
500
ret = i8042_install_filter (quirks -> i8042_filter );
482
501
if (ret ) {
You can’t perform that action at this time.
0 commit comments