Changeset b8cab5c in mainline for uspace/drv/uhci-hcd/transfer_list.c


Ignore:
Timestamp:
2011-05-27T07:10:12Z (13 years ago)
Author:
Matus Dekanek <smekideki@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ffca03c
Parents:
8bb61e6 (diff), 1889786 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

merge with usb/development

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/uhci-hcd/transfer_list.c

    r8bb61e6 rb8cab5c  
    3636#include <arch/barrier.h>
    3737
     38
    3839#include "transfer_list.h"
     40#include "batch.h"
    3941
    4042static void transfer_list_remove_batch(
     
    5860                return ENOMEM;
    5961        }
    60         uint32_t queue_head_pa = addr_to_phys(instance->queue_head);
     62        const uint32_t queue_head_pa = addr_to_phys(instance->queue_head);
    6163        usb_log_debug2("Transfer list %s setup with QH: %p (%#" PRIx32" ).\n",
    6264            name, instance->queue_head, queue_head_pa);
     
    9092{
    9193        assert(instance);
     94        assert(instance->queue_head);
    9295        assert(next);
    93         if (!instance->queue_head)
    94                 return;
    9596        /* Set queue_head.next to point to the follower */
    9697        qh_set_next_qh(instance->queue_head, next->queue_head);
     
    137138        write_barrier();
    138139
    139         /* Add to the driver list */
     140        /* Add to the driver's list */
    140141        list_append(&batch->link, &instance->batch_list);
    141142
     
    160161        link_t *current = instance->batch_list.next;
    161162        while (current != &instance->batch_list) {
    162                 link_t *next = current->next;
     163                link_t * const next = current->next;
    163164                usb_transfer_batch_t *batch =
    164165                    usb_transfer_batch_from_link(current);
     
    182183        fibril_mutex_lock(&instance->guard);
    183184        while (!list_empty(&instance->batch_list)) {
    184                 link_t *current = instance->batch_list.next;
     185                link_t * const current = instance->batch_list.next;
    185186                usb_transfer_batch_t *batch =
    186187                    usb_transfer_batch_from_link(current);
Note: See TracChangeset for help on using the changeset viewer.