diff mbox series

[v1] usb: core: Use ACPI_FAILURE at appropriate places

Message ID 20200218163217.53690-1-andriy.shevchenko@linux.intel.com (mailing list archive)
State Mainlined
Commit 2b974ee056a2a55e120071d014b31cb330117577
Headers show
Series [v1] usb: core: Use ACPI_FAILURE at appropriate places | expand

Commit Message

Andy Shevchenko Feb. 18, 2020, 4:32 p.m. UTC
Use ACPI_SUCCESS() to replace !ACPI_FAILURE(), this avoids !! operation.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/usb/core/usb-acpi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/usb/core/usb-acpi.c b/drivers/usb/core/usb-acpi.c
index 41b91f4c207d..9b31d658ab14 100644
--- a/drivers/usb/core/usb-acpi.c
+++ b/drivers/usb/core/usb-acpi.c
@@ -188,7 +188,7 @@  usb_acpi_find_companion_for_port(struct usb_port *port_dev)
 
 	handle = adev->handle;
 	status = acpi_get_physical_device_location(handle, &pld);
-	if (!ACPI_FAILURE(status) && pld) {
+	if (ACPI_SUCCESS(status) && pld) {
 		port_dev->location = USB_ACPI_LOCATION_VALID
 			| pld->group_token << 8 | pld->group_position;
 		port_dev->connect_type = usb_acpi_get_connect_type(handle, pld);