Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 297004
b: refs/heads/master
c: 34b6cfa
h: refs/heads/master
v: v3
  • Loading branch information
Lee, Chun-Yi authored and Matthew Garrett committed Mar 26, 2012
1 parent 9a74b1e commit 61a2605
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 917ee75a59160fe3518c1672feb4562f11a18fbc
refs/heads/master: 34b6cfabd760d3a2784f0ae649eb5e390e0e53cc
14 changes: 11 additions & 3 deletions trunk/drivers/platform/x86/acer-wmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,11 @@ struct hotkey_function_type_aa {
u8 length;
u16 handle;
u16 commun_func_bitmap;
u16 application_func_bitmap;
u16 media_func_bitmap;
u16 display_func_bitmap;
u16 others_func_bitmap;
u8 commun_fn_key_number;
} __attribute__((packed));

/*
Expand Down Expand Up @@ -213,6 +218,7 @@ static int force_series;
static bool ec_raw_mode;
static bool has_type_aa;
static u16 commun_func_bitmap;
static u8 commun_fn_key_number;

module_param(mailled, int, 0444);
module_param(brightness, int, 0444);
Expand Down Expand Up @@ -918,7 +924,7 @@ static acpi_status wmid3_get_device_status(u32 *value, u16 device)
union acpi_object *obj;
struct wmid3_gds_input_param params = {
.function_num = 0x1,
.hotkey_number = 0x01,
.hotkey_number = commun_fn_key_number,
.devices = device,
};
struct acpi_buffer input = {
Expand Down Expand Up @@ -987,7 +993,7 @@ static acpi_status wmid3_set_device_status(u32 value, u16 device)
u16 devices;
struct wmid3_gds_input_param params = {
.function_num = 0x1,
.hotkey_number = 0x01,
.hotkey_number = commun_fn_key_number,
.devices = commun_func_bitmap,
};
struct acpi_buffer input = {
Expand Down Expand Up @@ -1027,7 +1033,7 @@ static acpi_status wmid3_set_device_status(u32 value, u16 device)

devices = return_value.devices;
params.function_num = 0x2;
params.hotkey_number = 0x01;
params.hotkey_number = commun_fn_key_number;
params.devices = (value) ? (devices | device) : (devices & ~device);

status = wmi_evaluate_method(WMID_GUID3, 0, 0x1, &input, &output2);
Expand Down Expand Up @@ -1100,6 +1106,8 @@ static void type_aa_dmi_decode(const struct dmi_header *header, void *dummy)
interface->capability |= ACER_CAP_THREEG;
if (type_aa->commun_func_bitmap & ACER_WMID3_GDS_BLUETOOTH)
interface->capability |= ACER_CAP_BLUETOOTH;

commun_fn_key_number = type_aa->commun_fn_key_number;
}

static acpi_status WMID_set_capabilities(void)
Expand Down

0 comments on commit 61a2605

Please sign in to comment.