Changeset 5d36062 in mainline for uspace/drv/bus/usb/ohci/ohci_regs.h
- Timestamp:
- 2011-07-13T21:02:44Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 159100a
- Parents:
- ca2815e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/ohci/ohci_regs.h
rca2815e r5d36062 34 34 #ifndef DRV_OHCI_OHCI_REGS_H 35 35 #define DRV_OHCI_OHCI_REGS_H 36 #include <s tdint.h>36 #include <sys/types.h> 37 37 38 38 #define LEGACY_REGS_OFFSET 0x100 … … 40 40 /** OHCI memory mapped registers structure */ 41 41 typedef struct ohci_regs { 42 const volatile uint32_t revision;42 const ioport32_t revision; 43 43 #define R_REVISION_MASK (0x3f) 44 44 #define R_REVISION_SHIFT (0) 45 45 #define R_LEGACY_FLAG (0x80) 46 46 47 volatile uint32_t control;47 ioport32_t control; 48 48 #define C_CBSR_MASK (0x3) /* Control-bulk service ratio */ 49 49 #define C_CBSR_1_1 (0x0) … … 78 78 #define C_RWE (1 << 10) /* Remote wakeup enable */ 79 79 80 volatile uint32_t command_status;80 ioport32_t command_status; 81 81 #define CS_HCR (1 << 0) /* Host controller reset */ 82 82 #define CS_CLF (1 << 1) /* Control list filled */ … … 90 90 * writing causes enable/disable, 91 91 * status is write-clean (writing 1 clears the bit*/ 92 volatile uint32_t interrupt_status;93 volatile uint32_t interrupt_enable;94 volatile uint32_t interrupt_disable;92 ioport32_t interrupt_status; 93 ioport32_t interrupt_enable; 94 ioport32_t interrupt_disable; 95 95 #define I_SO (1 << 0) /* Scheduling overrun */ 96 96 #define I_WDH (1 << 1) /* Done head write-back */ … … 104 104 105 105 /** HCCA pointer (see hw_struct hcca.h) */ 106 volatile uint32_t hcca;106 ioport32_t hcca; 107 107 #define HCCA_PTR_MASK 0xffffff00 /* HCCA is 256B aligned */ 108 108 109 109 /** Currently executed periodic endpoint */ 110 const volatile uint32_t periodic_current;110 const ioport32_t periodic_current; 111 111 112 112 /** The first control endpoint */ 113 volatile uint32_t control_head;113 ioport32_t control_head; 114 114 115 115 /** Currently executed control endpoint */ 116 volatile uint32_t control_current;116 ioport32_t control_current; 117 117 118 118 /** The first bulk endpoint */ 119 volatile uint32_t bulk_head;119 ioport32_t bulk_head; 120 120 121 121 /** Currently executed bulk endpoint */ 122 volatile uint32_t bulk_current;122 ioport32_t bulk_current; 123 123 124 124 /** Done TD list, this value is periodically written to HCCA */ 125 const volatile uint32_t done_head;125 const ioport32_t done_head; 126 126 127 127 /** Frame time and max packet size for all transfers */ 128 volatile uint32_t fm_interval;128 ioport32_t fm_interval; 129 129 #define FMI_FI_MASK (0x3fff) /* Frame interval in bit times (should be 11999)*/ 130 130 #define FMI_FI_SHIFT (0) … … 134 134 135 135 /** Bit times remaining in current frame */ 136 const volatile uint32_t fm_remaining;136 const ioport32_t fm_remaining; 137 137 #define FMR_FR_MASK FMI_FI_MASK 138 138 #define FMR_FR_SHIFT FMI_FI_SHIFT … … 140 140 141 141 /** Frame number */ 142 const volatile uint32_t fm_number;142 const ioport32_t fm_number; 143 143 #define FMN_NUMBER_MASK (0xffff) 144 144 145 145 /** Remaining bit time in frame to start periodic transfers */ 146 volatile uint32_t periodic_start;146 ioport32_t periodic_start; 147 147 #define PS_PS_MASK (0x3fff) /* bit time when periodic get priority (0x3e67) */ 148 148 149 149 /** Threshold for starting LS transaction */ 150 volatile uint32_t ls_threshold;150 ioport32_t ls_threshold; 151 151 #define LST_LST_MASK (0x7fff) 152 152 153 153 /** The first root hub control register */ 154 volatile uint32_t rh_desc_a;154 ioport32_t rh_desc_a; 155 155 #define RHDA_NDS_MASK (0xff) /* Number of downstream ports, max 15 */ 156 156 #define RHDA_NDS_SHIFT (0) … … 164 164 165 165 /** The other root hub control register */ 166 volatile uint32_t rh_desc_b;166 ioport32_t rh_desc_b; 167 167 #define RHDB_DR_MASK (0xffff) /* Device removable mask */ 168 168 #define RHDB_DR_SHIFT (0) … … 176 176 177 177 /** Root hub status register */ 178 volatile uint32_t rh_status;178 ioport32_t rh_status; 179 179 #define RHS_LPS_FLAG (1 << 0)/* read: 0, 180 180 * write: 0-no effect, … … 198 198 199 199 /** Root hub per port status */ 200 volatile uint32_t rh_port_status[];200 ioport32_t rh_port_status[]; 201 201 #define RHPS_CCS_FLAG (1 << 0) /* r: current connect status, 202 202 * w: 1-clear port enable, 0-nothing */
Note:
See TracChangeset
for help on using the changeset viewer.