Index: uspace/drv/uhci-hcd/batch.c
===================================================================
--- uspace/drv/uhci-hcd/batch.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/batch.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,9 +26,9 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver USB transaction structure
  */
 #include <errno.h>
@@ -54,5 +54,5 @@
 
 
-/** Allocates memory and initializes internal data structures.
+/** Allocate memory and initialize internal data structure.
  *
  * @param[in] fun DDF function to pass to callback.
@@ -69,5 +69,10 @@
  * @param[in] arg additional parameter to func_in or func_out
  * @param[in] manager Pointer to toggle management structure.
- * @return False, if there is an active TD, true otherwise.
+ * @return Valid pointer if all substructures were successfully created,
+ * NULL otherwise.
+ *
+ * Determines the number of needed packets (TDs). Prepares a transport buffer
+ * (that is accessible by the hardware). Initializes parameters needed for the
+ * transaction and callback.
  */
 batch_t * batch_get(ddf_fun_t *fun, usb_target_t target,
@@ -148,8 +153,12 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Checks batch TDs for activity.
+/** Check batch TDs for activity.
  *
  * @param[in] instance Batch structure to use.
  * @return False, if there is an active TD, true otherwise.
+ *
+ * Walk all TDs. Stop with false if there is an active one (it is to be
+ * processed). Stop with true if an error is found. Return true if the last TS
+ * is reached.
  */
 bool batch_is_complete(batch_t *instance)
@@ -190,9 +199,11 @@
  *
  * @param[in] instance Batch structure to use.
+ *
+ * Uses genercir control function with pids OUT and IN.
  */
 void batch_control_write(batch_t *instance)
 {
 	assert(instance);
-	/* we are data out, we are supposed to provide data */
+	/* We are data out, we are supposed to provide data */
 	memcpy(instance->transport_buffer, instance->buffer,
 	    instance->buffer_size);
@@ -205,4 +216,6 @@
  *
  * @param[in] instance Batch structure to use.
+ *
+ * Uses generic control with pids IN and OUT.
  */
 void batch_control_read(batch_t *instance)
@@ -214,7 +227,9 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares interrupt in transaction.
- *
- * @param[in] instance Batch structure to use.
+/** Prepare interrupt in transaction.
+ *
+ * @param[in] instance Batch structure to use.
+ *
+ * Data transaction with PID_IN.
  */
 void batch_interrupt_in(batch_t *instance)
@@ -226,12 +241,14 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares interrupt out transaction.
- *
- * @param[in] instance Batch structure to use.
+/** Prepare interrupt out transaction.
+ *
+ * @param[in] instance Batch structure to use.
+ *
+ * Data transaction with PID_OUT.
  */
 void batch_interrupt_out(batch_t *instance)
 {
 	assert(instance);
-	/* we are data out, we are supposed to provide data */
+	/* We are data out, we are supposed to provide data */
 	memcpy(instance->transport_buffer, instance->buffer, instance->buffer_size);
 	batch_data(instance, USB_PID_OUT);
@@ -240,7 +257,9 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares bulk in transaction.
- *
- * @param[in] instance Batch structure to use.
+/** Prepare bulk in transaction.
+ *
+ * @param[in] instance Batch structure to use.
+ *
+ * Data transaction with PID_IN.
  */
 void batch_bulk_in(batch_t *instance)
@@ -252,11 +271,14 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares bulk out transaction.
- *
- * @param[in] instance Batch structure to use.
+/** Prepare bulk out transaction.
+ *
+ * @param[in] instance Batch structure to use.
+ *
+ * Data transaction with PID_OUT.
  */
 void batch_bulk_out(batch_t *instance)
 {
 	assert(instance);
+	/* We are data out, we are supposed to provide data */
 	memcpy(instance->transport_buffer, instance->buffer, instance->buffer_size);
 	batch_data(instance, USB_PID_OUT);
@@ -265,8 +287,11 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares generic data transaction
+/** Prepare generic data transaction
  *
  * @param[in] instance Batch structure to use.
  * @param[in] pid to use for data packets.
+ *
+ * Packets with alternating toggle bit and supplied pid value.
+ * The last packet is marked with IOC flag.
  */
 void batch_data(batch_t *instance, usb_packet_id pid)
@@ -309,9 +334,14 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares generic control transaction
+/** Prepare generic control transaction
  *
  * @param[in] instance Batch structure to use.
  * @param[in] data_stage to use for data packets.
  * @param[in] status_stage to use for data packets.
+ *
+ * Setup stage with toggle 0 and USB_PID_SETUP.
+ * Data stage with alternating toggle and pid supplied by parameter.
+ * Status stage with toggle 1 and pid supplied by parameter.
+ * The last packet is marked with IOC.
  */
 void batch_control(batch_t *instance,
@@ -362,7 +392,9 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares data, gets error status and calls callback in.
- *
- * @param[in] instance Batch structure to use.
+/** Prepare data, get error status and call callback in.
+ *
+ * @param[in] instance Batch structure to use.
+ * Copies data from transport buffer, and calls callback with appropriate
+ * parameters.
  */
 void batch_call_in(batch_t *instance)
@@ -371,5 +403,5 @@
 	assert(instance->callback_in);
 
-	/* we are data in, we need data */
+	/* We are data in, we need data */
 	memcpy(instance->buffer, instance->transport_buffer,
 	    instance->buffer_size);
@@ -384,5 +416,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Gets error status and calls callback out.
+/** Get error status and call callback out.
  *
  * @param[in] instance Batch structure to use.
@@ -400,5 +432,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Prepares data, gets error status, calls callback in and dispose.
+/** Helper function calls callback and correctly disposes of batch structure.
  *
  * @param[in] instance Batch structure to use.
@@ -411,5 +443,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Gets error status, calls callback out and dispose.
+/** Helper function calls callback and correctly disposes of batch structure.
  *
  * @param[in] instance Batch structure to use.
@@ -422,5 +454,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Correctly disposes all used data structures.
+/** Correctly dispose all used data structures.
  *
  * @param[in] instance Batch structure to use.
Index: uspace/drv/uhci-hcd/batch.h
===================================================================
--- uspace/drv/uhci-hcd/batch.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/batch.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,9 +26,9 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver USB transaction structure
  */
 #ifndef DRV_UHCI_BATCH_H
Index: uspace/drv/uhci-hcd/iface.c
===================================================================
--- uspace/drv/uhci-hcd/iface.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/iface.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,9 +26,9 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver hc interface implementation
  */
 #include <ddf/driver.h>
Index: uspace/drv/uhci-hcd/iface.h
===================================================================
--- uspace/drv/uhci-hcd/iface.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/iface.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -27,9 +27,9 @@
  */
 
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver iface
  */
 #ifndef DRV_UHCI_IFACE_H
Index: uspace/drv/uhci-hcd/main.c
===================================================================
--- uspace/drv/uhci-hcd/main.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/main.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,9 +26,9 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver initialization
  */
 #include <ddf/driver.h>
@@ -55,11 +55,8 @@
 };
 /*----------------------------------------------------------------------------*/
-/** Initializes a new ddf driver instance for uhci hc and hub.
+/** Initialize a new ddf driver instance for uhci hc and hub.
  *
  * @param[in] device DDF instance of the device to initialize.
  * @return Error code.
- *
- * Gets and initialies hardware resources, disables any legacy support,
- * and reports root hub device.
  */
 int uhci_add_device(ddf_dev_t *device)
@@ -82,5 +79,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Initializes global driver structures (NONE).
+/** Initialize global driver structures (NONE).
  *
  * @param[in] argc Nmber of arguments in argv vector (ignored).
@@ -92,5 +89,5 @@
 int main(int argc, char *argv[])
 {
-	sleep(3);
+	sleep(3); /* TODO: remove in final version */
 	usb_log_enable(USB_LOG_LEVEL_DEBUG, NAME);
 
Index: uspace/drv/uhci-hcd/pci.c
===================================================================
--- uspace/drv/uhci-hcd/pci.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/pci.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -27,5 +27,5 @@
  */
 /**
- * @addtogroup drvusbuhci
+ * @addtogroup drvusbuhcihc
  * @{
  */
@@ -117,5 +117,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Calls the PCI driver with a request to enable interrupts
+/** Call the PCI driver with a request to enable interrupts
  *
  * @param[in] device Device asking for interrupts
@@ -131,5 +131,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Calls the PCI driver with a request to clear legacy support register
+/** Call the PCI driver with a request to clear legacy support register
  *
  * @param[in] device Device asking to disable interrupts
Index: uspace/drv/uhci-hcd/pci.h
===================================================================
--- uspace/drv/uhci-hcd/pci.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/pci.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -27,9 +27,9 @@
  */
 
-/** @addtogroup drvusbuhci
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver PCI helper functions
  */
 #ifndef DRV_UHCI_PCI_H
Index: uspace/drv/uhci-hcd/transfer_list.c
===================================================================
--- uspace/drv/uhci-hcd/transfer_list.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/transfer_list.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,12 +26,11 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver transfer list implementation
  */
 #include <errno.h>
-
 #include <usb/debug.h>
 
@@ -41,8 +40,8 @@
     transfer_list_t *instance, batch_t *batch);
 /*----------------------------------------------------------------------------*/
-/** Initializes transfer list structures.
+/** Initialize transfer list structures.
  *
  * @param[in] instance Memory place to use.
- * @param[in] name Name of te new list.
+ * @param[in] name Name of the new list.
  * @return Error code
  *
@@ -66,5 +65,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Set the next list in chain.
+/** Set the next list in transfer list chain.
  *
  * @param[in] instance List to lead.
@@ -72,5 +71,5 @@
  * @return Error code
  *
- * Does not check whether there was a next list already.
+ * Does not check whether this replaces an existing list .
  */
 void transfer_list_set_next(transfer_list_t *instance, transfer_list_t *next)
@@ -80,14 +79,16 @@
 	if (!instance->queue_head)
 		return;
-	/* set both next and element to point to the same QH */
+	/* Set both next and element to point to the same QH */
 	qh_set_next_qh(instance->queue_head, next->queue_head_pa);
 	qh_set_element_qh(instance->queue_head, next->queue_head_pa);
 }
 /*----------------------------------------------------------------------------*/
-/** Submits a new transfer batch to list and queue.
+/** Submit transfer batch to the list and queue.
  *
  * @param[in] instance List to use.
  * @param[in] batch Transfer batch to submit.
  * @return Error code
+ *
+ * The batch is added to the end of the list and queue.
  */
 void transfer_list_add_batch(transfer_list_t *instance, batch_t *batch)
@@ -106,4 +107,5 @@
 	fibril_mutex_lock(&instance->guard);
 
+	/* Add to the hardware queue. */
 	if (list_empty(&instance->batch_list)) {
 		/* There is nothing scheduled */
@@ -117,4 +119,5 @@
 		qh_set_next_qh(last->qh, pa);
 	}
+	/* Add to the driver list */
 	list_append(&batch->link, &instance->batch_list);
 
@@ -126,5 +129,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Removes a transfer batch from the list and queue.
+/** Remove a transfer batch from the list and queue.
  *
  * @param[in] instance List to use.
@@ -144,4 +147,5 @@
 
 	const char * pos = NULL;
+	/* Remove from the hardware queue */
 	if (batch->link.prev == &instance->batch_list) {
 		/* I'm the first one here */
@@ -154,4 +158,5 @@
 		pos = "NOT FIRST";
 	}
+	/* Remove from the driver list */
 	list_remove(&batch->link);
 	usb_log_debug("Batch(%p) removed (%s) from %s, next element %x.\n",
@@ -159,8 +164,12 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Checks list for finished batches.
+/** Check list for finished batches.
  *
  * @param[in] instance List to use.
  * @return Error code
+ *
+ * Creates a local list of finished batches and calls next_step on each and
+ * every one. This is safer because next_step may theoretically access
+ * this transfer list leading to the deadlock if its done inline.
  */
 void transfer_list_remove_finished(transfer_list_t *instance)
@@ -177,4 +186,5 @@
 
 		if (batch_is_complete(batch)) {
+			/* Save for post-processing */
 			transfer_list_remove_batch(instance, batch);
 			list_append(current, &done);
Index: uspace/drv/uhci-hcd/transfer_list.h
===================================================================
--- uspace/drv/uhci-hcd/transfer_list.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/transfer_list.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,9 +26,9 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver transfer list structure
  */
 #ifndef DRV_UHCI_TRANSFER_LIST_H
@@ -50,8 +50,10 @@
 } transfer_list_t;
 
-int transfer_list_init(transfer_list_t *instance, const char *name);
-
-void transfer_list_set_next(transfer_list_t *instance, transfer_list_t *next);
-
+/** Dispose transfer list structures.
+ *
+ * @param[in] instance Memory place to use.
+ *
+ * Frees memory for internal qh_t structure.
+ */
 static inline void transfer_list_fini(transfer_list_t *instance)
 {
@@ -59,4 +61,9 @@
 	free32(instance->queue_head);
 }
+
+int transfer_list_init(transfer_list_t *instance, const char *name);
+
+void transfer_list_set_next(transfer_list_t *instance, transfer_list_t *next);
+
 void transfer_list_remove_finished(transfer_list_t *instance);
 
Index: uspace/drv/uhci-hcd/uhci.c
===================================================================
--- uspace/drv/uhci-hcd/uhci.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -60,4 +60,10 @@
 }
 /*----------------------------------------------------------------------------*/
+/** Get address of the device identified by handle.
+ *
+ * @param[in] dev DDF instance of the device to use.
+ * @param[in] iid (Unused).
+ * @param[in] call Pointer to the call that represents interrupt.
+ */
 static int usb_iface_get_address(
     ddf_fun_t *fun, devman_handle_t handle, usb_address_t *address)
@@ -106,5 +112,5 @@
 };
 /*----------------------------------------------------------------------------*/
-/** Gets root hub hw resources.
+/** Get root hub hw resources (I/O registers).
  *
  * @param[in] fun Root hub function.
@@ -127,4 +133,15 @@
 };
 /*----------------------------------------------------------------------------*/
+/** Initialize hc and rh ddf structures and their respective drivers.
+ *
+ * @param[in] instance UHCI structure to use.
+ * @param[in] device DDF instance of the device to use.
+ *
+ * This function does all the preparatory work for hc and rh drivers:
+ *  - gets device hw resources
+ *  - disables UHCI legacy support
+ *  - asks for interrupt
+ *  - registers interrupt handler
+ */
 int uhci_init(uhci_t *instance, ddf_dev_t *device)
 {
Index: uspace/drv/uhci-hcd/uhci.h
===================================================================
--- uspace/drv/uhci-hcd/uhci.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -31,5 +31,5 @@
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI driver main structure for both host controller and root-hub.
  */
 #ifndef DRV_UHCI_UHCI_H
Index: uspace/drv/uhci-hcd/uhci_hc.c
===================================================================
--- uspace/drv/uhci-hcd/uhci_hc.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_hc.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,9 +26,9 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI Host controller driver routines
  */
 #include <errno.h>
@@ -59,12 +59,4 @@
 	}
 };
-
-/** Gets USB address of the calling device.
- *
- * @param[in] fun UHCI hc function.
- * @param[in] handle Handle of the device seeking address.
- * @param[out] address Place to store found address.
- * @return Error code.
- */
 /*----------------------------------------------------------------------------*/
 static int uhci_hc_init_transfer_lists(uhci_hc_t *instance);
@@ -78,5 +70,5 @@
     bool low_speed, usb_transfer_type_t transfer, size_t size);
 /*----------------------------------------------------------------------------*/
-/** Initializes UHCI hcd driver structure
+/** Initialize UHCI hcd driver structure
  *
  * @param[in] instance Memory place to initialize.
@@ -86,4 +78,7 @@
  * @return Error code.
  * @note Should be called only once on any structure.
+ *
+ * Initializes memory structures, starts up hw, and launches debugger and
+ * interrupt fibrils.
  */
 int uhci_hc_init(uhci_hc_t *instance, ddf_fun_t *fun, void *regs, size_t reg_size)
@@ -130,7 +125,8 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Initializes UHCI hcd hw resources.
+/** Initialize UHCI hc hw resources.
  *
  * @param[in] instance UHCI structure to use.
+ * For magic values see UHCI Design Guide
  */
 void uhci_hc_init_hw(uhci_hc_t *instance)
@@ -154,6 +150,6 @@
 
 	/* Enable all interrupts, but resume interrupt */
-//	pio_write_16(&instance->registers->usbintr,
-//	    UHCI_INTR_CRC | UHCI_INTR_COMPLETE | UHCI_INTR_SHORT_PACKET);
+	pio_write_16(&instance->registers->usbintr,
+	    UHCI_INTR_CRC | UHCI_INTR_COMPLETE | UHCI_INTR_SHORT_PACKET);
 
 	uint16_t status = pio_read_16(&registers->usbcmd);
@@ -166,9 +162,14 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Initializes UHCI hcd memory structures.
+/** Initialize UHCI hc memory structures.
  *
  * @param[in] instance UHCI structure to use.
  * @return Error code
  * @note Should be called only once on any structure.
+ *
+ * Structures:
+ *  - interrupt code (I/O addressses are customized per instance)
+ *  - transfer lists (queue heads need to be accessible by the hw)
+ *  - frame list page (needs to be one UHCI hw accessible 4K page)
  */
 int uhci_hc_init_mem_structures(uhci_hc_t *instance)
@@ -229,9 +230,12 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Initializes UHCI hcd transfer lists.
+/** Initialize UHCI hc transfer lists.
  *
  * @param[in] instance UHCI structure to use.
  * @return Error code
  * @note Should be called only once on any structure.
+ *
+ * Initializes transfer lists and sets them in one chain to support proper
+ * USB scheduling. Sets pointer table for quick access.
  */
 int uhci_hc_init_transfer_lists(uhci_hc_t *instance)
@@ -293,9 +297,11 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Schedules batch for execution.
+/** Schedule batch for execution.
  *
  * @param[in] instance UHCI structure to use.
  * @param[in] batch Transfer batch to schedule.
  * @return Error code
+ *
+ * Checks for bandwidth availability and appends the batch to the proper queue.
  */
 int uhci_hc_schedule(uhci_hc_t *instance, batch_t *batch)
@@ -312,5 +318,5 @@
 		return ENOTSUP;
 	}
-	/* TODO: check available bandwith here */
+	/* TODO: check available bandwidth here */
 
 	transfer_list_t *list =
@@ -322,8 +328,13 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Takes action based on the interrupt cause.
+/** Take action based on the interrupt cause.
  *
  * @param[in] instance UHCI structure to use.
- * @param[in] status Value of the stsatus regiser at the time of interrupt.
+ * @param[in] status Value of the status register at the time of interrupt.
+ *
+ * Interrupt might indicate:
+ * - transaction completed, either by triggering IOC, SPD, or an error
+ * - some kind of device error
+ * - resume from suspend state (not implemented)
  */
 void uhci_hc_interrupt(uhci_hc_t *instance, uint16_t status)
@@ -342,6 +353,6 @@
 /** Polling function, emulates interrupts.
  *
- * @param[in] arg UHCI structure to use.
- * @return EOK
+ * @param[in] arg UHCI hc structure to use.
+ * @return EOK (should never return)
  */
 int uhci_hc_interrupt_emulator(void* arg)
@@ -366,5 +377,5 @@
  *
  * @param[in] arg UHCI structure to use.
- * @return EOK
+ * @return EOK (should never return)
  */
 int uhci_hc_debug_checker(void *arg)
@@ -430,10 +441,10 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Checks transfer packets, for USB validity
+/** Check transfer packets, for USB validity
  *
  * @param[in] low_speed Transfer speed.
  * @param[in] transfer Transer type
  * @param[in] size Maximum size of used packets
- * @return EOK
+ * @return True if transaction is allowed by USB specs, false otherwise
  */
 bool allowed_usb_packet(
Index: uspace/drv/uhci-hcd/uhci_hc.h
===================================================================
--- uspace/drv/uhci-hcd/uhci_hc.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_hc.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -27,9 +27,9 @@
  */
 
-/** @addtogroup drvusbuhci
+/** @addtogroup drvusbuhcihc
  * @{
  */
 /** @file
- * @brief UHCI driver
+ * @brief UHCI host controller driver structure
  */
 #ifndef DRV_UHCI_UHCI_HC_H
@@ -103,8 +103,5 @@
 } uhci_hc_t;
 
-/* init uhci specifics in device.driver_data */
 int uhci_hc_init(uhci_hc_t *instance, ddf_fun_t *fun, void *regs, size_t reg_size);
-
-static inline void uhci_hc_fini(uhci_hc_t *instance) { /* TODO: implement*/ };
 
 int uhci_hc_schedule(uhci_hc_t *instance, batch_t *batch);
@@ -112,4 +109,15 @@
 void uhci_hc_interrupt(uhci_hc_t *instance, uint16_t status);
 
+/** Safely dispose host controller internal structures
+ *
+ * @param[in] instance Host controller structure to use.
+ */
+static inline void uhci_hc_fini(uhci_hc_t *instance) { /* TODO: implement*/ };
+
+/** Get and cast pointer to the driver data
+ *
+ * @param[in] fun DDF function pointer
+ * @return cast pointer to driver_data
+ */
 static inline uhci_hc_t * fun_to_uhci_hc(ddf_fun_t *fun)
 	{ return (uhci_hc_t*)fun->driver_data; }
Index: uspace/drv/uhci-hcd/uhci_rh.c
===================================================================
--- uspace/drv/uhci-hcd/uhci_rh.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_rh.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,5 +26,5 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhci
  * @{
  */
@@ -42,5 +42,11 @@
 #include "uhci_hc.h"
 
-/*----------------------------------------------------------------------------*/
+/** Root hub initialization
+ * @param[in] instance RH structure to initialize
+ * @param[in] fun DDF function representing UHCI root hub
+ * @param[in] reg_addr Address of root hub status and control registers.
+ * @param[in] reg_size Size of accessible address space.
+ * @return Error code.
+ */
 int uhci_rh_init(
     uhci_rh_t *instance, ddf_fun_t *fun, uintptr_t reg_addr, size_t reg_size)
@@ -68,5 +74,4 @@
 	instance->io_regs.type = IO_RANGE;
 	instance->io_regs.res.io_range.address = reg_addr;
-//	    ((uintptr_t)hc->registers) + 0x10; // see UHCI design guide
 	instance->io_regs.res.io_range.size = reg_size;
 	instance->io_regs.res.io_range.endianness = LITTLE_ENDIAN;
Index: uspace/drv/uhci-hcd/uhci_struct/link_pointer.h
===================================================================
--- uspace/drv/uhci-hcd/uhci_struct/link_pointer.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_struct/link_pointer.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,5 +26,5 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
Index: uspace/drv/uhci-hcd/uhci_struct/queue_head.h
===================================================================
--- uspace/drv/uhci-hcd/uhci_struct/queue_head.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_struct/queue_head.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -1,3 +1,2 @@
-
 /*
  * Copyright (c) 2010 Jan Vesely
@@ -27,5 +26,5 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drv usbuhcihc
  * @{
  */
@@ -47,4 +46,10 @@
 } __attribute__((packed)) qh_t;
 /*----------------------------------------------------------------------------*/
+/** Initialize queue head structure
+ *
+ * @param[in] instance qh_t structure to initialize.
+ *
+ * Sets both pointer to terminal NULL.
+ */
 static inline void qh_init(qh_t *instance)
 {
@@ -55,7 +60,15 @@
 }
 /*----------------------------------------------------------------------------*/
+/** Set queue head next pointer
+ *
+ * @param[in] instance qh_t structure to use.
+ * @param[in] pa Physical address of the next queue head.
+ *
+ * Adds proper flag. If the pointer is NULL or terminal, sets next to terminal
+ * NULL.
+ */
 static inline void qh_set_next_qh(qh_t *instance, uint32_t pa)
 {
-	/* address is valid and not terminal */
+	/* Address is valid and not terminal */
 	if (pa && ((pa & LINK_POINTER_TERMINATE_FLAG) == 0)) {
 		instance->next = (pa & LINK_POINTER_ADDRESS_MASK)
@@ -66,7 +79,15 @@
 }
 /*----------------------------------------------------------------------------*/
+/** Set queue head element pointer
+ *
+ * @param[in] instance qh_t structure to initialize.
+ * @param[in] pa Physical address of the next queue head.
+ *
+ * Adds proper flag. If the pointer is NULL or terminal, sets element
+ * to terminal NULL.
+ */
 static inline void qh_set_element_qh(qh_t *instance, uint32_t pa)
 {
-	/* address is valid and not terminal */
+	/* Address is valid and not terminal */
 	if (pa && ((pa & LINK_POINTER_TERMINATE_FLAG) == 0)) {
 		instance->element = (pa & LINK_POINTER_ADDRESS_MASK)
@@ -77,4 +98,12 @@
 }
 /*----------------------------------------------------------------------------*/
+/** Set queue head element pointer
+ *
+ * @param[in] instance qh_t structure to initialize.
+ * @param[in] pa Physical address of the TD structure.
+ *
+ * Adds proper flag. If the pointer is NULL or terminal, sets element
+ * to terminal NULL.
+ */
 static inline void qh_set_element_td(qh_t *instance, uint32_t pa)
 {
Index: uspace/drv/uhci-hcd/uhci_struct/transfer_descriptor.c
===================================================================
--- uspace/drv/uhci-hcd/uhci_struct/transfer_descriptor.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_struct/transfer_descriptor.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -26,5 +26,5 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
@@ -38,5 +38,5 @@
 #include "utils/malloc32.h"
 
-/** Initializes Transfer Descriptor
+/** Initialize Transfer Descriptor
  *
  * @param[in] instance Memory place to initialize.
@@ -106,5 +106,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Converts TD status into standard error code
+/** Convert TD status into standard error code
  *
  * @param[in] instance TD structure to use.
Index: uspace/drv/uhci-hcd/uhci_struct/transfer_descriptor.h
===================================================================
--- uspace/drv/uhci-hcd/uhci_struct/transfer_descriptor.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/uhci_struct/transfer_descriptor.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -1,4 +1,4 @@
 /*
- * Copyright (c) 2010 Jan Vesely
+ * Copyright (c) 2011 Jan Vesely
  * All rights reserved.
  *
@@ -26,5 +26,5 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-/** @addtogroup usb
+/** @addtogroup drvusbuhcihc
  * @{
  */
@@ -108,5 +108,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Checks whether less than max data were recieved and packet is marked as SPD.
+/** Check whether less than max data were recieved and packet is marked as SPD.
  *
  * @param[in] instance TD structure to use.
Index: uspace/drv/uhci-hcd/utils/device_keeper.c
===================================================================
--- uspace/drv/uhci-hcd/utils/device_keeper.c	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/utils/device_keeper.c	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -27,5 +27,5 @@
  */
 
-/** @addtogroup drvusbuhci
+/** @addtogroup drvusbuhcihc
  * @{
  */
@@ -40,7 +40,9 @@
 
 /*----------------------------------------------------------------------------*/
-/** Initializes device keeper structure.
+/** Initialize device keeper structure.
  *
  * @param[in] instance Memory place to initialize.
+ *
+ * Set all values to false/0.
  */
 void device_keeper_init(device_keeper_t *instance)
@@ -58,5 +60,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Attempts to obtain address 0, blocks.
+/** Attempt to obtain address 0, blocks.
  *
  * @param[in] instance Device keeper structure to use.
@@ -76,5 +78,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Attempts to obtain address 0, blocks.
+/** Attempt to obtain address 0, blocks.
  *
  * @param[in] instance Device keeper structure to use.
@@ -90,9 +92,11 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Checks setup data for signs of toggle reset.
+/** Check setup packet data for signs of toggle reset.
  *
  * @param[in] instance Device keeper structure to use.
  * @param[in] target Device to receive setup packet.
  * @param[in] data Setup packet data.
+ *
+ * Really ugly one.
  */
 void device_keeper_reset_if_need(
@@ -105,4 +109,5 @@
 	    || !instance->devices[target.address].occupied) {
 		fibril_mutex_unlock(&instance->guard);
+		usb_log_error("Invalid data when checking for toggle reset.\n");
 		return;
 	}
@@ -130,5 +135,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Gets current value of endpoint toggle.
+/** Get current value of endpoint toggle.
  *
  * @param[in] instance Device keeper structure to use.
@@ -144,8 +149,8 @@
 	    || target.address >= USB_ADDRESS_COUNT || target.address < 0
 	    || !instance->devices[target.address].occupied) {
+		usb_log_error("Invalid data when asking for toggle value.\n");
 		ret = EINVAL;
 	} else {
-		ret =
-		    (instance->devices[target.address].toggle_status
+		ret = (instance->devices[target.address].toggle_status
 		        >> target.endpoint) & 1;
 	}
@@ -154,9 +159,9 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Sets current value of endpoint toggle.
+/** Set current value of endpoint toggle.
  *
  * @param[in] instance Device keeper structure to use.
  * @param[in] target Device and endpoint used.
- * @param[in] toggle Current toggle value.
+ * @param[in] toggle Toggle value.
  * @return Error code.
  */
@@ -170,4 +175,5 @@
 	    || target.address >= USB_ADDRESS_COUNT || target.address < 0
 	    || !instance->devices[target.address].occupied) {
+		usb_log_error("Invalid data when setting toggle value.\n");
 		ret = EINVAL;
 	} else {
@@ -183,5 +189,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Gets a free USB address
+/** Get a free USB address
  *
  * @param[in] instance Device keeper structure to use.
@@ -216,5 +222,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Binds USB address to devman handle.
+/** Bind USB address to devman handle.
  *
  * @param[in] instance Device keeper structure to use.
@@ -234,5 +240,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Releases used USB address.
+/** Release used USB address.
  *
  * @param[in] instance Device keeper structure to use.
@@ -251,5 +257,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Finds USB address associated with the device
+/** Find USB address associated with the device
  *
  * @param[in] instance Device keeper structure to use.
@@ -274,5 +280,5 @@
 }
 /*----------------------------------------------------------------------------*/
-/** Gets speed associated with the address
+/** Get speed associated with the address
  *
  * @param[in] instance Device keeper structure to use.
Index: uspace/drv/uhci-hcd/utils/device_keeper.h
===================================================================
--- uspace/drv/uhci-hcd/utils/device_keeper.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/utils/device_keeper.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -27,5 +27,5 @@
  */
 
-/** @addtogroup drvusbuhci
+/** @addtogroup drvusbuhcihc
  * @{
  */
Index: uspace/drv/uhci-hcd/utils/malloc32.h
===================================================================
--- uspace/drv/uhci-hcd/utils/malloc32.h	(revision 3bd96bb951ab0413b8e57b2afd8fdb7056374fb0)
+++ uspace/drv/uhci-hcd/utils/malloc32.h	(revision 17ceb7293c4b3e05a924f81338db1e3c118dea83)
@@ -43,4 +43,9 @@
 #define UHCI_REQUIRED_PAGE_SIZE 4096
 
+/** Get physical address translation
+ *
+ * @param[in] addr Virtual address to translate
+ * @return Physical address if exists, NULL otherwise.
+ */
 static inline uintptr_t addr_to_phys(void *addr)
 {
@@ -48,27 +53,41 @@
 	int ret = as_get_physical_mapping(addr, &result);
 
-	assert(ret == 0);
+	if (ret != EOK)
+		return 0;
 	return (result | ((uintptr_t)addr & 0xfff));
 }
-
+/*----------------------------------------------------------------------------*/
+/** Physical mallocator simulator
+ *
+ * @param[in] size Size of the required memory space
+ * @return Address of the alligned and big enough memory place, NULL on failure.
+ */
 static inline void * malloc32(size_t size)
 	{ return memalign(UHCI_STRCUTURES_ALIGNMENT, size); }
-
-static inline void * get_page()
+/*----------------------------------------------------------------------------*/
+/** Physical mallocator simulator
+ *
+ * @param[in] addr Address of the place allocated by malloc32
+ */
+static inline void free32(void *addr)
+	{ if (addr) free(addr); }
+/*----------------------------------------------------------------------------*/
+/** Create 4KB page mapping
+ *
+ * @return Address of the mapped page, NULL on failure.
+ */
+static inline void * get_page(void)
 {
 	void * free_address = as_get_mappable_page(UHCI_REQUIRED_PAGE_SIZE);
 	assert(free_address);
 	if (free_address == 0)
-		return 0;
+		return NULL;
 	void* ret =
 	  as_area_create(free_address, UHCI_REQUIRED_PAGE_SIZE,
 		  AS_AREA_READ | AS_AREA_WRITE);
 	if (ret != free_address)
-		return 0;
+		return NULL;
 	return ret;
 }
-
-static inline void free32(void *addr)
-	{ if (addr) free(addr); }
 
 #endif
