Index: uspace/lib/usb/src/pipesio.c
===================================================================
--- uspace/lib/usb/src/pipesio.c	(revision e936e8e6cbbc25342b3cf6a6345b31510cc8d06f)
+++ uspace/lib/usb/src/pipesio.c	(revision ec4538d177a1db4e3a960efd7b592e896070bbaa)
@@ -115,5 +115,10 @@
 
 	if (data_request_rc != EOK) {
-		return (int) data_request_rc;
+		/* Prefer the return code of the opening request. */
+		if (opening_request_rc != EOK) {
+			return (int) opening_request_rc;
+		} else {
+			return (int) data_request_rc;
+		}
 	}
 	if (opening_request_rc != EOK) {
@@ -331,5 +336,10 @@
 
 	if (data_request_rc != EOK) {
-		return (int) data_request_rc;
+		/* Prefer the return code of the opening request. */
+		if (opening_request_rc != EOK) {
+			return (int) opening_request_rc;
+		} else {
+			return (int) data_request_rc;
+		}
 	}
 	if (opening_request_rc != EOK) {
