summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorIlya Yanok <ilya.yanok@cogentembedded.com>2012-11-06 13:48:20 +0000
committerMarek Vasut <marex@denx.de>2012-11-20 00:16:06 +0100
commitc60795f41d37600b6ebd79ec99252ec2f5efecd4 (patch)
treedb0d743573e872b7c5d3e77a38bf2f1d0948c794 /common
parent82651c39f6544e932fb86853bf9a648414ccca9a (diff)
usb: use linux/usb/ch9.h instead of usbdescriptors.h
Linux usb/ch9.h seems to have all the same information (and more) as usbdescriptors.h so use the former instead of the later one. As a consequense of this change USB_SPEED_* values don't correspond directly to EHCI speed encoding anymore, I've added necessary recoding in EHCI driver. Also there is no point to put speed into pipe anymore so it's removed and a bunch of host drivers fixed to look at usb_device->speed instead. Old usbdescriptors.h included is not removed as it seems to be used by old USB device code. This makes usb.h and usbdevice.h incompatible. Fortunately the only place that tries to include both are the old MUSB code and it needs usb.h only for USB_DMA_MINALIGN used in aligned attribute on musb_regs structure but this attribute seems to be unneeded (old MUSB code doesn't support any DMA at all). Signed-off-by: Ilya Yanok <ilya.yanok@cogentembedded.com>
Diffstat (limited to 'common')
-rw-r--r--common/cmd_usb.c2
-rw-r--r--common/usb.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/common/cmd_usb.c b/common/cmd_usb.c
index 8ad0b23058..dacdc2d5b1 100644
--- a/common/cmd_usb.c
+++ b/common/cmd_usb.c
@@ -192,7 +192,7 @@ static void usb_display_desc(struct usb_device *dev)
}
-static void usb_display_conf_desc(struct usb_configuration_descriptor *config,
+static void usb_display_conf_desc(struct usb_config_descriptor *config,
struct usb_device *dev)
{
printf(" Configuration: %d\n", config->bConfigurationValue);
diff --git a/common/usb.c b/common/usb.c
index 50b81752eb..ac9b4ca8d5 100644
--- a/common/usb.c
+++ b/common/usb.c
@@ -492,9 +492,9 @@ int usb_get_configuration_no(struct usb_device *dev,
{
int result;
unsigned int tmp;
- struct usb_configuration_descriptor *config;
+ struct usb_config_descriptor *config;
- config = (struct usb_configuration_descriptor *)&buffer[0];
+ config = (struct usb_config_descriptor *)&buffer[0];
result = usb_get_descriptor(dev, USB_DT_CONFIG, cfgno, buffer, 9);
if (result < 9) {
if (result < 0)