aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/host')
-rw-r--r--drivers/usb/host/ehci-hcd.c2
-rw-r--r--drivers/usb/host/ehci-q.c2
-rw-r--r--drivers/usb/host/ehci-sched.c19
-rw-r--r--drivers/usb/host/hc_crisv10.c10
-rw-r--r--drivers/usb/host/isp116x-hcd.c20
-rw-r--r--drivers/usb/host/ohci-hcd.c6
-rw-r--r--drivers/usb/host/ohci-hub.c3
-rw-r--r--drivers/usb/host/ohci-mem.c4
-rw-r--r--drivers/usb/host/ohci-omap.c53
-rw-r--r--drivers/usb/host/sl811-hcd.c2
-rw-r--r--drivers/usb/host/uhci-q.c2
11 files changed, 53 insertions, 70 deletions
diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c
index 35248a37b717..149b13fc0a71 100644
--- a/drivers/usb/host/ehci-hcd.c
+++ b/drivers/usb/host/ehci-hcd.c
@@ -960,7 +960,7 @@ static int ehci_urb_enqueue (
960 struct usb_hcd *hcd, 960 struct usb_hcd *hcd,
961 struct usb_host_endpoint *ep, 961 struct usb_host_endpoint *ep,
962 struct urb *urb, 962 struct urb *urb,
963 int mem_flags 963 unsigned mem_flags
964) { 964) {
965 struct ehci_hcd *ehci = hcd_to_ehci (hcd); 965 struct ehci_hcd *ehci = hcd_to_ehci (hcd);
966 struct list_head qtd_list; 966 struct list_head qtd_list;
diff --git a/drivers/usb/host/ehci-q.c b/drivers/usb/host/ehci-q.c
index 45d89a7083b1..d74b2d68a50e 100644
--- a/drivers/usb/host/ehci-q.c
+++ b/drivers/usb/host/ehci-q.c
@@ -898,7 +898,7 @@ submit_async (
898 struct usb_host_endpoint *ep, 898 struct usb_host_endpoint *ep,
899 struct urb *urb, 899 struct urb *urb,
900 struct list_head *qtd_list, 900 struct list_head *qtd_list,
901 int mem_flags 901 unsigned mem_flags
902) { 902) {
903 struct ehci_qtd *qtd; 903 struct ehci_qtd *qtd;
904 int epnum; 904 int epnum;
diff --git a/drivers/usb/host/ehci-sched.c b/drivers/usb/host/ehci-sched.c
index c2104cad4033..9af4f64532a9 100644
--- a/drivers/usb/host/ehci-sched.c
+++ b/drivers/usb/host/ehci-sched.c
@@ -588,7 +588,7 @@ static int intr_submit (
588 struct usb_host_endpoint *ep, 588 struct usb_host_endpoint *ep,
589 struct urb *urb, 589 struct urb *urb,
590 struct list_head *qtd_list, 590 struct list_head *qtd_list,
591 int mem_flags 591 unsigned mem_flags
592) { 592) {
593 unsigned epnum; 593 unsigned epnum;
594 unsigned long flags; 594 unsigned long flags;
@@ -633,7 +633,7 @@ done:
633/* ehci_iso_stream ops work with both ITD and SITD */ 633/* ehci_iso_stream ops work with both ITD and SITD */
634 634
635static struct ehci_iso_stream * 635static struct ehci_iso_stream *
636iso_stream_alloc (int mem_flags) 636iso_stream_alloc (unsigned mem_flags)
637{ 637{
638 struct ehci_iso_stream *stream; 638 struct ehci_iso_stream *stream;
639 639
@@ -846,7 +846,7 @@ iso_stream_find (struct ehci_hcd *ehci, struct urb *urb)
846/* ehci_iso_sched ops can be ITD-only or SITD-only */ 846/* ehci_iso_sched ops can be ITD-only or SITD-only */
847 847
848static struct ehci_iso_sched * 848static struct ehci_iso_sched *
849iso_sched_alloc (unsigned packets, int mem_flags) 849iso_sched_alloc (unsigned packets, unsigned mem_flags)
850{ 850{
851 struct ehci_iso_sched *iso_sched; 851 struct ehci_iso_sched *iso_sched;
852 int size = sizeof *iso_sched; 852 int size = sizeof *iso_sched;
@@ -919,7 +919,7 @@ itd_urb_transaction (
919 struct ehci_iso_stream *stream, 919 struct ehci_iso_stream *stream,
920 struct ehci_hcd *ehci, 920 struct ehci_hcd *ehci,
921 struct urb *urb, 921 struct urb *urb,
922 int mem_flags 922 unsigned mem_flags
923) 923)
924{ 924{
925 struct ehci_itd *itd; 925 struct ehci_itd *itd;
@@ -1412,7 +1412,8 @@ itd_complete (
1412 1412
1413/*-------------------------------------------------------------------------*/ 1413/*-------------------------------------------------------------------------*/
1414 1414
1415static int itd_submit (struct ehci_hcd *ehci, struct urb *urb, int mem_flags) 1415static int itd_submit (struct ehci_hcd *ehci, struct urb *urb,
1416 unsigned mem_flags)
1416{ 1417{
1417 int status = -EINVAL; 1418 int status = -EINVAL;
1418 unsigned long flags; 1419 unsigned long flags;
@@ -1523,7 +1524,7 @@ sitd_urb_transaction (
1523 struct ehci_iso_stream *stream, 1524 struct ehci_iso_stream *stream,
1524 struct ehci_hcd *ehci, 1525 struct ehci_hcd *ehci,
1525 struct urb *urb, 1526 struct urb *urb,
1526 int mem_flags 1527 unsigned mem_flags
1527) 1528)
1528{ 1529{
1529 struct ehci_sitd *sitd; 1530 struct ehci_sitd *sitd;
@@ -1772,7 +1773,8 @@ sitd_complete (
1772} 1773}
1773 1774
1774 1775
1775static int sitd_submit (struct ehci_hcd *ehci, struct urb *urb, int mem_flags) 1776static int sitd_submit (struct ehci_hcd *ehci, struct urb *urb,
1777 unsigned mem_flags)
1776{ 1778{
1777 int status = -EINVAL; 1779 int status = -EINVAL;
1778 unsigned long flags; 1780 unsigned long flags;
@@ -1822,7 +1824,8 @@ done:
1822#else 1824#else
1823 1825
1824static inline int 1826static inline int
1825sitd_submit (struct ehci_hcd *ehci, struct urb *urb, int mem_flags) 1827sitd_submit (struct ehci_hcd *ehci, struct urb *urb,
1828 unsigned mem_flags)
1826{ 1829{
1827 ehci_dbg (ehci, "split iso support is disabled\n"); 1830 ehci_dbg (ehci, "split iso support is disabled\n");
1828 return -ENOSYS; 1831 return -ENOSYS;
diff --git a/drivers/usb/host/hc_crisv10.c b/drivers/usb/host/hc_crisv10.c
index d9883d774d3a..81f8f6b7fdce 100644
--- a/drivers/usb/host/hc_crisv10.c
+++ b/drivers/usb/host/hc_crisv10.c
@@ -463,7 +463,8 @@ static void etrax_usb_free_epid(int epid);
463 463
464static int etrax_remove_from_sb_list(struct urb *urb); 464static int etrax_remove_from_sb_list(struct urb *urb);
465 465
466static void* etrax_usb_buffer_alloc(struct usb_bus* bus, size_t size, int mem_flags, dma_addr_t *dma); 466static void* etrax_usb_buffer_alloc(struct usb_bus* bus, size_t size,
467 unsigned mem_flags, dma_addr_t *dma);
467static void etrax_usb_buffer_free(struct usb_bus *bus, size_t size, void *addr, dma_addr_t dma); 468static void etrax_usb_buffer_free(struct usb_bus *bus, size_t size, void *addr, dma_addr_t dma);
468 469
469static void etrax_usb_add_to_bulk_sb_list(struct urb *urb, int epid); 470static void etrax_usb_add_to_bulk_sb_list(struct urb *urb, int epid);
@@ -476,7 +477,7 @@ static int etrax_usb_submit_ctrl_urb(struct urb *urb);
476static int etrax_usb_submit_intr_urb(struct urb *urb); 477static int etrax_usb_submit_intr_urb(struct urb *urb);
477static int etrax_usb_submit_isoc_urb(struct urb *urb); 478static int etrax_usb_submit_isoc_urb(struct urb *urb);
478 479
479static int etrax_usb_submit_urb(struct urb *urb, int mem_flags); 480static int etrax_usb_submit_urb(struct urb *urb, unsigned mem_flags);
480static int etrax_usb_unlink_urb(struct urb *urb, int status); 481static int etrax_usb_unlink_urb(struct urb *urb, int status);
481static int etrax_usb_get_frame_number(struct usb_device *usb_dev); 482static int etrax_usb_get_frame_number(struct usb_device *usb_dev);
482 483
@@ -1262,7 +1263,7 @@ static int etrax_usb_allocate_epid(void)
1262 return -1; 1263 return -1;
1263} 1264}
1264 1265
1265static int etrax_usb_submit_urb(struct urb *urb, int mem_flags) 1266static int etrax_usb_submit_urb(struct urb *urb, unsigned mem_flags)
1266{ 1267{
1267 etrax_hc_t *hc; 1268 etrax_hc_t *hc;
1268 int ret = -EINVAL; 1269 int ret = -EINVAL;
@@ -4277,7 +4278,8 @@ etrax_usb_bulk_eot_timer_func(unsigned long dummy)
4277} 4278}
4278 4279
4279static void* 4280static void*
4280etrax_usb_buffer_alloc(struct usb_bus* bus, size_t size, int mem_flags, dma_addr_t *dma) 4281etrax_usb_buffer_alloc(struct usb_bus* bus, size_t size,
4282 unsigned mem_flags, dma_addr_t *dma)
4281{ 4283{
4282 return kmalloc(size, mem_flags); 4284 return kmalloc(size, mem_flags);
4283} 4285}
diff --git a/drivers/usb/host/isp116x-hcd.c b/drivers/usb/host/isp116x-hcd.c
index ff0a168e8eed..50b1970fe6b6 100644
--- a/drivers/usb/host/isp116x-hcd.c
+++ b/drivers/usb/host/isp116x-hcd.c
@@ -17,7 +17,7 @@
17 * The driver basically works. A number of people have used it with a range 17 * The driver basically works. A number of people have used it with a range
18 * of devices. 18 * of devices.
19 * 19 *
20 *The driver passes all usbtests 1-14. 20 * The driver passes all usbtests 1-14.
21 * 21 *
22 * Suspending/resuming of root hub via sysfs works. Remote wakeup works too. 22 * Suspending/resuming of root hub via sysfs works. Remote wakeup works too.
23 * And suspending/resuming of platform device works too. Suspend/resume 23 * And suspending/resuming of platform device works too. Suspend/resume
@@ -229,7 +229,7 @@ static void preproc_atl_queue(struct isp116x *isp116x)
229 struct isp116x_ep *ep; 229 struct isp116x_ep *ep;
230 struct urb *urb; 230 struct urb *urb;
231 struct ptd *ptd; 231 struct ptd *ptd;
232 u16 toggle, dir, len; 232 u16 toggle = 0, dir = PTD_DIR_SETUP, len;
233 233
234 for (ep = isp116x->atl_active; ep; ep = ep->active) { 234 for (ep = isp116x->atl_active; ep; ep = ep->active) {
235 BUG_ON(list_empty(&ep->hep->urb_list)); 235 BUG_ON(list_empty(&ep->hep->urb_list));
@@ -251,8 +251,6 @@ static void preproc_atl_queue(struct isp116x *isp116x)
251 dir = PTD_DIR_OUT; 251 dir = PTD_DIR_OUT;
252 break; 252 break;
253 case USB_PID_SETUP: 253 case USB_PID_SETUP:
254 toggle = 0;
255 dir = PTD_DIR_SETUP;
256 len = sizeof(struct usb_ctrlrequest); 254 len = sizeof(struct usb_ctrlrequest);
257 ep->data = urb->setup_packet; 255 ep->data = urb->setup_packet;
258 break; 256 break;
@@ -264,11 +262,9 @@ static void preproc_atl_queue(struct isp116x *isp116x)
264 ? PTD_DIR_OUT : PTD_DIR_IN; 262 ? PTD_DIR_OUT : PTD_DIR_IN;
265 break; 263 break;
266 default: 264 default:
267 /* To please gcc */
268 toggle = dir = 0;
269 ERR("%s %d: ep->nextpid %d\n", __func__, __LINE__, 265 ERR("%s %d: ep->nextpid %d\n", __func__, __LINE__,
270 ep->nextpid); 266 ep->nextpid);
271 BUG_ON(1); 267 BUG();
272 } 268 }
273 269
274 ptd->count = PTD_CC_MSK | PTD_ACTIVE_MSK | PTD_TOGGLE(toggle); 270 ptd->count = PTD_CC_MSK | PTD_ACTIVE_MSK | PTD_TOGGLE(toggle);
@@ -697,7 +693,7 @@ static int balance(struct isp116x *isp116x, u16 period, u16 load)
697 693
698static int isp116x_urb_enqueue(struct usb_hcd *hcd, 694static int isp116x_urb_enqueue(struct usb_hcd *hcd,
699 struct usb_host_endpoint *hep, struct urb *urb, 695 struct usb_host_endpoint *hep, struct urb *urb,
700 int mem_flags) 696 unsigned mem_flags)
701{ 697{
702 struct isp116x *isp116x = hcd_to_isp116x(hcd); 698 struct isp116x *isp116x = hcd_to_isp116x(hcd);
703 struct usb_device *udev = urb->dev; 699 struct usb_device *udev = urb->dev;
@@ -719,7 +715,7 @@ static int isp116x_urb_enqueue(struct usb_hcd *hcd,
719 } 715 }
720 /* avoid all allocations within spinlocks: request or endpoint */ 716 /* avoid all allocations within spinlocks: request or endpoint */
721 if (!hep->hcpriv) { 717 if (!hep->hcpriv) {
722 ep = kcalloc(1, sizeof *ep, (__force unsigned)mem_flags); 718 ep = kcalloc(1, sizeof *ep, mem_flags);
723 if (!ep) 719 if (!ep)
724 return -ENOMEM; 720 return -ENOMEM;
725 } 721 }
@@ -1054,7 +1050,7 @@ static int isp116x_hub_control(struct usb_hcd *hcd,
1054 break; 1050 break;
1055 case GetHubStatus: 1051 case GetHubStatus:
1056 DBG("GetHubStatus\n"); 1052 DBG("GetHubStatus\n");
1057 *(__le32 *) buf = cpu_to_le32(0); 1053 *(__le32 *) buf = 0;
1058 break; 1054 break;
1059 case GetPortStatus: 1055 case GetPortStatus:
1060 DBG("GetPortStatus\n"); 1056 DBG("GetPortStatus\n");
@@ -1810,9 +1806,9 @@ static int isp116x_suspend(struct device *dev, pm_message_t state, u32 phase)
1810 ret = usb_suspend_device(hcd->self.root_hub, state); 1806 ret = usb_suspend_device(hcd->self.root_hub, state);
1811 if (!ret) { 1807 if (!ret) {
1812 dev->power.power_state = state; 1808 dev->power.power_state = state;
1813 INFO("%s suspended\n", (char *)hcd_name); 1809 INFO("%s suspended\n", hcd_name);
1814 } else 1810 } else
1815 ERR("%s suspend failed\n", (char *)hcd_name); 1811 ERR("%s suspend failed\n", hcd_name);
1816 1812
1817 return ret; 1813 return ret;
1818} 1814}
diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c
index 13cd2177b557..68decab280dd 100644
--- a/drivers/usb/host/ohci-hcd.c
+++ b/drivers/usb/host/ohci-hcd.c
@@ -180,7 +180,7 @@ static int ohci_urb_enqueue (
180 struct usb_hcd *hcd, 180 struct usb_hcd *hcd,
181 struct usb_host_endpoint *ep, 181 struct usb_host_endpoint *ep,
182 struct urb *urb, 182 struct urb *urb,
183 int mem_flags 183 unsigned mem_flags
184) { 184) {
185 struct ohci_hcd *ohci = hcd_to_ohci (hcd); 185 struct ohci_hcd *ohci = hcd_to_ohci (hcd);
186 struct ed *ed; 186 struct ed *ed;
@@ -673,8 +673,10 @@ retry:
673 673
674 ohci_dump (ohci, 1); 674 ohci_dump (ohci, 1);
675 675
676 if (ohci_to_hcd(ohci)->self.root_hub == NULL) 676 if (ohci_to_hcd(ohci)->self.root_hub == NULL) {
677 register_reboot_notifier (&ohci->reboot_notifier);
677 create_debug_files (ohci); 678 create_debug_files (ohci);
679 }
678 680
679 return 0; 681 return 0;
680} 682}
diff --git a/drivers/usb/host/ohci-hub.c b/drivers/usb/host/ohci-hub.c
index e2fc4129dfc6..83ca4549a50e 100644
--- a/drivers/usb/host/ohci-hub.c
+++ b/drivers/usb/host/ohci-hub.c
@@ -419,10 +419,11 @@ ohci_hub_descriptor (
419 419
420 /* two bitmaps: ports removable, and usb 1.0 legacy PortPwrCtrlMask */ 420 /* two bitmaps: ports removable, and usb 1.0 legacy PortPwrCtrlMask */
421 rh = roothub_b (ohci); 421 rh = roothub_b (ohci);
422 memset(desc->bitmap, 0xff, sizeof(desc->bitmap));
422 desc->bitmap [0] = rh & RH_B_DR; 423 desc->bitmap [0] = rh & RH_B_DR;
423 if (ports > 7) { 424 if (ports > 7) {
424 desc->bitmap [1] = (rh & RH_B_DR) >> 8; 425 desc->bitmap [1] = (rh & RH_B_DR) >> 8;
425 desc->bitmap [2] = desc->bitmap [3] = 0xff; 426 desc->bitmap [2] = 0xff;
426 } else 427 } else
427 desc->bitmap [1] = 0xff; 428 desc->bitmap [1] = 0xff;
428} 429}
diff --git a/drivers/usb/host/ohci-mem.c b/drivers/usb/host/ohci-mem.c
index 23735a36af00..fd3c4d3714bd 100644
--- a/drivers/usb/host/ohci-mem.c
+++ b/drivers/usb/host/ohci-mem.c
@@ -84,7 +84,7 @@ dma_to_td (struct ohci_hcd *hc, dma_addr_t td_dma)
84 84
85/* TDs ... */ 85/* TDs ... */
86static struct td * 86static struct td *
87td_alloc (struct ohci_hcd *hc, int mem_flags) 87td_alloc (struct ohci_hcd *hc, unsigned mem_flags)
88{ 88{
89 dma_addr_t dma; 89 dma_addr_t dma;
90 struct td *td; 90 struct td *td;
@@ -118,7 +118,7 @@ td_free (struct ohci_hcd *hc, struct td *td)
118 118
119/* EDs ... */ 119/* EDs ... */
120static struct ed * 120static struct ed *
121ed_alloc (struct ohci_hcd *hc, int mem_flags) 121ed_alloc (struct ohci_hcd *hc, unsigned mem_flags)
122{ 122{
123 dma_addr_t dma; 123 dma_addr_t dma;
124 struct ed *ed; 124 struct ed *ed;
diff --git a/drivers/usb/host/ohci-omap.c b/drivers/usb/host/ohci-omap.c
index b62d69937694..5cde76faab93 100644
--- a/drivers/usb/host/ohci-omap.c
+++ b/drivers/usb/host/ohci-omap.c
@@ -456,34 +456,22 @@ static int ohci_hcd_omap_drv_remove(struct device *dev)
456 456
457#ifdef CONFIG_PM 457#ifdef CONFIG_PM
458 458
459/* states match PCI usage, always suspending the root hub except that 459static int ohci_omap_suspend(struct device *dev, pm_message_t message, u32 level)
460 * 4 ~= D3cold (ACPI D3) with clock off (resume sees reset).
461 *
462 * FIXME: above comment is not right, and code is wrong, too :-(.
463 */
464
465static int ohci_omap_suspend(struct device *dev, pm_message_t state, u32 level)
466{ 460{
467 struct ohci_hcd *ohci = hcd_to_ohci(dev_get_drvdata(dev)); 461 struct ohci_hcd *ohci = hcd_to_ohci(dev_get_drvdata(dev));
468 int status = -EINVAL; 462 int status = -EINVAL;
469 463
470 if (level != SUSPEND_POWER_DOWN) 464 if (level != SUSPEND_POWER_DOWN)
471 return 0; 465 return 0;
472 if (state <= dev->power.power_state)
473 return 0;
474 466
475 dev_dbg(dev, "suspend to %d\n", state);
476 down(&ohci_to_hcd(ohci)->self.root_hub->serialize); 467 down(&ohci_to_hcd(ohci)->self.root_hub->serialize);
477 status = ohci_hub_suspend(ohci_to_hcd(ohci)); 468 status = ohci_hub_suspend(ohci_to_hcd(ohci));
478 if (status == 0) { 469 if (status == 0) {
479 if (state >= 4) { 470 omap_ohci_clock_power(0);
480 omap_ohci_clock_power(0); 471 ohci_to_hcd(ohci)->self.root_hub->state =
481 ohci_to_hcd(ohci)->self.root_hub->state = 472 USB_STATE_SUSPENDED;
482 USB_STATE_SUSPENDED;
483 state = 4;
484 }
485 ohci_to_hcd(ohci)->state = HC_STATE_SUSPENDED; 473 ohci_to_hcd(ohci)->state = HC_STATE_SUSPENDED;
486 dev->power.power_state = state; 474 dev->power.power_state = PMSG_SUSPEND;
487 } 475 }
488 up(&ohci_to_hcd(ohci)->self.root_hub->serialize); 476 up(&ohci_to_hcd(ohci)->self.root_hub->serialize);
489 return status; 477 return status;
@@ -497,29 +485,20 @@ static int ohci_omap_resume(struct device *dev, u32 level)
497 if (level != RESUME_POWER_ON) 485 if (level != RESUME_POWER_ON)
498 return 0; 486 return 0;
499 487
500 switch (dev->power.power_state) { 488 if (time_before(jiffies, ohci->next_statechange))
501 case 0: 489 msleep(5);
502 break; 490 ohci->next_statechange = jiffies;
503 case 4: 491 omap_ohci_clock_power(1);
504 if (time_before(jiffies, ohci->next_statechange))
505 msleep(5);
506 ohci->next_statechange = jiffies;
507 omap_ohci_clock_power(1);
508 /* FALLTHROUGH */
509 default:
510 dev_dbg(dev, "resume from %d\n", dev->power.power_state);
511#ifdef CONFIG_USB_SUSPEND 492#ifdef CONFIG_USB_SUSPEND
512 /* get extra cleanup even if remote wakeup isn't in use */ 493 /* get extra cleanup even if remote wakeup isn't in use */
513 status = usb_resume_device(ohci_to_hcd(ohci)->self.root_hub); 494 status = usb_resume_device(ohci_to_hcd(ohci)->self.root_hub);
514#else 495#else
515 down(&ohci_to_hcd(ohci)->self.root_hub->serialize); 496 down(&ohci_to_hcd(ohci)->self.root_hub->serialize);
516 status = ohci_hub_resume(ohci_to_hcd(ohci)); 497 status = ohci_hub_resume(ohci_to_hcd(ohci));
517 up(&ohci_to_hcd(ohci)->self.root_hub->serialize); 498 up(&ohci_to_hcd(ohci)->self.root_hub->serialize);
518#endif 499#endif
519 if (status == 0) 500 if (status == 0)
520 dev->power.power_state = 0; 501 dev->power.power_state = PMSG_ON;
521 break;
522 }
523 return status; 502 return status;
524} 503}
525 504
diff --git a/drivers/usb/host/sl811-hcd.c b/drivers/usb/host/sl811-hcd.c
index 6c3f910bc307..7a890a65f55d 100644
--- a/drivers/usb/host/sl811-hcd.c
+++ b/drivers/usb/host/sl811-hcd.c
@@ -815,7 +815,7 @@ static int sl811h_urb_enqueue(
815 struct usb_hcd *hcd, 815 struct usb_hcd *hcd,
816 struct usb_host_endpoint *hep, 816 struct usb_host_endpoint *hep,
817 struct urb *urb, 817 struct urb *urb,
818 int mem_flags 818 unsigned mem_flags
819) { 819) {
820 struct sl811 *sl811 = hcd_to_sl811(hcd); 820 struct sl811 *sl811 = hcd_to_sl811(hcd);
821 struct usb_device *udev = urb->dev; 821 struct usb_device *udev = urb->dev;
diff --git a/drivers/usb/host/uhci-q.c b/drivers/usb/host/uhci-q.c
index 5f18084a116d..bbb36cd6ed61 100644
--- a/drivers/usb/host/uhci-q.c
+++ b/drivers/usb/host/uhci-q.c
@@ -1164,7 +1164,7 @@ static struct urb *uhci_find_urb_ep(struct uhci_hcd *uhci, struct urb *urb)
1164 1164
1165static int uhci_urb_enqueue(struct usb_hcd *hcd, 1165static int uhci_urb_enqueue(struct usb_hcd *hcd,
1166 struct usb_host_endpoint *ep, 1166 struct usb_host_endpoint *ep,
1167 struct urb *urb, int mem_flags) 1167 struct urb *urb, unsigned mem_flags)
1168{ 1168{
1169 int ret; 1169 int ret;
1170 struct uhci_hcd *uhci = hcd_to_uhci(hcd); 1170 struct uhci_hcd *uhci = hcd_to_uhci(hcd);