Index: uspace/drv/bus/usb/xhci/streams.c
===================================================================
--- uspace/drv/bus/usb/xhci/streams.c	(revision 8033f891a5db64bf70d7b58c3ae97e1b72e52042)
+++ uspace/drv/bus/usb/xhci/streams.c	(revision 45457265072881ea3db34a5feaa13f1ca7c28c4c)
@@ -85,5 +85,5 @@
  * @param[in] count Amount of primary streams.
  */
-static int initialize_primary_structures(xhci_endpoint_t *xhci_ep, unsigned count)
+static errno_t initialize_primary_structures(xhci_endpoint_t *xhci_ep, unsigned count)
 {
 	usb_log_debug("Allocating primary stream context array of size %u "
@@ -152,6 +152,6 @@
  * @param[in] index index of the initialized stream structure.
  */
-static int initialize_primary_stream(xhci_hc_t *hc, xhci_endpoint_t *xhci_ep,
-    unsigned index)
+static errno_t initialize_primary_stream(xhci_hc_t *hc, xhci_endpoint_t *xhci_ep,
+	unsigned index)
 {
 	xhci_stream_ctx_t *ctx = &xhci_ep->primary_stream_ctx_array[index];
@@ -159,5 +159,5 @@
 	memset(data, 0, sizeof(xhci_stream_data_t));
 
-	int err = EOK;
+	errno_t err = EOK;
 
 	/* Init and register TRB ring for the primary stream */
@@ -178,7 +178,7 @@
  * @param[in] xhci_ep XHCI bulk endpoint to use.
  */
-static int initialize_primary_streams(xhci_hc_t *hc, xhci_endpoint_t *xhci_ep)
-{
-	int err = EOK;
+static errno_t initialize_primary_streams(xhci_hc_t *hc, xhci_endpoint_t *xhci_ep)
+{
+	errno_t err = EOK;
 	size_t index;
 	for (index = 0; index < xhci_ep->primary_stream_data_size; ++index) {
@@ -205,6 +205,6 @@
  * @param[in] count Number of secondary streams to initialize.
  */
-static int initialize_secondary_streams(xhci_hc_t *hc, xhci_endpoint_t *xhci_ep,
-    unsigned idx, unsigned count)
+static errno_t initialize_secondary_streams(xhci_hc_t *hc, xhci_endpoint_t *xhci_ep,
+	unsigned idx, unsigned count)
 {
 	if (count == 0) {
@@ -243,5 +243,5 @@
 
 	/* Initialize all the rings. */
-	int err = EOK;
+	errno_t err = EOK;
 	size_t index;
 	for (index = 0; index < count; ++index) {
@@ -275,5 +275,5 @@
  */
 static void setup_stream_context(xhci_endpoint_t *xhci_ep, xhci_ep_ctx_t *ctx,
-    unsigned pstreams, unsigned lsa)
+	unsigned pstreams, unsigned lsa)
 {
 	XHCI_EP_TYPE_SET(*ctx, xhci_endpoint_type(xhci_ep));
@@ -294,5 +294,5 @@
  * @param[in] count Amount of primary streams requested.
  */
-static int verify_stream_conditions(xhci_hc_t *hc, xhci_device_t *dev,
+static errno_t verify_stream_conditions(xhci_hc_t *hc, xhci_device_t *dev,
 	xhci_endpoint_t *xhci_ep, unsigned count)
 {
@@ -345,6 +345,6 @@
  * @param[in] xhci_ep Associated XHCI bulk endpoint.
  */
-int xhci_endpoint_remove_streams(xhci_hc_t *hc, xhci_device_t *dev,
-    xhci_endpoint_t *xhci_ep)
+errno_t xhci_endpoint_remove_streams(xhci_hc_t *hc, xhci_device_t *dev,
+	xhci_endpoint_t *xhci_ep)
 {
 	if (!xhci_ep->primary_stream_data_size) {
@@ -357,5 +357,5 @@
 
 	/* Streams are now removed, proceed with reconfiguring endpoint. */
-	int err;
+	errno_t err;
 	if ((err = xhci_trb_ring_init(&xhci_ep->ring, 0))) {
 		usb_log_error("Failed to initialize a transfer ring.");
@@ -373,8 +373,8 @@
  * @param[in] count Amount of primary streams requested.
  */
-int xhci_endpoint_request_primary_streams(xhci_hc_t *hc, xhci_device_t *dev,
+errno_t xhci_endpoint_request_primary_streams(xhci_hc_t *hc, xhci_device_t *dev,
 	xhci_endpoint_t *xhci_ep, unsigned count)
 {
-	int err = verify_stream_conditions(hc, dev, xhci_ep, count);
+	errno_t err = verify_stream_conditions(hc, dev, xhci_ep, count);
 	if (err) {
 		return err;
@@ -421,5 +421,5 @@
  * @param[in] count Amount of primary streams requested.
  */
-int xhci_endpoint_request_secondary_streams(xhci_hc_t *hc, xhci_device_t *dev,
+errno_t xhci_endpoint_request_secondary_streams(xhci_hc_t *hc, xhci_device_t *dev,
 	xhci_endpoint_t *xhci_ep, unsigned *sizes, unsigned count)
 {
@@ -430,5 +430,5 @@
 	}
 
-	int err = verify_stream_conditions(hc, dev, xhci_ep, count);
+	errno_t err = verify_stream_conditions(hc, dev, xhci_ep, count);
 	if (err) {
 		return err;
