[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20200421133019.27167-6-matwey.kornilov@gmail.com>
Date: Tue, 21 Apr 2020 16:30:18 +0300
From: matwey.kornilov@...il.com
To: stern@...land.harvard.edu, Bin Liu <b-liu@...com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
linux-usb@...r.kernel.org (open list:MUSB MULTIPOINT HIGH SPEED
DUAL-ROLE CONTROLLER), linux-kernel@...r.kernel.org (open list)
Cc: "Matwey V. Kornilov" <matwey@....msu.ru>,
linux-usb@...r.kernel.org (open list:MUSB MULTIPOINT HIGH SPEED
DUAL-ROLE CONTROLLER), linux-kernel@...r.kernel.org (open list)
Subject: [PATCH v3 5/6] usb: musb: Introduce musb_start_urb()
From: "Matwey V. Kornilov" <matwey@....msu.ru>
This function allows us to start arbitrary urb.
Signed-off-by: Matwey V. Kornilov <matwey@....msu.ru>
---
drivers/usb/musb/musb_host.c | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c
index c3c9aa8ba973..46d9dd7d6f67 100644
--- a/drivers/usb/musb/musb_host.c
+++ b/drivers/usb/musb/musb_host.c
@@ -213,11 +213,10 @@ static struct musb_qh *musb_ep_get_qh(struct musb_hw_ep *ep, int is_in)
* Context: controller locked, irqs blocked
*/
static void
-musb_start_next_urb(struct musb *musb, int is_in, struct musb_qh *qh)
+musb_start_urb(struct musb *musb, int is_in, struct musb_qh *qh, struct urb *urb)
{
u32 len;
void __iomem *mbase = musb->mregs;
- struct urb *urb = next_urb(qh);
void *buf = urb->transfer_buffer;
u32 offset = 0;
struct musb_hw_ep *hw_ep = qh->hw_ep;
@@ -293,6 +292,14 @@ musb_start_next_urb(struct musb *musb, int is_in, struct musb_qh *qh)
}
}
+static void
+musb_start_next_urb(struct musb *musb, int is_in, struct musb_qh *qh)
+{
+ struct urb *urb = next_urb(qh);
+
+ musb_start_urb(musb, is_in, qh, urb);
+}
+
/* Context: caller owns controller lock, IRQs are blocked */
static void musb_giveback(struct musb *musb, struct urb *urb, int status)
__releases(musb->lock)
--
2.25.0
Powered by blists - more mailing lists