Index: uspace/drv/uhci-hcd/hc.c
===================================================================
--- uspace/drv/uhci-hcd/hc.c	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/hc.c	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -66,8 +66,4 @@
 static int hc_interrupt_emulator(void *arg);
 static int hc_debug_checker(void *arg);
-#if 0
-static bool usb_is_allowed(
-    bool low_speed, usb_transfer_type_t transfer, size_t size);
-#endif
 /*----------------------------------------------------------------------------*/
 /** Initialize UHCI hcd driver structure
@@ -89,9 +85,7 @@
 	int ret;
 
-#define CHECK_RET_DEST_FUN_RETURN(ret, message...) \
+#define CHECK_RET_RETURN(ret, message...) \
 	if (ret != EOK) { \
 		usb_log_error(message); \
-		if (instance->ddf_instance) \
-			ddf_fun_destroy(instance->ddf_instance); \
 		return ret; \
 	} else (void) 0
@@ -99,14 +93,11 @@
 	instance->hw_interrupts = interrupts;
 	instance->hw_failures = 0;
-
-	/* Setup UHCI function. */
-	instance->ddf_instance = fun;
 
 	/* allow access to hc control registers */
 	regs_t *io;
 	ret = pio_enable(regs, reg_size, (void**)&io);
-	CHECK_RET_DEST_FUN_RETURN(ret,
+	CHECK_RET_RETURN(ret,
 	    "Failed(%d) to gain access to registers at %p: %s.\n",
-	    ret, str_error(ret), io);
+	    ret, io, str_error(ret));
 	instance->registers = io;
 	usb_log_debug("Device registers at %p(%u) accessible.\n",
@@ -114,19 +105,15 @@
 
 	ret = hc_init_mem_structures(instance);
-	CHECK_RET_DEST_FUN_RETURN(ret,
-	    "Failed to initialize UHCI memory structures.\n");
+	CHECK_RET_RETURN(ret,
+	    "Failed(%d) to initialize UHCI memory structures: %s.\n",
+	    ret, str_error(ret));
 
 	hc_init_hw(instance);
 	if (!interrupts) {
-		instance->cleaner =
+		instance->interrupt_emulator =
 		    fibril_create(hc_interrupt_emulator, instance);
-		fibril_add_ready(instance->cleaner);
-	} else {
-		/* TODO: enable interrupts here */
-	}
-
-	instance->debug_checker =
-	    fibril_create(hc_debug_checker, instance);
-//	fibril_add_ready(instance->debug_checker);
+		fibril_add_ready(instance->interrupt_emulator);
+	}
+	(void)hc_debug_checker;
 
 	return EOK;
@@ -479,31 +466,4 @@
 #undef QH
 }
-/*----------------------------------------------------------------------------*/
-/** Check transfers for USB validity
- *
- * @param[in] low_speed Transfer speed.
- * @param[in] transfer Transer type
- * @param[in] size Size of data packets
- * @return True if transaction is allowed by USB specs, false otherwise
- */
-#if 0
-bool usb_is_allowed(
-    bool low_speed, usb_transfer_type_t transfer, size_t size)
-{
-	/* see USB specification chapter 5.5-5.8 for magic numbers used here */
-	switch(transfer)
-	{
-	case USB_TRANSFER_ISOCHRONOUS:
-		return (!low_speed && size < 1024);
-	case USB_TRANSFER_INTERRUPT:
-		return size <= (low_speed ? 8 : 64);
-	case USB_TRANSFER_CONTROL: /* device specifies its own max size */
-		return (size <= (low_speed ? 8 : 64));
-	case USB_TRANSFER_BULK: /* device specifies its own max size */
-		return (!low_speed && size <= 64);
-	}
-	return false;
-}
-#endif
 /**
  * @}
Index: uspace/drv/uhci-hcd/hc.h
===================================================================
--- uspace/drv/uhci-hcd/hc.h	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/hc.h	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -48,5 +48,7 @@
 #include "transfer_list.h"
 
+/** UHCI I/O registers layout */
 typedef struct uhci_regs {
+	/** Command register, controls HC behaviour */
 	uint16_t usbcmd;
 #define UHCI_CMD_MAX_PACKET (1 << 7)
@@ -59,4 +61,5 @@
 #define UHCI_CMD_RUN_STOP  (1 << 0)
 
+	/** Status register, 1 means interrupt is asserted (if enabled) */
 	uint16_t usbsts;
 #define UHCI_STATUS_HALTED (1 << 5)
@@ -67,4 +70,5 @@
 #define UHCI_STATUS_INTERRUPT (1 << 0)
 
+	/** Interrupt enabled registers */
 	uint16_t usbintr;
 #define UHCI_INTR_SHORT_PACKET (1 << 3)
@@ -73,6 +77,11 @@
 #define UHCI_INTR_CRC (1 << 0)
 
+	/** Register stores frame number used in SOF packet */
 	uint16_t frnum;
+
+	/** Pointer(physical) to the Frame List */
 	uint32_t flbaseadd;
+
+	/** SOF modification to match external timers */
 	uint8_t sofmod;
 } regs_t;
@@ -83,27 +92,40 @@
 #define UHCI_ALLOWED_HW_FAIL 5
 
+/* Main HC driver structure */
 typedef struct hc {
+	/** USB bus driver, devices and addresses */
 	usb_device_keeper_t manager;
+	/** USB bus driver, endpoints */
 	usb_endpoint_manager_t ep_manager;
 
+	/** Addresses of I/O registers */
 	regs_t *registers;
 
+	/** Frame List contains 1024 link pointers */
 	link_pointer_t *frame_list;
 
+	/** List and queue of interrupt transfers */
+	transfer_list_t transfers_interrupt;
+	/** List and queue of low speed control transfers */
+	transfer_list_t transfers_control_slow;
+	/** List and queue of full speed bulk transfers */
 	transfer_list_t transfers_bulk_full;
+	/** List and queue of full speed control transfers */
 	transfer_list_t transfers_control_full;
-	transfer_list_t transfers_control_slow;
-	transfer_list_t transfers_interrupt;
 
+	/** Pointer table to the above lists, helps during scheduling */
 	transfer_list_t *transfers[2][4];
 
+	/** Code to be executed in kernel interrupt handler */
 	irq_code_t interrupt_code;
 
-	fid_t cleaner;
-	fid_t debug_checker;
+	/** Fibril periodically checking status register*/
+	fid_t interrupt_emulator;
+
+	/** Indicator of hw interrupts availability */
 	bool hw_interrupts;
+
+	/** Number of hw failures detected. */
 	unsigned hw_failures;
-
-	ddf_fun_t *ddf_instance;
 } hc_t;
 
Index: uspace/drv/uhci-hcd/main.c
===================================================================
--- uspace/drv/uhci-hcd/main.c	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/main.c	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -39,5 +39,4 @@
 #include <usb/debug.h>
 
-#include "iface.h"
 #include "uhci.h"
 
@@ -62,6 +61,7 @@
 int uhci_add_device(ddf_dev_t *device)
 {
-	usb_log_debug("uhci_add_device() called\n");
+	usb_log_debug2("uhci_add_device() called\n");
 	assert(device);
+
 	uhci_t *uhci = malloc(sizeof(uhci_t));
 	if (uhci == NULL) {
@@ -72,6 +72,6 @@
 	int ret = uhci_init(uhci, device);
 	if (ret != EOK) {
-		usb_log_error("Failed to initialize UHCI driver: %s.\n",
-		    str_error(ret));
+		usb_log_error("Failed(%d) to initialize UHCI driver: %s.\n",
+		    ret, str_error(ret));
 		return ret;
 	}
@@ -85,5 +85,5 @@
 /** Initialize global driver structures (NONE).
  *
- * @param[in] argc Nmber of arguments in argv vector (ignored).
+ * @param[in] argc Number of arguments in argv vector (ignored).
  * @param[in] argv Cmdline argument vector (ignored).
  * @return Error code.
@@ -94,6 +94,4 @@
 {
 	printf(NAME ": HelenOS UHCI driver.\n");
-
-	sleep(3); /* TODO: remove in final version */
 	usb_log_enable(USB_LOG_LEVEL_DEFAULT, NAME);
 
Index: uspace/drv/uhci-hcd/pci.c
===================================================================
--- uspace/drv/uhci-hcd/pci.c	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/pci.c	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -44,5 +44,5 @@
 #include "pci.h"
 
-/** Get address of registers and IRQ for given device.
+/** Get I/O address of registers and IRQ for given device.
  *
  * @param[in] dev Device asking for the addresses.
@@ -53,18 +53,16 @@
  */
 int pci_get_my_registers(ddf_dev_t *dev,
-    uintptr_t *io_reg_address, size_t *io_reg_size,
-    int *irq_no)
+    uintptr_t *io_reg_address, size_t *io_reg_size, int *irq_no)
 {
 	assert(dev != NULL);
 
-	int parent_phone = devman_parent_device_connect(dev->handle,
-	    IPC_FLAG_BLOCKING);
+	int parent_phone =
+	    devman_parent_device_connect(dev->handle, IPC_FLAG_BLOCKING);
 	if (parent_phone < 0) {
 		return parent_phone;
 	}
 
-	int rc;
 	hw_resource_list_t hw_resources;
-	rc = hw_res_get_resource_list(parent_phone, &hw_resources);
+	int rc = hw_res_get_resource_list(parent_phone, &hw_resources);
 	if (rc != EOK) {
 		goto leave;
@@ -95,4 +93,5 @@
 			    res->res.io_range.address, res->res.io_range.size);
 			io_found = true;
+			break;
 
 		default:
@@ -113,5 +112,4 @@
 leave:
 	async_hangup(parent_phone);
-
 	return rc;
 }
@@ -145,5 +143,5 @@
 	}
 
-	/* See UHCI design guide for these values,
+	/* See UHCI design guide for these values p.45,
 	 * write all WC bits in USB legacy register */
 	sysarg_t address = 0xc0;
Index: uspace/drv/uhci-hcd/root_hub.c
===================================================================
--- uspace/drv/uhci-hcd/root_hub.c	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/root_hub.c	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -55,10 +55,13 @@
 	int ret = asprintf(&match_str, "usb&uhci&root-hub");
 	if (ret < 0) {
-		usb_log_error("Failed to create root hub match string.\n");
-		return ENOMEM;
+		usb_log_error(
+		    "Failed(%d) to create root hub match string: %s.\n",
+		    ret, str_error(ret));
+		return ret;
 	}
 
 	ret = ddf_fun_add_match_id(fun, match_str, 100);
 	if (ret != EOK) {
+		free(match_str);
 		usb_log_error("Failed(%d) to add root hub match id: %s\n",
 		    ret, str_error(ret));
@@ -66,8 +69,8 @@
 	}
 
-	hw_resource_list_t *resource_list = &instance->resource_list;
-	resource_list->count = 1;
-	resource_list->resources = &instance->io_regs;
-	assert(resource_list->resources);
+	/* Initialize resource structure */
+	instance->resource_list.count = 1;
+	instance->resource_list.resources = &instance->io_regs;
+
 	instance->io_regs.type = IO_RANGE;
 	instance->io_regs.res.io_range.address = reg_addr;
Index: uspace/drv/uhci-hcd/root_hub.h
===================================================================
--- uspace/drv/uhci-hcd/root_hub.h	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/root_hub.h	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -39,6 +39,9 @@
 #include <ops/hw_res.h>
 
+/** DDF support structure for uhci-rhd driver, provides I/O resources */
 typedef struct rh {
+	/** List of resources available to the root hub. */
 	hw_resource_list_t resource_list;
+	/** The only resource in the above list */
 	hw_resource_t io_regs;
 } rh_t;
Index: uspace/drv/uhci-hcd/uhci.c
===================================================================
--- uspace/drv/uhci-hcd/uhci.c	(revision 9d2d444d3b59436c06a1f40efb0311a036ac3f9f)
+++ uspace/drv/uhci-hcd/uhci.c	(revision ea993d187c0d51ace4521338277bd6b087c3e0a7)
@@ -63,5 +63,5 @@
  * @param[in] fun DDF instance of the function to use.
  * @param[in] handle DDF handle of the driver seeking its USB address.
- * @param[in] address Pointer to the place to store the found address.
+ * @param[out] address Found address.
  */
 static int usb_iface_get_address(
@@ -87,5 +87,5 @@
  *
  * @param[in] fun DDF function of uhci device.
- * @param[out] handle Place to write the HC handle.
+ * @param[out] handle Host cotnroller handle.
  * @return Error code.
  */
