Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

toshiba_acpi: Fix pr_* messages from USB Sleep Functions

This patch fixes the messages displayed by the USB Sleep Functions,
they were printing wrong messages not associated to the feature
currently queried.

Signed-off-by: Azael Avalos <coproscefalo@gmail.com>
Signed-off-by: Darren Hart <dvhart@linux.intel.com>

authored by

Azael Avalos and committed by
Darren Hart
bb26f189 c8c91842

+8 -8
+8 -8
drivers/platform/x86/toshiba_acpi.c
··· 965 965 status = tci_raw(dev, in, out); 966 966 sci_close(dev); 967 967 if (ACPI_FAILURE(status) || out[0] == TOS_FAILURE) { 968 - pr_err("ACPI call to get USB S&C battery level failed\n"); 968 + pr_err("ACPI call to get USB Rapid Charge failed\n"); 969 969 return -EIO; 970 970 } else if (out[0] == TOS_NOT_SUPPORTED || 971 971 out[0] == TOS_INPUT_DATA_ERROR) { 972 - pr_info("USB Sleep and Charge not supported\n"); 972 + pr_info("USB Rapid Charge not supported\n"); 973 973 return -ENODEV; 974 974 } 975 975 ··· 993 993 status = tci_raw(dev, in, out); 994 994 sci_close(dev); 995 995 if (ACPI_FAILURE(status) || out[0] == TOS_FAILURE) { 996 - pr_err("ACPI call to set USB S&C battery level failed\n"); 996 + pr_err("ACPI call to set USB Rapid Charge failed\n"); 997 997 return -EIO; 998 998 } else if (out[0] == TOS_NOT_SUPPORTED) { 999 - pr_info("USB Sleep and Charge not supported\n"); 999 + pr_info("USB Rapid Charge not supported\n"); 1000 1000 return -ENODEV; 1001 1001 } else if (out[0] == TOS_INPUT_DATA_ERROR) { 1002 1002 return -EIO; ··· 1015 1015 result = sci_read(dev, SCI_USB_SLEEP_MUSIC, state); 1016 1016 sci_close(dev); 1017 1017 if (result == TOS_FAILURE) { 1018 - pr_err("ACPI call to set USB S&C mode failed\n"); 1018 + pr_err("ACPI call to get Sleep and Music failed\n"); 1019 1019 return -EIO; 1020 1020 } else if (result == TOS_NOT_SUPPORTED) { 1021 - pr_info("USB Sleep and Charge not supported\n"); 1021 + pr_info("Sleep and Music not supported\n"); 1022 1022 return -ENODEV; 1023 1023 } else if (result == TOS_INPUT_DATA_ERROR) { 1024 1024 return -EIO; ··· 1037 1037 result = sci_write(dev, SCI_USB_SLEEP_MUSIC, state); 1038 1038 sci_close(dev); 1039 1039 if (result == TOS_FAILURE) { 1040 - pr_err("ACPI call to set USB S&C mode failed\n"); 1040 + pr_err("ACPI call to set Sleep and Music failed\n"); 1041 1041 return -EIO; 1042 1042 } else if (result == TOS_NOT_SUPPORTED) { 1043 - pr_info("USB Sleep and Charge not supported\n"); 1043 + pr_info("Sleep and Music not supported\n"); 1044 1044 return -ENODEV; 1045 1045 } else if (result == TOS_INPUT_DATA_ERROR) { 1046 1046 return -EIO;