Index: uspace/drv/bus/usb/ohci/pci.c
===================================================================
--- uspace/drv/bus/usb/ohci/pci.c	(revision 82a3126168de2945f7d30595842c3d638a8204d2)
+++ uspace/drv/bus/usb/ohci/pci.c	(revision 45a9cf4ed2ab0809563a4d86d665955b4206bd43)
@@ -70,19 +70,19 @@
 	if (!parent_sess)
 		return ENOMEM;
-	
+
 	hw_resource_list_t hw_resources;
 	int rc = hw_res_get_resource_list(parent_sess, &hw_resources);
+	async_hangup(parent_sess);
 	if (rc != EOK) {
-		async_hangup(parent_sess);
 		return rc;
 	}
-	
+
 	uintptr_t mem_address = 0;
 	size_t mem_size = 0;
 	bool mem_found = false;
-	
+
 	int irq = 0;
 	bool irq_found = false;
-	
+
 	size_t i;
 	for (i = 0; i < hw_resources.count; i++) {
@@ -107,15 +107,13 @@
 		}
 	}
-	
+	free(hw_resources.resources);
+
 	if (mem_found && irq_found) {
 		*mem_reg_address = mem_address;
 		*mem_reg_size = mem_size;
 		*irq_no = irq;
-		rc = EOK;
-	} else
-		rc = ENOENT;
-	
-	async_hangup(parent_sess);
-	return rc;
+		return EOK;
+	}
+	return ENOENT;
 }
 
Index: uspace/drv/bus/usb/uhci/pci.c
===================================================================
--- uspace/drv/bus/usb/uhci/pci.c	(revision 82a3126168de2945f7d30595842c3d638a8204d2)
+++ uspace/drv/bus/usb/uhci/pci.c	(revision 45a9cf4ed2ab0809563a4d86d665955b4206bd43)
@@ -69,7 +69,7 @@
 
 	hw_resource_list_t hw_resources;
-	int rc = hw_res_get_resource_list(parent_sess, &hw_resources);
+	const int rc = hw_res_get_resource_list(parent_sess, &hw_resources);
+	async_hangup(parent_sess);
 	if (rc != EOK) {
-		async_hangup(parent_sess);
 		return rc;
 	}
@@ -78,8 +78,8 @@
 	size_t io_size = 0;
 	bool io_found = false;
-	
+
 	int irq = 0;
 	bool irq_found = false;
-	
+
 	size_t i;
 	for (i = 0; i < hw_resources.count; i++) {
@@ -102,6 +102,5 @@
 		}
 	}
-
-	async_hangup(parent_sess);
+	free(hw_resources.resources);
 
 	if (!io_found || !irq_found)
