Changeset 1f6eb7d in mainline


Ignore:
Timestamp:
2011-07-10T21:22:54Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
78ab6d4
Parents:
2e8a01b
Message:

OHCI: Remove irq code from hc_t structure.

Location:
uspace/drv/bus/usb/ohci
Files:
2 edited

Legend:

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

    r2e8a01b r1f6eb7d  
    632632            instance->lists[USB_TRANSFER_INTERRUPT].list_head_pa);
    633633
    634         /* Init interrupt code */
    635         instance->interrupt_code.cmds = instance->interrupt_commands;
    636         instance->interrupt_code.cmdcount = OHCI_NEEDED_IRQ_COMMANDS;
    637         {
    638                 /* Read status register */
    639                 instance->interrupt_commands[0].cmd = CMD_MEM_READ_32;
    640                 instance->interrupt_commands[0].dstarg = 1;
    641                 instance->interrupt_commands[0].addr =
    642                     (void*)&instance->registers->interrupt_status;
    643 
    644                 /* Test whether we are the interrupt cause */
    645                 instance->interrupt_commands[1].cmd = CMD_BTEST;
    646                 instance->interrupt_commands[1].value =
    647                     OHCI_USED_INTERRUPTS;
    648                 instance->interrupt_commands[1].srcarg = 1;
    649                 instance->interrupt_commands[1].dstarg = 2;
    650 
    651                 /* Predicate cleaning and accepting */
    652                 instance->interrupt_commands[2].cmd = CMD_PREDICATE;
    653                 instance->interrupt_commands[2].value = 2;
    654                 instance->interrupt_commands[2].srcarg = 2;
    655 
    656                 /* Write-clean status register */
    657                 instance->interrupt_commands[3].cmd = CMD_MEM_WRITE_A_32;
    658                 instance->interrupt_commands[3].srcarg = 1;
    659                 instance->interrupt_commands[3].addr =
    660                     (void*)&instance->registers->interrupt_status;
    661 
    662                 /* Accept interrupt */
    663                 instance->interrupt_commands[4].cmd = CMD_ACCEPT;
    664         }
    665 
    666634        return EOK;
    667635}
  • uspace/drv/bus/usb/ohci/hc.h

    r2e8a01b r1f6eb7d  
    5151#include "hw_struct/hcca.h"
    5252
    53 #define OHCI_NEEDED_IRQ_COMMANDS 5
    54 
    55 /** Main OHCI drier structure */
     53/** Main OHCI driver structure */
    5654typedef struct hc {
    5755        /** USB bus driver, devices and addresses */
     
    7573        /** Guards schedule and endpoint manipulation */
    7674        fibril_mutex_t guard;
    77 
    78         /** Code to be executed in kernel interrupt handler */
    79         irq_code_t interrupt_code;
    80 
    81         /** Commands that form interrupt code */
    82         irq_cmd_t interrupt_commands[OHCI_NEEDED_IRQ_COMMANDS];
    8375
    8476        /** USB hub emulation structure */
Note: See TracChangeset for help on using the changeset viewer.