Changeset e583fd4 in mainline for uspace/drv/ohci/batch.c


Ignore:
Timestamp:
2011-04-14T22:05:27Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
d7f08b0d, e05d6c3
Parents:
0146d41 (diff), c9dc471 (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:

OHCI fixes

Add support for toggle reset on OHCI ED
Properly handle error conditions on OHCI ED

Fixes strange virtualbox behavior. Tested USB devices no longer hang usbinfo
Logitech keyboard supports HALT feature and makes use of new clea halt mechanism. MS mouse does not use HALT feature.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/ohci/batch.c

    r0146d41 re583fd4  
    161161                        usb_log_debug("Batch(%p) found error TD(%d):%x.\n",
    162162                            instance, i, data->tds[i]->status);
     163                        /* Make sure TD queue is empty (one TD),
     164                         * ED should be marked as halted */
     165                        data->ed->td_tail =
     166                            (data->ed->td_head & ED_TDTAIL_PTR_MASK);
     167                        ++i;
    163168                        break;
    164169                }
     
    169174        assert(hcd_ep);
    170175        hcd_ep->td = data->tds[i];
     176        /* Clear possible ED HALT */
     177        data->ed->td_head &= ~ED_TDHEAD_HALTED_FLAG;
     178        uint32_t pa = addr_to_phys(hcd_ep->td);
     179        assert(pa == (data->ed->td_head & ED_TDHEAD_PTR_MASK));
     180        assert(pa == (data->ed->td_tail & ED_TDTAIL_PTR_MASK));
    171181
    172182        return true;
Note: See TracChangeset for help on using the changeset viewer.