aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorRemy Bohmer2008-10-10 10:23:22 +0200
committerMarkus Klotzbuecher2008-10-14 16:43:06 +0200
commit9dbc366744960013965fce8851035b6141f3b3ae (patch)
tree32ce48313c2edb817abc02651543b18fffa05b1e /drivers
parent48867208444cb2a82e2af9c3249e90b7ed4a1751 (diff)
The PIPE_INTERRUPT flag is used wrong
At a lot of places in the code the PIPE_INTERRUPT flags and friends are used wrong. The wrong bits are compared to this flag resulting in wrong conditions. Also there are macros that should be used for PIPE_* flags. This patch tries to fix them all, however, I was not able to test the changes, because I do not have any of these boards. Review required! Signed-off-by: Remy Bohmer <linux@bohmer.net> Signed-off-by: Markus Klotzbuecher <mk@denx.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/isp116x-hcd.c4
-rw-r--r--drivers/usb/r8a66597-hcd.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/drivers/usb/isp116x-hcd.c b/drivers/usb/isp116x-hcd.c
index 6b9b23bc6ed..cc46dfe9f3a 100644
--- a/drivers/usb/isp116x-hcd.c
+++ b/drivers/usb/isp116x-hcd.c
@@ -687,7 +687,7 @@ retry_same:
/* Start the data transfer */
/* Allow more time for a BULK device to react - some are slow */
- if (usb_pipetype(pipe) == PIPE_BULK)
+ if (usb_pipebulk(pipe))
timeout = 5000;
else
timeout = 100;
@@ -822,7 +822,7 @@ static int isp116x_submit_rh_msg(struct usb_device *dev, unsigned long pipe,
u16 wIndex;
u16 wLength;
- if ((pipe & PIPE_INTERRUPT) == PIPE_INTERRUPT) {
+ if (usb_pipeint(pipe)) {
INFO("Root-Hub submit IRQ: NOT implemented");
return 0;
}
diff --git a/drivers/usb/r8a66597-hcd.c b/drivers/usb/r8a66597-hcd.c
index a2e1fffcc0e..288f41a8b83 100644
--- a/drivers/usb/r8a66597-hcd.c
+++ b/drivers/usb/r8a66597-hcd.c
@@ -654,7 +654,7 @@ static int r8a66597_submit_rh_msg(struct usb_device *dev, unsigned long pipe,
R8A66597_DPRINT("%s\n", __func__);
- if ((pipe & PIPE_INTERRUPT) == PIPE_INTERRUPT) {
+ if (usb_pipeint(pipe)) {
printf("Root-Hub submit IRQ: NOT implemented");
return 0;
}