Changeset 3bb6b35 in mainline for uspace/drv/ohci/root_hub.c
- Timestamp:
- 2011-04-03T21:50:40Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 040ab02
- Parents:
- 195890b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/ohci/root_hub.c
r195890b r3bb6b35 108 108 109 109 static const uint32_t hub_clear_feature_valid_mask = 110 (1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER) +110 (1 << USB_HUB_FEATURE_C_HUB_LOCAL_POWER) | 111 111 (1 << USB_HUB_FEATURE_C_HUB_OVER_CURRENT); 112 112 … … 122 122 123 123 static const uint32_t port_set_feature_valid_mask = 124 (1 << USB_HUB_FEATURE_PORT_ENABLE) +125 (1 << USB_HUB_FEATURE_PORT_SUSPEND) +126 (1 << USB_HUB_FEATURE_PORT_RESET) +124 (1 << USB_HUB_FEATURE_PORT_ENABLE) | 125 (1 << USB_HUB_FEATURE_PORT_SUSPEND) | 126 (1 << USB_HUB_FEATURE_PORT_RESET) | 127 127 (1 << USB_HUB_FEATURE_PORT_POWER); 128 128 129 129 static const uint32_t port_clear_feature_valid_mask = 130 (1 << USB_HUB_FEATURE_PORT_CONNECTION) +131 (1 << USB_HUB_FEATURE_PORT_SUSPEND) +132 (1 << USB_HUB_FEATURE_PORT_OVER_CURRENT) +133 (1 << USB_HUB_FEATURE_PORT_POWER) +134 (1 << USB_HUB_FEATURE_C_PORT_CONNECTION) +135 (1 << USB_HUB_FEATURE_C_PORT_ENABLE) +136 (1 << USB_HUB_FEATURE_C_PORT_SUSPEND) +137 (1 << USB_HUB_FEATURE_C_PORT_OVER_CURRENT) +130 (1 << USB_HUB_FEATURE_PORT_CONNECTION) | 131 (1 << USB_HUB_FEATURE_PORT_SUSPEND) | 132 (1 << USB_HUB_FEATURE_PORT_OVER_CURRENT) | 133 (1 << USB_HUB_FEATURE_PORT_POWER) | 134 (1 << USB_HUB_FEATURE_C_PORT_CONNECTION) | 135 (1 << USB_HUB_FEATURE_C_PORT_ENABLE) | 136 (1 << USB_HUB_FEATURE_C_PORT_SUSPEND) | 137 (1 << USB_HUB_FEATURE_C_PORT_OVER_CURRENT) | 138 138 (1 << USB_HUB_FEATURE_C_PORT_RESET); 139 139 //note that USB_HUB_FEATURE_PORT_POWER bit is translated into … … 165 165 166 166 static int process_hub_feature_set_request(rh_t *instance, uint16_t feature); 167 168 167 169 168 static int process_hub_feature_clear_request(rh_t *instance, … … 204 203 instance->port_count = instance->registers->rh_desc_a & 0xff; 205 204 rh_init_descriptors(instance); 206 /// \TODO set port power mode 207 205 // set port power mode to no-power-switching 206 instance->registers->rh_desc_a = 207 instance->registers->rh_desc_a | (1<<9); 208 208 209 209 usb_log_info("OHCI root hub with %d ports.\n", instance->port_count);
Note:
See TracChangeset
for help on using the changeset viewer.