diff options
| author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2012-10-22 16:14:58 -0400 |
|---|---|---|
| committer | Felipe Balbi <balbi@ti.com> | 2012-10-31 09:02:58 -0400 |
| commit | 64dce9144507d4a6c624fe1b8e0aa88daeae0b9b (patch) | |
| tree | 152fd7ad3f073566faf9c45e58b2f18e51ba297c | |
| parent | bcb2f99c6c43a8da6cb4002e8b0acf6f1275f3a8 (diff) | |
usb: gadget storage: use a computation macro for INT endpoint interval
The 9 for HS means 32ms. Use the macro to make it easier to read.
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
| -rw-r--r-- | drivers/usb/gadget/storage_common.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/gadget/storage_common.c b/drivers/usb/gadget/storage_common.c index 8d9bcd8207c8..14199d70beea 100644 --- a/drivers/usb/gadget/storage_common.c +++ b/drivers/usb/gadget/storage_common.c | |||
| @@ -441,7 +441,7 @@ fsg_hs_intr_in_desc = { | |||
| 441 | /* bEndpointAddress copied from fs_intr_in_desc during fsg_bind() */ | 441 | /* bEndpointAddress copied from fs_intr_in_desc during fsg_bind() */ |
| 442 | .bmAttributes = USB_ENDPOINT_XFER_INT, | 442 | .bmAttributes = USB_ENDPOINT_XFER_INT, |
| 443 | .wMaxPacketSize = cpu_to_le16(2), | 443 | .wMaxPacketSize = cpu_to_le16(2), |
| 444 | .bInterval = 9, /* 2**(9-1) = 256 uframes -> 32 ms */ | 444 | .bInterval = USB_MS_TO_HS_INTERVAL(32), /* 32 ms */ |
| 445 | }; | 445 | }; |
| 446 | 446 | ||
| 447 | #ifndef FSG_NO_OTG | 447 | #ifndef FSG_NO_OTG |
| @@ -509,7 +509,7 @@ fsg_ss_intr_in_desc = { | |||
| 509 | /* bEndpointAddress copied from fs_intr_in_desc during fsg_bind() */ | 509 | /* bEndpointAddress copied from fs_intr_in_desc during fsg_bind() */ |
| 510 | .bmAttributes = USB_ENDPOINT_XFER_INT, | 510 | .bmAttributes = USB_ENDPOINT_XFER_INT, |
| 511 | .wMaxPacketSize = cpu_to_le16(2), | 511 | .wMaxPacketSize = cpu_to_le16(2), |
| 512 | .bInterval = 9, /* 2**(9-1) = 256 uframes -> 32 ms */ | 512 | .bInterval = USB_MS_TO_HS_INTERVAL(32), /* 32 ms */ |
| 513 | }; | 513 | }; |
| 514 | 514 | ||
| 515 | static struct usb_ss_ep_comp_descriptor fsg_ss_intr_in_comp_desc = { | 515 | static struct usb_ss_ep_comp_descriptor fsg_ss_intr_in_comp_desc = { |
