Skip to contentSkip to conversation

uas: fix comparison for error code

PATCH Oliver Neukum 1 participant 1 message Mar 6, 2018

Subsystems (3)
lore
Share & tools
lore

Oliver Neukum

author maintainer
#0 lore raw

A typo broke the comparison.

Fixes cbeef22fd611c4f47c494b821b2b105b8af970bb ("usb: uas: unconditionally bring back host after reset")
---
 drivers/usb/storage/uas.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/storage/uas.c +1 -1
index 3b1b9695177a..6034c39b67d1 100644
@@ -1076,7 +1076,7 @@ static int uas_post_reset(struct usb_interface *intf)
 		return 0;
 
 	err = uas_configure_endpoints(devinfo);
-	if (err && err != ENODEV)
+	if (err && err != -ENODEV)
 		shost_printk(KERN_ERR, shost,
 			     "%s: alloc streams error %d after reset",
 			     __func__, err);