Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1298709
| From | Robert Baldyga <r.baldyga@samsung.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 1/5] usb: dwc2: gadget: use ep->fifo_index in context of FIFO registers |
| Date | 2015-12-28 17:30 +0100 |
| Message-ID | <qKIQk-4yb-33@gated-at.bofh.it> (permalink) |
| References | <qKIQi-4yb-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
In context of FIFO registers we use ep->fifo_index instead of ep->index.
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
---
drivers/usb/dwc2/gadget.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c
index 4e9fc92..773d121 100644
--- a/drivers/usb/dwc2/gadget.c
+++ b/drivers/usb/dwc2/gadget.c
@@ -369,7 +369,8 @@ static int dwc2_hsotg_write_fifo(struct dwc2_hsotg *hsotg,
return -ENOSPC;
}
} else if (hsotg->dedicated_fifos && hs_ep->index != 0) {
- can_write = dwc2_readl(hsotg->regs + DTXFSTS(hs_ep->index));
+ can_write = dwc2_readl(hsotg->regs +
+ DTXFSTS(hs_ep->fifo_index));
can_write &= 0xffff;
can_write *= 4;
@@ -2172,7 +2173,7 @@ static void kill_all_requests(struct dwc2_hsotg *hsotg,
if (!hsotg->dedicated_fifos)
return;
- size = (dwc2_readl(hsotg->regs + DTXFSTS(ep->index)) & 0xffff) * 4;
+ size = (dwc2_readl(hsotg->regs + DTXFSTS(ep->fifo_index)) & 0xffff) * 4;
if (size < ep->fifo_size)
dwc2_hsotg_txfifo_flush(hsotg, ep->fifo_index);
}
--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH 0/5] usb: dwc2: gadget: Fix TX FIFO handling Robert Baldyga <r.baldyga@samsung.com> - 2015-12-28 17:30 +0100 [PATCH 3/5] usb: dwc2: gadget: change variable name to more meaningful Robert Baldyga <r.baldyga@samsung.com> - 2015-12-28 17:30 +0100 [PATCH 2/5] usb: dwc2: gadget: fix TX FIFO size and address initialization Robert Baldyga <r.baldyga@samsung.com> - 2015-12-28 17:30 +0100 [PATCH 1/5] usb: dwc2: gadget: use ep->fifo_index in context of FIFO registers Robert Baldyga <r.baldyga@samsung.com> - 2015-12-28 17:30 +0100
csiph-web