Changes in uspace/drv/ohci/root_hub.c [3476be8:05e21ffc] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/ohci/root_hub.c
r3476be8 r05e21ffc 41 41 #include "usb/classes/classes.h" 42 42 #include "usb/devdrv.h" 43 #include "ohci_regs.h"44 45 43 #include <usb/request.h> 46 44 #include <usb/classes/hub.h> … … 111 109 */ 112 110 static const uint32_t hub_clear_feature_valid_mask = 113 RHS_OCIC_FLAG|114 RHS_CLEAR_PORT_POWER;111 (1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER) | 112 (1 << USB_HUB_FEATURE_C_HUB_OVER_CURRENT); 115 113 116 114 /** … … 118 116 */ 119 117 static const uint32_t hub_clear_feature_by_writing_one_mask = 120 RHS_CLEAR_PORT_POWER; 121 // 1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER; 118 1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER; 122 119 123 120 /** … … 125 122 */ 126 123 static const uint32_t hub_set_feature_valid_mask = 127 RHS_LPSC_FLAG | 128 RHS_OCIC_FLAG; 129 //(1 << USB_HUB_FEATURE_C_HUB_OVER_CURRENT) | 130 //(1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER); 124 (1 << USB_HUB_FEATURE_C_HUB_OVER_CURRENT) | 125 (1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER); 131 126 132 127 /** … … 134 129 */ 135 130 static const uint32_t hub_set_feature_direct_mask = 136 RHS_SET_PORT_POWER; 137 //(1 << USB_HUB_FEATURE_C_HUB_OVER_CURRENT); 131 (1 << USB_HUB_FEATURE_C_HUB_OVER_CURRENT); 138 132 139 133 /** … … 141 135 */ 142 136 static const uint32_t port_set_feature_valid_mask = 143 RHPS_SET_PORT_ENABLE|144 RHPS_SET_PORT_SUSPEND|145 RHPS_SET_PORT_RESET|146 RHPS_SET_PORT_POWER;137 (1 << USB_HUB_FEATURE_PORT_ENABLE) | 138 (1 << USB_HUB_FEATURE_PORT_SUSPEND) | 139 (1 << USB_HUB_FEATURE_PORT_RESET) | 140 (1 << USB_HUB_FEATURE_PORT_POWER); 147 141 148 142 /** … … 150 144 */ 151 145 static const uint32_t port_clear_feature_valid_mask = 152 RHPS_CCS_FLAG |153 RHPS_SET_PORT_SUSPEND |154 RHPS_POCI_FLAG |155 RHPS_SET_PORT_POWER |156 RHPS_CSC_FLAG |157 RHPS_PESC_FLAG |158 RHPS_PSSC_FLAG |159 RHPS_OCIC_FLAG |160 RHPS_PRSC_FLAG;161 162 /*163 164 146 (1 << USB_HUB_FEATURE_PORT_CONNECTION) | 165 147 (1 << USB_HUB_FEATURE_PORT_SUSPEND) | … … 171 153 (1 << USB_HUB_FEATURE_C_PORT_OVER_CURRENT) | 172 154 (1 << USB_HUB_FEATURE_C_PORT_RESET); 173 */174 155 //note that USB_HUB_FEATURE_PORT_POWER bit is translated into 175 //USB_HUB_FEATURE_PORT_LOW_SPEED for port set feature request156 //USB_HUB_FEATURE_PORT_LOW_SPEED 176 157 177 158 /** 178 159 * bitmask with port status changes 179 160 */ 180 static const uint32_t port_status_change_mask = RHPS_CHANGE_WC_MASK;181 /*(1 << USB_HUB_FEATURE_C_PORT_CONNECTION) |161 static const uint32_t port_status_change_mask = 162 (1 << USB_HUB_FEATURE_C_PORT_CONNECTION) | 182 163 (1 << USB_HUB_FEATURE_C_PORT_ENABLE) | 183 164 (1 << USB_HUB_FEATURE_C_PORT_OVER_CURRENT) | 184 165 (1 << USB_HUB_FEATURE_C_PORT_RESET) | 185 166 (1 << USB_HUB_FEATURE_C_PORT_SUSPEND); 186 */ 167 187 168 188 169 static int create_serialized_hub_descriptor(rh_t *instance); … … 256 237 return ENOMEM; 257 238 258 usb_log_info("OHCI root hub with % zuports initialized.\n",239 usb_log_info("OHCI root hub with %d ports initialized.\n", 259 240 instance->port_count); 260 241
Note:
See TracChangeset
for help on using the changeset viewer.