From: Lee, Chun-Yi
Git-commit: 1d1fc8a75fec3a2b29cc5864d45c5d03048f62e0
Patch-mainline: v3.2
References: bnc#745236
Release-target: openSUSE 12.1
Before set communication devices state, we need query out all devices state to set
the states bitmap. That will be better use the devices bitmap in SMBIOS type Aah
instead of hardcode in driver.
Tested on Acer Travelmate 8572.
Cc: Carlos Corbacho
Cc: Matthew Garrett
Cc: Dmitry Torokhov
Cc: Corentin Chary
Cc: Thomas Renninger
Signed-off-by: Lee, Chun-Yi
Signed-off-by: Matthew Garrett
---
drivers/platform/x86/acer-wmi.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
--- a/drivers/platform/x86/acer-wmi.c
+++ b/drivers/platform/x86/acer-wmi.c
@@ -206,6 +206,7 @@ static int threeg = -1;
static int force_series;
static bool ec_raw_mode;
static bool has_type_aa;
+static u16 commun_func_bitmap;
module_param(mailled, int, 0444);
module_param(brightness, int, 0444);
@@ -975,10 +976,7 @@ static acpi_status wmid3_set_device_stat
struct wmid3_gds_input_param params = {
.function_num = 0x1,
.hotkey_number = 0x01,
- .devices = ACER_WMID3_GDS_WIRELESS |
- ACER_WMID3_GDS_THREEG |
- ACER_WMID3_GDS_WIMAX |
- ACER_WMID3_GDS_BLUETOOTH,
+ .devices = commun_func_bitmap,
};
struct acpi_buffer input = {
sizeof(struct wmid3_gds_input_param),
@@ -1082,6 +1080,7 @@ static void type_aa_dmi_decode(const str
pr_info("Function bitmap for Communication Button: 0x%x\n",
type_aa->commun_func_bitmap);
+ commun_func_bitmap = type_aa->commun_func_bitmap;
if (type_aa->commun_func_bitmap & ACER_WMID3_GDS_WIRELESS)
interface->capability |= ACER_CAP_WIRELESS;
--
To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org
To contact the owner, e-mail: opensuse-kernel+owner@opensuse.org