ia64/linux-2.6.18-xen.hg

changeset 854:950b9eb27661

usbback: fix urb interval value for interrupt urbs.

Signed-off-by: Noboru Iwamatsu <n_iwamatsu@jp.fujitsu.com>
author Keir Fraser <keir.fraser@citrix.com>
date Mon Apr 06 13:51:20 2009 +0100 (2009-04-06)
parents 711e402bc141
children b8bef3d2d3c3 e5d3f2fa3428
files drivers/xen/usbback/usbback.c
line diff
     1.1 --- a/drivers/xen/usbback/usbback.c	Mon Apr 06 13:48:03 2009 +0100
     1.2 +++ b/drivers/xen/usbback/usbback.c	Mon Apr 06 13:51:20 2009 +0100
     1.3 @@ -470,6 +470,18 @@ static void usbbk_init_urb(usbif_request
     1.4  				pending_req->buffer, req->buffer_length,
     1.5  				usbbk_urb_complete,
     1.6  				pending_req, req->u.intr.interval);
     1.7 +		/*
     1.8 +		 * high speed interrupt endpoints use a logarithmic encoding of
     1.9 +		 * the endpoint interval, and usb_fill_int_urb() initializes a
    1.10 +		 * interrupt urb with the encoded interval value.
    1.11 +		 *
    1.12 +		 * req->u.intr.interval is the interval value that already
    1.13 +		 * encoded in the frontend part, and the above usb_fill_int_urb()
    1.14 +		 * initializes the urb->interval with double encoded value.
    1.15 +		 *
    1.16 +		 * so, simply overwrite the urb->interval with original value.
    1.17 +		 */
    1.18 +		urb->interval = req->u.intr.interval;
    1.19  		urb->transfer_flags = req->transfer_flags;
    1.20  
    1.21  		break;