husy394 / rpms / kernel

Forked from rpms/kernel 3 years ago
Clone
e293be
centosplus kernel patch [bug#15707]
e293be
centos-linux-3.10-asus-wmi-bug15707.patch
e293be
e293be
From 0fe57261214bcc866ef0233444a395b5fdfb5ac3 Mon Sep 17 00:00:00 2001
e293be
From: =?UTF-8?q?Pali=20Roh=C3=A1r?= <pali.rohar@gmail.com>
e293be
Date: Sat, 12 Aug 2017 09:44:16 +0200
e293be
Subject: platform/x86: asus-wmi: Evaluate wmi method with instance number 0x0
e293be
MIME-Version: 1.0
e293be
Content-Type: text/plain; charset=UTF-8
e293be
Content-Transfer-Encoding: 8bit
e293be
e293be
According to available DSDT dump from Asus machine, there is the only one
e293be
instance of the WMI GUID 97845ED0-4E6D-11DE-8A39-0800200C9A66 and so it is
e293be
0x0. Moreover corresponding method WMBC does not check Arg0 (instance
e293be
number) at all.
e293be
e293be
DSDT dump is available at:
e293be
https://lwn.net/Articles/391249/
e293be
e293be
_WDG dump:
e293be
0xD0, 0x5E, 0x84, 0x97, 0x6D, 0x4E, 0xDE, 0x11, 0x8A, 0x39, 0x08,
e293be
0x00, 0x20, 0x0C, 0x9A, 0x66,
e293be
0x42, 0x43,    // Object ID "BC" = method "WMBC"
e293be
0x01,          // Instance count
e293be
0x02,          // Flags
e293be
e293be
Signed-off-by: Pali Rohár <pali.rohar@gmail.com>
e293be
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
e293be
Submitted-by: Pablo Greco <pablo@fliagreco.com.ar>
e293be
Applied-by: Akemi Yagi <toracat@elrepo.org>
e293be
---
e293be
 drivers/platform/x86/asus-wmi.c | 4 ++--
e293be
 1 file changed, 2 insertions(+), 2 deletions(-)
e293be
e293be
diff --git a/drivers/platform/x86/asus-wmi.c b/drivers/platform/x86/asus-wmi.c
e293be
index 709e3a67391a..48e1541dc8d4 100644
e293be
--- a/drivers/platform/x86/asus-wmi.c
e293be
+++ b/drivers/platform/x86/asus-wmi.c
e293be
@@ -271,7 +271,7 @@ static int asus_wmi_evaluate_method(u32
e293be
 	union acpi_object *obj;
e293be
 	u32 tmp;
e293be
 
e293be
-	status = wmi_evaluate_method(ASUS_WMI_MGMT_GUID, 1, method_id,
e293be
+	status = wmi_evaluate_method(ASUS_WMI_MGMT_GUID, 0, method_id,
e293be
 				     &input, &output);
e293be
 
e293be
 	if (ACPI_FAILURE(status))
e293be
@@ -1669,7 +1669,7 @@ static int show_call(struct seq_file *m,
e293be
 		return -EPERM;
e293be
 
e293be
 	status = wmi_evaluate_method(ASUS_WMI_MGMT_GUID,
e293be
-				     1, asus->debug.method_id,
e293be
+				     0, asus->debug.method_id,
e293be
 				     &input, &output);
e293be
 
e293be
 	if (ACPI_FAILURE(status))
e293be
-- 
e293be
cgit 1.2-0.3.lf.el7
e293be