Changeset 495547d in mainline


Ignore:
Timestamp:
2015-07-03T23:10:21Z (9 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
cc468c7
Parents:
954d590
Message:

ehci/hc: Postpone enabling of interrupts.

Clean status register before doing so.
Helps avoid spurious interrupt on startup.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/ehci/hc.c

    r954d590 r495547d  
    397397        usb_log_debug("HC(%p): HW reset OK.", instance);
    398398
    399         //TODO: Do this last
    400         /* Enable interrupts */
    401         EHCI_WR(instance->registers->usbintr, EHCI_USED_INTERRUPTS);
    402399        /* Use the lowest 4G segment */
    403400        EHCI_WR(instance->registers->ctrldssegment, 0);
     
    435432            &instance->registers->usbintr, EHCI_RD(instance->registers->usbintr),
    436433            &instance->registers->configflag, EHCI_RD(instance->registers->configflag));
     434        /* Clear and Enable interrupts */
     435        EHCI_WR(instance->registers->usbsts, EHCI_RD(instance->registers->usbsts));
     436        EHCI_WR(instance->registers->usbintr, EHCI_USED_INTERRUPTS);
    437437}
    438438
Note: See TracChangeset for help on using the changeset viewer.