git.openpandora.org
/
pandora-kernel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
backlight: Remove unneeded owner field
[pandora-kernel.git]
/
drivers
/
acpi
/
asus_acpi.c
diff --git
a/drivers/acpi/asus_acpi.c
b/drivers/acpi/asus_acpi.c
index
7cc54aa
..
906c54f
100644
(file)
--- a/
drivers/acpi/asus_acpi.c
+++ b/
drivers/acpi/asus_acpi.c
@@
-26,7
+26,7
@@
* Pontus Fuchs - Helper functions, cleanup
* Johann Wiesner - Small compile fixes
* John Belmonte - ACPI code for Toshiba laptop was a good starting point.
* Pontus Fuchs - Helper functions, cleanup
* Johann Wiesner - Small compile fixes
* John Belmonte - ACPI code for Toshiba laptop was a good starting point.
- *
Ér
ic Burghard - LED display support for W1N
+ *
�
ic Burghard - LED display support for W1N
*
*/
*
*/
@@
-141,6
+141,7
@@
struct asus_hotk {
W5A, //W5A
W3V, //W3030V
xxN, //M2400N, M3700N, M5200N, M6800N, S1300N, S5200N
W5A, //W5A
W3V, //W3030V
xxN, //M2400N, M3700N, M5200N, M6800N, S1300N, S5200N
+ A4S, //Z81sp
//(Centrino)
END_MODEL
} model; //Models currently supported
//(Centrino)
END_MODEL
} model; //Models currently supported
@@
-397,7
+398,16
@@
static struct model_data model_conf[END_MODEL] = {
.brightness_set = "SPLV",
.brightness_get = "GPLV",
.display_set = "SDSP",
.brightness_set = "SPLV",
.brightness_get = "GPLV",
.display_set = "SDSP",
- .display_get = "\\ADVG"}
+ .display_get = "\\ADVG"},
+
+ {
+ .name = "A4S",
+ .brightness_set = "SPLV",
+ .brightness_get = "GPLV",
+ .mt_bt_switch = "BLED",
+ .mt_wled = "WLED"
+ }
+
};
/* procdir we use */
};
/* procdir we use */
@@
-421,7
+431,7
@@
static struct asus_hotk *hotk;
static int asus_hotk_add(struct acpi_device *device);
static int asus_hotk_remove(struct acpi_device *device, int type);
static struct acpi_driver asus_hotk_driver = {
static int asus_hotk_add(struct acpi_device *device);
static int asus_hotk_remove(struct acpi_device *device, int type);
static struct acpi_driver asus_hotk_driver = {
- .name =
ACPI_HOTK_NAME
,
+ .name =
"asus_acpi"
,
.class = ACPI_HOTK_CLASS,
.ids = ACPI_HOTK_HID,
.ops = {
.class = ACPI_HOTK_CLASS,
.ids = ACPI_HOTK_HID,
.ops = {
@@
-1117,6
+1127,8
@@
static int asus_model_match(char *model)
return W3V;
else if (strncmp(model, "W5A", 3) == 0)
return W5A;
return W3V;
else if (strncmp(model, "W5A", 3) == 0)
return W5A;
+ else if (strncmp(model, "A4S", 3) == 0)
+ return A4S;
else
return END_MODEL;
}
else
return END_MODEL;
}
@@
-1128,7
+1140,6
@@
static int asus_model_match(char *model)
static int asus_hotk_get_info(void)
{
struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
static int asus_hotk_get_info(void)
{
struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
- struct acpi_buffer dsdt = { ACPI_ALLOCATE_BUFFER, NULL };
union acpi_object *model = NULL;
int bsts_result;
char *string = NULL;
union acpi_object *model = NULL;
int bsts_result;
char *string = NULL;
@@
-1142,11
+1153,9
@@
static int asus_hotk_get_info(void)
* HID), this bit will be moved. A global variable asus_info contains
* the DSDT header.
*/
* HID), this bit will be moved. A global variable asus_info contains
* the DSDT header.
*/
- status = acpi_get_table(ACPI_
TABLE_ID_DSDT, 1, &dsdt
);
+ status = acpi_get_table(ACPI_
SIG_DSDT, 1, &asus_info
);
if (ACPI_FAILURE(status))
printk(KERN_WARNING " Couldn't get the DSDT table header\n");
if (ACPI_FAILURE(status))
printk(KERN_WARNING " Couldn't get the DSDT table header\n");
- else
- asus_info = dsdt.pointer;
/* We have to write 0 on init this far for all ASUS models */
if (!write_acpi_int(hotk->handle, "INIT", 0, &buffer)) {
/* We have to write 0 on init this far for all ASUS models */
if (!write_acpi_int(hotk->handle, "INIT", 0, &buffer)) {
@@
-1264,10
+1273,9
@@
static int asus_hotk_add(struct acpi_device *device)
printk(KERN_NOTICE "Asus Laptop ACPI Extras version %s\n",
ASUS_ACPI_VERSION);
printk(KERN_NOTICE "Asus Laptop ACPI Extras version %s\n",
ASUS_ACPI_VERSION);
- hotk = k
m
alloc(sizeof(struct asus_hotk), GFP_KERNEL);
+ hotk = k
z
alloc(sizeof(struct asus_hotk), GFP_KERNEL);
if (!hotk)
return -ENOMEM;
if (!hotk)
return -ENOMEM;
- memset(hotk, 0, sizeof(struct asus_hotk));
hotk->handle = device->handle;
strcpy(acpi_device_name(device), ACPI_HOTK_DEVICE_NAME);
hotk->handle = device->handle;
strcpy(acpi_device_name(device), ACPI_HOTK_DEVICE_NAME);
@@
-1345,7
+1353,6
@@
static int asus_hotk_remove(struct acpi_device *device, int type)
}
static struct backlight_properties asus_backlight_data = {
}
static struct backlight_properties asus_backlight_data = {
- .owner = THIS_MODULE,
.get_brightness = read_brightness,
.update_status = set_brightness_status,
.max_brightness = 15,
.get_brightness = read_brightness,
.update_status = set_brightness_status,
.max_brightness = 15,
@@
-1359,8
+1366,6
@@
static void __exit asus_acpi_exit(void)
acpi_bus_unregister_driver(&asus_hotk_driver);
remove_proc_entry(PROC_ASUS, acpi_root_dir);
acpi_bus_unregister_driver(&asus_hotk_driver);
remove_proc_entry(PROC_ASUS, acpi_root_dir);
- kfree(asus_info);
-
return;
}
return;
}
@@
-1371,10
+1376,6
@@
static int __init asus_acpi_init(void)
if (acpi_disabled)
return -ENODEV;
if (acpi_disabled)
return -ENODEV;
- if (!acpi_specific_hotkey_enabled) {
- printk(KERN_ERR "Using generic hotkey driver\n");
- return -ENODEV;
- }
asus_proc_dir = proc_mkdir(PROC_ASUS, acpi_root_dir);
if (!asus_proc_dir) {
printk(KERN_ERR "Asus ACPI: Unable to create /proc entry\n");
asus_proc_dir = proc_mkdir(PROC_ASUS, acpi_root_dir);
if (!asus_proc_dir) {
printk(KERN_ERR "Asus ACPI: Unable to create /proc entry\n");