toshiba_acpi: Fix USB Sleep and Music always disabled
authorAzael Avalos <coproscefalo@gmail.com>
Wed, 9 Sep 2015 17:25:44 +0000 (11:25 -0600)
committerDarren Hart <dvhart@linux.intel.com>
Thu, 10 Sep 2015 21:23:34 +0000 (14:23 -0700)
Commit e1a949c1b988 ("toshiba_acpi: Refactor *{get, set} functions return
value") made changes on the return type of the HCI/SCI functions, but a
typo on the USB Sleep and Music code is always reporting non existent
support for such feature.

This patch corrects the typo, changing an assignment to a comparison,
making the laptops with actual support for such feature to work again.

Signed-off-by: Azael Avalos <coproscefalo@gmail.com>
Signed-off-by: Darren Hart <dvhart@linux.intel.com>
drivers/platform/x86/toshiba_acpi.c

index 6740c513919cc153f522a0c72e3fd4e183dab16a..c434b53323ed5a555011a097518e13f19fac757f 100644 (file)
@@ -938,7 +938,7 @@ static int toshiba_usb_sleep_music_get(struct toshiba_acpi_dev *dev, u32 *state)
        else if (result == TOS_NOT_SUPPORTED)
                return -ENODEV;
 
-       return result = TOS_SUCCESS ? 0 : -EIO;
+       return result == TOS_SUCCESS ? 0 : -EIO;
 }
 
 static int toshiba_usb_sleep_music_set(struct toshiba_acpi_dev *dev, u32 state)