diff options
Diffstat (limited to 'drivers/platform/x86/asus-laptop.c')
-rw-r--r-- | drivers/platform/x86/asus-laptop.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/drivers/platform/x86/asus-laptop.c b/drivers/platform/x86/asus-laptop.c index c53b3ff7978a..d65df92e2acc 100644 --- a/drivers/platform/x86/asus-laptop.c +++ b/drivers/platform/x86/asus-laptop.c | |||
@@ -318,7 +318,7 @@ static int acpi_check_handle(acpi_handle handle, const char *method, | |||
318 | 318 | ||
319 | if (status != AE_OK) { | 319 | if (status != AE_OK) { |
320 | if (ret) | 320 | if (ret) |
321 | pr_warning("Error finding %s\n", method); | 321 | pr_warn("Error finding %s\n", method); |
322 | return -ENODEV; | 322 | return -ENODEV; |
323 | } | 323 | } |
324 | return 0; | 324 | return 0; |
@@ -383,7 +383,7 @@ static int asus_kled_lvl(struct asus_laptop *asus) | |||
383 | rv = acpi_evaluate_integer(asus->handle, METHOD_KBD_LIGHT_GET, | 383 | rv = acpi_evaluate_integer(asus->handle, METHOD_KBD_LIGHT_GET, |
384 | ¶ms, &kblv); | 384 | ¶ms, &kblv); |
385 | if (ACPI_FAILURE(rv)) { | 385 | if (ACPI_FAILURE(rv)) { |
386 | pr_warning("Error reading kled level\n"); | 386 | pr_warn("Error reading kled level\n"); |
387 | return -ENODEV; | 387 | return -ENODEV; |
388 | } | 388 | } |
389 | return kblv; | 389 | return kblv; |
@@ -397,7 +397,7 @@ static int asus_kled_set(struct asus_laptop *asus, int kblv) | |||
397 | kblv = 0; | 397 | kblv = 0; |
398 | 398 | ||
399 | if (write_acpi_int(asus->handle, METHOD_KBD_LIGHT_SET, kblv)) { | 399 | if (write_acpi_int(asus->handle, METHOD_KBD_LIGHT_SET, kblv)) { |
400 | pr_warning("Keyboard LED display write failed\n"); | 400 | pr_warn("Keyboard LED display write failed\n"); |
401 | return -EINVAL; | 401 | return -EINVAL; |
402 | } | 402 | } |
403 | return 0; | 403 | return 0; |
@@ -531,7 +531,7 @@ static int asus_read_brightness(struct backlight_device *bd) | |||
531 | rv = acpi_evaluate_integer(asus->handle, METHOD_BRIGHTNESS_GET, | 531 | rv = acpi_evaluate_integer(asus->handle, METHOD_BRIGHTNESS_GET, |
532 | NULL, &value); | 532 | NULL, &value); |
533 | if (ACPI_FAILURE(rv)) | 533 | if (ACPI_FAILURE(rv)) |
534 | pr_warning("Error reading brightness\n"); | 534 | pr_warn("Error reading brightness\n"); |
535 | 535 | ||
536 | return value; | 536 | return value; |
537 | } | 537 | } |
@@ -541,7 +541,7 @@ static int asus_set_brightness(struct backlight_device *bd, int value) | |||
541 | struct asus_laptop *asus = bl_get_data(bd); | 541 | struct asus_laptop *asus = bl_get_data(bd); |
542 | 542 | ||
543 | if (write_acpi_int(asus->handle, METHOD_BRIGHTNESS_SET, value)) { | 543 | if (write_acpi_int(asus->handle, METHOD_BRIGHTNESS_SET, value)) { |
544 | pr_warning("Error changing brightness\n"); | 544 | pr_warn("Error changing brightness\n"); |
545 | return -EIO; | 545 | return -EIO; |
546 | } | 546 | } |
547 | return 0; | 547 | return 0; |
@@ -730,7 +730,7 @@ static ssize_t store_ledd(struct device *dev, struct device_attribute *attr, | |||
730 | rv = parse_arg(buf, count, &value); | 730 | rv = parse_arg(buf, count, &value); |
731 | if (rv > 0) { | 731 | if (rv > 0) { |
732 | if (write_acpi_int(asus->handle, METHOD_LEDD, value)) { | 732 | if (write_acpi_int(asus->handle, METHOD_LEDD, value)) { |
733 | pr_warning("LED display write failed\n"); | 733 | pr_warn("LED display write failed\n"); |
734 | return -ENODEV; | 734 | return -ENODEV; |
735 | } | 735 | } |
736 | asus->ledd_status = (u32) value; | 736 | asus->ledd_status = (u32) value; |
@@ -752,7 +752,7 @@ static int asus_wireless_status(struct asus_laptop *asus, int mask) | |||
752 | rv = acpi_evaluate_integer(asus->handle, METHOD_WL_STATUS, | 752 | rv = acpi_evaluate_integer(asus->handle, METHOD_WL_STATUS, |
753 | NULL, &status); | 753 | NULL, &status); |
754 | if (ACPI_FAILURE(rv)) { | 754 | if (ACPI_FAILURE(rv)) { |
755 | pr_warning("Error reading Wireless status\n"); | 755 | pr_warn("Error reading Wireless status\n"); |
756 | return -EINVAL; | 756 | return -EINVAL; |
757 | } | 757 | } |
758 | return !!(status & mask); | 758 | return !!(status & mask); |
@@ -764,7 +764,7 @@ static int asus_wireless_status(struct asus_laptop *asus, int mask) | |||
764 | static int asus_wlan_set(struct asus_laptop *asus, int status) | 764 | static int asus_wlan_set(struct asus_laptop *asus, int status) |
765 | { | 765 | { |
766 | if (write_acpi_int(asus->handle, METHOD_WLAN, !!status)) { | 766 | if (write_acpi_int(asus->handle, METHOD_WLAN, !!status)) { |
767 | pr_warning("Error setting wlan status to %d", status); | 767 | pr_warn("Error setting wlan status to %d\n", status); |
768 | return -EIO; | 768 | return -EIO; |
769 | } | 769 | } |
770 | return 0; | 770 | return 0; |
@@ -792,7 +792,7 @@ static ssize_t store_wlan(struct device *dev, struct device_attribute *attr, | |||
792 | static int asus_bluetooth_set(struct asus_laptop *asus, int status) | 792 | static int asus_bluetooth_set(struct asus_laptop *asus, int status) |
793 | { | 793 | { |
794 | if (write_acpi_int(asus->handle, METHOD_BLUETOOTH, !!status)) { | 794 | if (write_acpi_int(asus->handle, METHOD_BLUETOOTH, !!status)) { |
795 | pr_warning("Error setting bluetooth status to %d", status); | 795 | pr_warn("Error setting bluetooth status to %d\n", status); |
796 | return -EIO; | 796 | return -EIO; |
797 | } | 797 | } |
798 | return 0; | 798 | return 0; |
@@ -821,7 +821,7 @@ static ssize_t store_bluetooth(struct device *dev, | |||
821 | static int asus_wimax_set(struct asus_laptop *asus, int status) | 821 | static int asus_wimax_set(struct asus_laptop *asus, int status) |
822 | { | 822 | { |
823 | if (write_acpi_int(asus->handle, METHOD_WIMAX, !!status)) { | 823 | if (write_acpi_int(asus->handle, METHOD_WIMAX, !!status)) { |
824 | pr_warning("Error setting wimax status to %d", status); | 824 | pr_warn("Error setting wimax status to %d\n", status); |
825 | return -EIO; | 825 | return -EIO; |
826 | } | 826 | } |
827 | return 0; | 827 | return 0; |
@@ -850,7 +850,7 @@ static ssize_t store_wimax(struct device *dev, | |||
850 | static int asus_wwan_set(struct asus_laptop *asus, int status) | 850 | static int asus_wwan_set(struct asus_laptop *asus, int status) |
851 | { | 851 | { |
852 | if (write_acpi_int(asus->handle, METHOD_WWAN, !!status)) { | 852 | if (write_acpi_int(asus->handle, METHOD_WWAN, !!status)) { |
853 | pr_warning("Error setting wwan status to %d", status); | 853 | pr_warn("Error setting wwan status to %d\n", status); |
854 | return -EIO; | 854 | return -EIO; |
855 | } | 855 | } |
856 | return 0; | 856 | return 0; |
@@ -880,7 +880,7 @@ static void asus_set_display(struct asus_laptop *asus, int value) | |||
880 | { | 880 | { |
881 | /* no sanity check needed for now */ | 881 | /* no sanity check needed for now */ |
882 | if (write_acpi_int(asus->handle, METHOD_SWITCH_DISPLAY, value)) | 882 | if (write_acpi_int(asus->handle, METHOD_SWITCH_DISPLAY, value)) |
883 | pr_warning("Error setting display\n"); | 883 | pr_warn("Error setting display\n"); |
884 | return; | 884 | return; |
885 | } | 885 | } |
886 | 886 | ||
@@ -909,7 +909,7 @@ static ssize_t store_disp(struct device *dev, struct device_attribute *attr, | |||
909 | static void asus_als_switch(struct asus_laptop *asus, int value) | 909 | static void asus_als_switch(struct asus_laptop *asus, int value) |
910 | { | 910 | { |
911 | if (write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value)) | 911 | if (write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value)) |
912 | pr_warning("Error setting light sensor switch\n"); | 912 | pr_warn("Error setting light sensor switch\n"); |
913 | asus->light_switch = value; | 913 | asus->light_switch = value; |
914 | } | 914 | } |
915 | 915 | ||
@@ -937,7 +937,7 @@ static ssize_t store_lssw(struct device *dev, struct device_attribute *attr, | |||
937 | static void asus_als_level(struct asus_laptop *asus, int value) | 937 | static void asus_als_level(struct asus_laptop *asus, int value) |
938 | { | 938 | { |
939 | if (write_acpi_int(asus->handle, METHOD_ALS_LEVEL, value)) | 939 | if (write_acpi_int(asus->handle, METHOD_ALS_LEVEL, value)) |
940 | pr_warning("Error setting light sensor level\n"); | 940 | pr_warn("Error setting light sensor level\n"); |
941 | asus->light_level = value; | 941 | asus->light_level = value; |
942 | } | 942 | } |
943 | 943 | ||
@@ -976,7 +976,7 @@ static int asus_gps_status(struct asus_laptop *asus) | |||
976 | rv = acpi_evaluate_integer(asus->handle, METHOD_GPS_STATUS, | 976 | rv = acpi_evaluate_integer(asus->handle, METHOD_GPS_STATUS, |
977 | NULL, &status); | 977 | NULL, &status); |
978 | if (ACPI_FAILURE(rv)) { | 978 | if (ACPI_FAILURE(rv)) { |
979 | pr_warning("Error reading GPS status\n"); | 979 | pr_warn("Error reading GPS status\n"); |
980 | return -ENODEV; | 980 | return -ENODEV; |
981 | } | 981 | } |
982 | return !!status; | 982 | return !!status; |
@@ -1284,7 +1284,7 @@ static int asus_laptop_get_info(struct asus_laptop *asus) | |||
1284 | */ | 1284 | */ |
1285 | status = acpi_get_table(ACPI_SIG_DSDT, 1, &asus->dsdt_info); | 1285 | status = acpi_get_table(ACPI_SIG_DSDT, 1, &asus->dsdt_info); |
1286 | if (ACPI_FAILURE(status)) | 1286 | if (ACPI_FAILURE(status)) |
1287 | pr_warning("Couldn't get the DSDT table header\n"); | 1287 | pr_warn("Couldn't get the DSDT table header\n"); |
1288 | 1288 | ||
1289 | /* We have to write 0 on init this far for all ASUS models */ | 1289 | /* We have to write 0 on init this far for all ASUS models */ |
1290 | if (write_acpi_int_ret(asus->handle, "INIT", 0, &buffer)) { | 1290 | if (write_acpi_int_ret(asus->handle, "INIT", 0, &buffer)) { |
@@ -1296,7 +1296,7 @@ static int asus_laptop_get_info(struct asus_laptop *asus) | |||
1296 | status = | 1296 | status = |
1297 | acpi_evaluate_integer(asus->handle, "BSTS", NULL, &bsts_result); | 1297 | acpi_evaluate_integer(asus->handle, "BSTS", NULL, &bsts_result); |
1298 | if (ACPI_FAILURE(status)) | 1298 | if (ACPI_FAILURE(status)) |
1299 | pr_warning("Error calling BSTS\n"); | 1299 | pr_warn("Error calling BSTS\n"); |
1300 | else if (bsts_result) | 1300 | else if (bsts_result) |
1301 | pr_notice("BSTS called, 0x%02x returned\n", | 1301 | pr_notice("BSTS called, 0x%02x returned\n", |
1302 | (uint) bsts_result); | 1302 | (uint) bsts_result); |