|  | @@ -243,7 +243,6 @@ int usb_endpoint_described ( struct usb_endpoint *ep,
 | 
		
	
		
			
			| 243 | 243 |  			     struct usb_interface_descriptor *interface,
 | 
		
	
		
			
			| 244 | 244 |  			     unsigned int type, unsigned int index ) {
 | 
		
	
		
			
			| 245 | 245 |  	struct usb_device *usb = ep->usb;
 | 
		
	
		
			
			| 246 |  | -	struct usb_port *port = usb->port;
 | 
		
	
		
			
			| 247 | 246 |  	struct usb_endpoint_descriptor *desc;
 | 
		
	
		
			
			| 248 | 247 |  	struct usb_endpoint_companion_descriptor *descx;
 | 
		
	
		
			
			| 249 | 248 |  	unsigned int sizes;
 | 
		
	
	
		
			
			|  | @@ -267,7 +266,7 @@ int usb_endpoint_described ( struct usb_endpoint *ep,
 | 
		
	
		
			
			| 267 | 266 |  	/* Calculate interval */
 | 
		
	
		
			
			| 268 | 267 |  	if ( ( type & USB_ENDPOINT_ATTR_TYPE_MASK ) ==
 | 
		
	
		
			
			| 269 | 268 |  	     USB_ENDPOINT_ATTR_INTERRUPT ) {
 | 
		
	
		
			
			| 270 |  | -		if ( port->speed >= USB_SPEED_HIGH ) {
 | 
		
	
		
			
			|  | 269 | +		if ( usb->speed >= USB_SPEED_HIGH ) {
 | 
		
	
		
			
			| 271 | 270 |  			/* 2^(desc->interval-1) is a microframe count */
 | 
		
	
		
			
			| 272 | 271 |  			interval = ( 1 << ( desc->interval - 1 ) );
 | 
		
	
		
			
			| 273 | 272 |  		} else {
 | 
		
	
	
		
			
			|  | @@ -1492,8 +1491,9 @@ static int register_usb ( struct usb_device *usb ) {
 | 
		
	
		
			
			| 1492 | 1491 |  		       hub->name, port->address, strerror ( rc ) );
 | 
		
	
		
			
			| 1493 | 1492 |  		goto err_speed;
 | 
		
	
		
			
			| 1494 | 1493 |  	}
 | 
		
	
		
			
			|  | 1494 | +	usb->speed = port->speed;
 | 
		
	
		
			
			| 1495 | 1495 |  	DBGC2 ( usb, "USB %s attached as %s-speed device\n",
 | 
		
	
		
			
			| 1496 |  | -		usb->name, usb_speed_name ( port->speed ) );
 | 
		
	
		
			
			|  | 1496 | +		usb->name, usb_speed_name ( usb->speed ) );
 | 
		
	
		
			
			| 1497 | 1497 |  
 | 
		
	
		
			
			| 1498 | 1498 |  	/* Open device */
 | 
		
	
		
			
			| 1499 | 1499 |  	if ( ( rc = usb->host->open ( usb ) ) != 0 ) {
 | 
		
	
	
		
			
			|  | @@ -1503,7 +1503,7 @@ static int register_usb ( struct usb_device *usb ) {
 | 
		
	
		
			
			| 1503 | 1503 |  	}
 | 
		
	
		
			
			| 1504 | 1504 |  
 | 
		
	
		
			
			| 1505 | 1505 |  	/* Describe control endpoint */
 | 
		
	
		
			
			| 1506 |  | -	mtu = USB_EP0_DEFAULT_MTU ( port->speed );
 | 
		
	
		
			
			|  | 1506 | +	mtu = USB_EP0_DEFAULT_MTU ( usb->speed );
 | 
		
	
		
			
			| 1507 | 1507 |  	usb_endpoint_describe ( &usb->control, USB_EP0_ADDRESS,
 | 
		
	
		
			
			| 1508 | 1508 |  				USB_EP0_ATTRIBUTES, mtu, USB_EP0_BURST,
 | 
		
	
		
			
			| 1509 | 1509 |  				USB_EP0_INTERVAL );
 | 
		
	
	
		
			
			|  | @@ -1554,7 +1554,7 @@ static int register_usb ( struct usb_device *usb ) {
 | 
		
	
		
			
			| 1554 | 1554 |  	       le16_to_cpu ( usb->device.product ), usb->device.class.class,
 | 
		
	
		
			
			| 1555 | 1555 |  	       usb->device.class.subclass, usb->device.class.protocol,
 | 
		
	
		
			
			| 1556 | 1556 |  	       usb_bcd ( le16_to_cpu ( usb->device.protocol ) ),
 | 
		
	
		
			
			| 1557 |  | -	       usb_speed_name ( port->speed ), usb->control.mtu );
 | 
		
	
		
			
			|  | 1557 | +	       usb_speed_name ( usb->speed ), usb->control.mtu );
 | 
		
	
		
			
			| 1558 | 1558 |  
 | 
		
	
		
			
			| 1559 | 1559 |  	/* Configure device */
 | 
		
	
		
			
			| 1560 | 1560 |  	if ( ( rc = usb_autoconfigure ( usb ) ) != 0 )
 | 
		
	
	
		
			
			|  | @@ -2233,12 +2233,12 @@ struct usb_port * usb_transaction_translator ( struct usb_device *usb ) {
 | 
		
	
		
			
			| 2233 | 2233 |  	struct usb_device *parent;
 | 
		
	
		
			
			| 2234 | 2234 |  
 | 
		
	
		
			
			| 2235 | 2235 |  	/* Navigate up to root hub.  If we find a low-speed or
 | 
		
	
		
			
			| 2236 |  | -	 * full-speed port with a higher-speed parent device, then
 | 
		
	
		
			
			| 2237 |  | -	 * that port is the transaction translator.
 | 
		
	
		
			
			|  | 2236 | +	 * full-speed device with a higher-speed parent hub, then that
 | 
		
	
		
			
			|  | 2237 | +	 * device's port is the transaction translator.
 | 
		
	
		
			
			| 2238 | 2238 |  	 */
 | 
		
	
		
			
			| 2239 | 2239 |  	for ( ; ( parent = usb->port->hub->usb ) ; usb = parent ) {
 | 
		
	
		
			
			| 2240 |  | -		if ( ( usb->port->speed <= USB_SPEED_FULL ) &&
 | 
		
	
		
			
			| 2241 |  | -		     ( parent->port->speed > USB_SPEED_FULL ) )
 | 
		
	
		
			
			|  | 2240 | +		if ( ( usb->speed <= USB_SPEED_FULL ) &&
 | 
		
	
		
			
			|  | 2241 | +		     ( parent->speed > USB_SPEED_FULL ) )
 | 
		
	
		
			
			| 2242 | 2242 |  			return usb->port;
 | 
		
	
		
			
			| 2243 | 2243 |  	}
 | 
		
	
		
			
			| 2244 | 2244 |  
 |