Hi,
John Youn writes:
>> John Youn writes:
John Youn writes:
>>> @@ -1812,17 +1812,17 @@ static u32 dwc2_hsotg_ep0_mps(unsigned int mps)
>>> * @hsotg: The driver state.
>>> * @ep: The index number of the endpoint
>>> * @mps: The maximum packet size in bytes
>>> +
Hi,
John Youn writes:
>> + dwc3_writel(dwc->regs, DWC3_GEVNTCOUNT(0), count);
>> +
After that evt->buf[lpos, lpos + count] seems goes back to HW, so
thread should not rely on this?
Or I miss something?
>>>
>>> Hi,
>>>
>>> Yes, you're right. That's a possibility
On Tue, 1 Nov 2016, Lu Baolu wrote:
> +static int __init xdbc_init(void)
> +{
...
> + base = ioremap_nocache(xdbc.xhci_start, xdbc.xhci_length);
> + if (!base) {
> + xdbc_trace("failed to remap the io address\n");
> + ret = -ENOMEM;
> + goto free_and_quit
On Tue, 1 Nov 2016, Lu Baolu wrote:
> +static void early_xdbc_write(struct console *con, const char *str, u32 n)
> +{
> + int chunk, ret;
> + static char buf[XDBC_MAX_PACKET];
> + int use_cr = 0;
> +
> + if (!xdbc.xdbc_reg)
> + return;
> + memset(buf, 0, XDBC_MAX_PAC
Use pre-increment and set -ETIMEDOUT correctly.
Signed-off-by: Janusz Dziedzic
---
drivers/usb/dwc3/gadget.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index 19bea3b..0cd98c0 100644
--- a/drivers/usb/dwc3/gadget.c
+++
After we kick_transfer we should clean
DWC3_EP_PENDING_REQUEST endpoint flag.
Signed-off-by: Janusz Dziedzic
---
drivers/usb/dwc3/gadget.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index 0cd98c0..e40d58e 100644
--- a/drivers/usb/dwc
Seems last time we hit few issues where
we get trb_left = 0, mainly because of
HWO bit still set in previous TRB.
Add warn on once to catch/fix such
problems much faster.
Signed-off-by: Janusz Dziedzic
---
drivers/usb/dwc3/gadget.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff -
In case we will fail to STARTTRANSFER we should
also decrement queued_requests.
Signed-off-by: Janusz Dziedzic
---
drivers/usb/dwc3/gadget.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index a9c1d75..840e312 100644
--- a/drivers/usb/d
In case STARTTRANSFER will fail, clean TRB.
Seems HW in such case don't clean HWO bit.
So, without this cleanup prev_trb still have
HWO bit set.
In my case (without patch), after first START failed:
- dep->enqueue == 1
- dep->dequeue == 1
- prev_trb still have HWO set
- left_trb() == 0
No way to s
On Wed, Nov 09, 2016 at 11:58:31AM +0100, Oliver Neukum wrote:
> On Tue, 2016-11-08 at 16:41 +0100, Johan Hovold wrote:
> > On Tue, Nov 08, 2016 at 03:13:13PM +0100, Oliver Neukum wrote:
> > > On Tue, 2016-11-08 at 13:26 +0100, Johan Hovold wrote:
> > > > Drop invalid user-pointer checks from ioctl
On Tue, 2016-11-08 at 16:41 +0100, Johan Hovold wrote:
> On Tue, Nov 08, 2016 at 03:13:13PM +0100, Oliver Neukum wrote:
> > On Tue, 2016-11-08 at 13:26 +0100, Johan Hovold wrote:
> > > Drop invalid user-pointer checks from ioctl handlers.
> > >
> > > A NULL-pointer can be valid in user space and c
Signed-off-by: Ladislav Michl
---
drivers/usb/class/cdc-acm.c | 35 +--
1 file changed, 17 insertions(+), 18 deletions(-)
diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
index 78f0f85..b511289 100644
--- a/drivers/usb/class/cdc-acm.c
+++ b/d
Pointer to usb_device is already stored in acm structure.
Signed-off-by: Ladislav Michl
---
drivers/usb/class/cdc-acm.c | 9 +++--
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
index b511289..8e2d82c 100644
--- a/drive
Move urb killing code into separate function and use it
instead of copying that code pattern over.
Signed-off-by: Ladislav Michl
---
drivers/usb/class/cdc-acm.c | 43 ---
1 file changed, 16 insertions(+), 27 deletions(-)
diff --git a/drivers/usb/class/cdc
Clearing stall needs pipe descriptor, store it in acm structure.
Signed-off-by: Ladislav Michl
---
drivers/usb/class/cdc-acm.c | 27 ++-
drivers/usb/class/cdc-acm.h | 1 +
2 files changed, 15 insertions(+), 13 deletions(-)
diff --git a/drivers/usb/class/cdc-acm.c b/driv
Read urbs are submitted back only on success, causing read pipe
running out of urbs after few errors. No more characters can
be read from tty device then until it is reopened and no errors
are reported.
Fix that by always submitting urbs back and clearing stall on
-EPIPE.
Signed-off-by: Ladislav M
On Tue, 2016-11-08 at 13:44 -0500, Alan Stern wrote:
> These problems could very well be caused by running at SuperSpeed
> (USB-3) instead of high speed (USB-2).
>
> Is there any way to test what happens when the device is attached to
> the computer by a USB-2 cable? That would prevent it from
On Tue, 2016-11-08 at 13:28 +0100, Johan Hovold wrote:
> Drop invalid user-pointer check from TIOCGSERIAL handler.
>
> A NULL-pointer can be valid in user space and copy_to_user() takes
> care
> of sanity checking.
>
> Signed-off-by: Johan Hovold
Acked-by: Oliver Neukum
Regards
From: John Youn
> Sent: 08 November 2016 22:30
...
> >> Also make it __packed.
> >
> > why are you making it packed? Does it _have_ to be packed? If it must,
> > why wasn't it before?
>
> We want to guarantee that it reflects the exact descriptor structure
> in memory, so probably yes. It was over
Oliver Neukum writes:
> On Tue, 2016-11-08 at 13:44 -0500, Alan Stern wrote:
>
>> These problems could very well be caused by running at SuperSpeed
>> (USB-3) instead of high speed (USB-2).
>>
>> Is there any way to test what happens when the device is attached to
>> the computer by a USB-2 cab
Don't complain on -EPROBE_DEFER when when no PHY found, the driver
probe will be retried later.
Signed-off-by: Ladislav Michl
---
drivers/usb/host/ehci-omap.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/ehci-omap.c b/drivers/usb/host/ehci-omap.c
inde
Don't complain on -EPROBE_DEFER when initializing controller,
the driver probe will be retried later.
Signed-off-by: Ladislav Michl
---
drivers/usb/musb/musb_core.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.
There is no point having this complaint to be dev_err as it is just adding
noise to bootlog.
Signed-off-by: Ladislav Michl
---
drivers/usb/musb/omap2430.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
index 451b372..
Replace pr_err with dev_err to print also device name.
Signed-off-by: Ladislav Michl
---
drivers/usb/musb/omap2430.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
index cc12254..451b372 100644
--- a/drivers/usb
On Tue, 8 Nov 2016 sonofa...@openmailbox.org wrote:
>
> > I never had them in the first place.
> Yes I know, the question was asked to the thread creator!
Why didn't you say so (given that you were replying to a message that I
sent)?
> Why did the messages move to a new subject and were not add
On Tue, 8 Nov 2016 sonofa...@openmailbox.org wrote:
> My C-Media USB speakers do not work on Ubuntu 16.10 with 4.8.0 on my AMD
> KABINI USB 2.0 port. Using Ubuntu 16.04 with 4.4.0 on the same machine
> at the same port with the same cable fixes the issue.
> If I put the speakers on any USB 3.0 c
On Tue, Nov 08, 2016 at 06:26:07PM -0700, Tony Lindgren wrote:
> * Johan Hovold [161108 12:03]:
> > On Tue, Nov 08, 2016 at 10:34:13AM -0700, Tony Lindgren wrote:
> > > * Johan Hovold [161108 10:09]:
> > > > On Mon, Nov 07, 2016 at 02:50:18PM -0700, Tony Lindgren wrote:
> > > > > @@ -2604,6 +2669
Rework smelling code (goto inside compound statement). Perhaps this is
legacy. Anyway such code is not appropriate for Linux kernel.
Changes since v3: fix typo
Changes since v2: extract the code to static function
Changes since v1: fix spaces instead of tab, add missing 'Signed-off-by'
Signed-off
* Tony Lindgren [161108 18:26]:
> * Johan Hovold [161108 12:03]:
> +int musb_queue_resume_work(struct musb *musb,
> +int (*callback)(struct musb *musb, void *data),
> +void *data)
> +{
> + struct musb_pending_work *w;
> + unsigned long flags
On Wed, Nov 09, 2016 at 08:34:10AM -0700, Tony Lindgren wrote:
> * Tony Lindgren [161108 18:26]:
> > * Johan Hovold [161108 12:03]:
> > +int musb_queue_resume_work(struct musb *musb,
> > + int (*callback)(struct musb *musb, void *data),
> > + void *data)
On Wed, Nov 09, 2016 at 04:39:53PM +0100, Johan Hovold wrote:
> On Tue, Nov 08, 2016 at 06:26:07PM -0700, Tony Lindgren wrote:
> > @@ -2065,6 +2147,7 @@ musb_init_controller(struct device *dev, int nIrq,
> > void __iomem *ctrl)
> > }
> >
> > spin_lock_init(&musb->lock);
> > + spin_loc
On 9 November 2016 at 09:05, Felipe Balbi wrote:
>
> Hi,
>
> John Youn writes:
>>> + dwc3_writel(dwc->regs, DWC3_GEVNTCOUNT(0), count);
>>> +
> After that evt->buf[lpos, lpos + count] seems goes back to HW, so
> thread should not rely on this?
>
> Or I miss something
If musb controller is configured with USB peripherals and we have
enumerated with a USB host, we can get warnings on removal of the
modules:
WARNING: CPU: 0 PID: 1269 at drivers/dma/cppi41.c:391
cppi41_dma_free_chan_resources
Fix the issue by adding the missing pm_runtime_get to
cppi41_dma_free_c
Hi,
I found two pm runtime issues when testing with usb on beaglebone.
In the am335x case cppi41 and two instances of musb controller share
the same interconnect wrapper module, so any pm issues with musb or
cppi41 will keep the interconnect wrapper module busy.
Regards,
Tony
Tony Lindgren (2
On am335x with musb host we can end up with unpaired pm runtime calls
if a hub with no devices is connected and disconnected.
This is because of the conditional pm runtime calls which are always
a bad idea. Let's fix the issue by making them unconditional and
paired in each function.
Fixes: fdea2
* Ladislav Michl [161109 07:03]:
> Don't complain on -EPROBE_DEFER when when no PHY found, the driver
> probe will be retried later.
Please send this directly to Alan and Greg:
Acked-by: Tony Lindgren
> Signed-off-by: Ladislav Michl
> ---
> drivers/usb/host/ehci-omap.c | 5 +++--
> 1 file ch
* Ladislav Michl [161109 07:08]:
> Don't complain on -EPROBE_DEFER when initializing controller,
> the driver probe will be retried later.
>
> Signed-off-by: Ladislav Michl
Acked-by: Tony Lindgren
> ---
> drivers/usb/musb/musb_core.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(
* Ladislav Michl [161109 07:09]:
> Replace pr_err with dev_err to print also device name.
>
> Signed-off-by: Ladislav Michl
Acked-by: Tony Lindgren
> ---
> drivers/usb/musb/omap2430.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/usb/musb/omap2430.c
* Ladislav Michl [161109 07:11]:
> There is no point having this complaint to be dev_err as it is just adding
> noise to bootlog.
Acked-by: Tony Lindgren
> Signed-off-by: Ladislav Michl
> ---
> drivers/usb/musb/omap2430.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git
* Johan Hovold [161109 08:40]:
> On Tue, Nov 08, 2016 at 06:26:07PM -0700, Tony Lindgren wrote:
> > * Johan Hovold [161108 12:03]:
> > > On Tue, Nov 08, 2016 at 10:34:13AM -0700, Tony Lindgren wrote:
> > > > * Johan Hovold [161108 10:09]:
> > > > > On Mon, Nov 07, 2016 at 02:50:18PM -0700, Tony
On 11/9/2016 12:02 AM, Felipe Balbi wrote:
>
> Hi,
>
> John Youn writes:
>>> John Youn writes:
> John Youn writes:
@@ -1812,17 +1812,17 @@ static u32 dwc2_hsotg_ep0_mps(unsigned int mps)
* @hsotg: The driver state.
* @ep: The index number of the endpoint
On 11/8/2016 11:54 PM, Felipe Balbi wrote:
>
> Hi,
>
> John Youn writes:
>> On 11/8/2016 1:12 AM, Felipe Balbi wrote:
>>>
>>> Hi,
>>>
>>> John Youn writes:
Add a vendor prefix and make the name more consistent by renaming it to
"snps,gadget-dma-enable".
Signed-off-by: John Y
On 11/9/2016 4:18 AM, David Laight wrote:
> From: John Youn
>> Sent: 08 November 2016 22:30
> ...
Also make it __packed.
>>>
>>> why are you making it packed? Does it _have_ to be packed? If it must,
>>> why wasn't it before?
>>
>> We want to guarantee that it reflects the exact descriptor str
Good question. I don't know the answer; it may be hidden in a part
of the system log that you didn't post.
Nothing unusual was found on the log. If you need more information, just
tell me what you need.
This is a known bug in the 4.8 kernel, caused by changes to the timer
code. A workaroun
Why didn't you say so (given that you were replying to a message that I
sent)?
Because I thought it would go to the correct existing subject on the
first place.
I don't know. What new subject are you referring to?
Some days ago, the first two messages I have sent were not linked there:
htt
This function has access to the descriptors via the usb_ep.
Signed-off-by: John Youn
---
drivers/usb/dwc3/gadget.c | 9 ++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index 0e73383..4914182 100644
--- a/drivers/usb/dw
The __dwc3_gadget_endpoint_enable() function has access to the endpoint
descriptors via the usb_ep. So we don't need to pass them in as
arguments. The descriptors should be set by the caller prior to calling
usb_ep_enable().
Signed-off-by: John Youn
---
drivers/usb/dwc3/core.h | 1 -
drivers/
Hi,
On 11/09/2016 05:23 PM, Thomas Gleixner wrote:
> On Tue, 1 Nov 2016, Lu Baolu wrote:
>> +static int __init xdbc_init(void)
>> +{
> ...
>> +base = ioremap_nocache(xdbc.xhci_start, xdbc.xhci_length);
>> +if (!base) {
>> +xdbc_trace("failed to remap the io address\n");
>> +
Hi,
On 11/09/2016 05:37 PM, Thomas Gleixner wrote:
> On Tue, 1 Nov 2016, Lu Baolu wrote:
>> +static void early_xdbc_write(struct console *con, const char *str, u32 n)
>> +{
>> +int chunk, ret;
>> +static char buf[XDBC_MAX_PACKET];
>> +int use_cr = 0;
>> +
>> +if (!xdbc.xdbc_reg)
>>
From:
Date: Tue, 8 Nov 2016 16:08:01 -0600
> From: Allan Chou
>
> Add support for Cypress GX3 SuperSpeed to Gigabit Ethernet
> Bridge Controller (Vendor=04b4 ProdID=3610).
>
> Patch verified on x64 linux kernel 4.7.4, 4.8.6, 4.9-rc4 systems
> with the Kensington SD4600P USB-C Universal Dock wi
Hi Johan,
Johan Hovold 於 2016/11/2 下午 08:37 寫道:
On Fri, Oct 14, 2016 at 04:20:46PM +0800, Ji-Ze Hong (Peter Hong) wrote:
Reviewed-by: Johan Hovold
You must never add other peoples' Reviewed-by tags unless you've
explicitly been given permission to do so (e.g. "fix this minor thing up
and th
From: Vahram Aharonyan
Make the DMA descriptor structure packed to guarantee alignment and size
in memory.
Signed-off-by: John Youn
---
drivers/usb/dwc2/hw.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/dwc2/hw.h b/drivers/usb/dwc2/hw.h
index 6031efe..ee827e8
From: Vahram Aharonyan
Add a parameter for descriptor DMA and set it based on hardware
capabilities. This won't actually be used by the gadget until later,
when the descriptor DMA code is in place.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/core.h | 2 ++
From: Vahram Aharonyan
Rename DMA descriptor structure from dwc2_hcd_dma_desc to dwc2_dma_desc
as it is applies to both host and gadget.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/hcd.c | 4 ++--
drivers/usb/dwc2/hcd.h | 2 +-
drivers/usb/dwc2/hc
From: Vahram Aharonyan
Add device mode DMA transfer descriptor status quadlet field notations.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/hw.h | 37 +
1 file changed, 37 insertions(+)
diff --git a/drivers/usb/dwc2/hw.h b/
This series implements gadget-side descriptor DMA for the DWC_hsotg
controller.
It also includes support for DWC USB IOT controllers which use the
descriptor DMA mode of operation exclusively. These are two new
device-only USB controller IPs based on DWC_hsotg.
Tested on HAPS platform with:
* HSO
From: Vahram Aharonyan
Add dwc2_gadget_get_desc_params() function to define descriptor entry
parameters based on the endpoint type.
Add dwc2_gadget_config_nonisoc_xfer_ddma() function, which programs DDMA
chain entries with corresponding values based on the received DMA buffer
and transfer lengt
From: Vahram Aharonyan
Update dwc2_hsotg structure to add descriptor chains for EP 0: two DMA
descriptors for Setup phase, per one for IN/OUT data and status phases.
Add their allocation function dwc2_gadget_alloc_ctrl_desc_chains() and
its call during gadget probe.
Signed-off-by: Vahram Aharony
From: Vahram Aharonyan
In DDMA mode of operation IN status phase of control write transfer
should start after getting StsPhseRcvd interrupt. This interrupt is
issued by HW once host starts to send IN tokens after data stage.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers
From: Vahram Aharonyan
Rename MAX_DMA_DESC_SIZE to HOST_DMA_NBYTES_LIMIT as it stores value of
host DMA descriptor transfer bytes' limit. Values are different in case
of gadget DMA descriptors.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/hcd_ddma.c | 4 ++--
From: Vahram Aharonyan
The StsPhseRcvd interrupt should not be enabled in slave mode.
Also move the StsPhsRcvd interrupt checking in the endpoint interrupt
handler to the correct order according to the databook. The interrupt
itself will be implemented in a later commit.
Signed-off-by: Vahram A
Now that the gadget driver automatically detects DMA modes, we need to
provide a way to disable them. Certain platforms may still have issues
with DMA and require it to be disabled. It is also needed for IP
validation purposes.
Signed-off-by: John Youn
---
Documentation/devicetree/bindings/usb/d
This is not needed as the gadget now fully supports DMA and it can
autodetect it. This was initially added because gadget DMA mode was only
partially implemented so could not be automatically enabled.
Signed-off-by: John Youn
---
Documentation/devicetree/bindings/usb/dwc2.txt | 4 +++-
arch/arm
From: Vahram Aharonyan
Add DMA descriptor members to the dwc2_hsotg_ep structure.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/core.h | 7 +++
drivers/usb/dwc2/gadget.c | 33 +++--
2 files changed, 38 insertions(+), 2 deletio
From: Vardan Mikayelyan
When device is enumerated in LS we should program ep0_mps accordingly.
USB2 spec says that in LS mode, control ep mps must be 8.
Signed-off-by: Vardan Mikayelyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/gadget.c | 2 ++
1 file changed, 2 insertions(+)
diff --git
From: Vahram Aharonyan
For DDMA mode in case of isochronous transfers completion performed
differently than other transfer types. This is because each usb request
was mapped to one descriptor in the chain and SW gets xfercomplete
interrupt on all descriptors. The endpoint remains enabled until HW
From: Vardan Mikayelyan
Added new core param for low speed, which can be used only when SNPSID
is equal to DWC2_CORE_FS_IOT. When LS mode is enabled, we are
restricting ep types and providing to upper layer only INTR and CTRL
endpoints.
Signed-off-by: Vardan Mikayelyan
Signed-off-by: John Youn
From: Vahram Aharonyan
Add function dwc2_gadget_fill_isoc_desc() - initializes DMA descriptor
for isochronous transfer based on the received request data and endpoint
characteristics.
Added function dwc2_gadget_start_isoc_ddma() - prepare DMA chain for
isochronous transfer in DDMA, programs corr
From: Vahram Aharonyan
In DDMA mode if programmed ISOC OUT transfer length is not DWORD
aligned, after closing descriptor HW leaves value of 4 - (ureq->length %
4) in the RX bytes. This is caused because DMA works using 4B chunks.
Example: if length = 9 and all 9 bytes were received from the bus,
From: Vahram Aharonyan
In DDMA mode incompISOOUT should be masked, similar as Bulk Out -
XferCompl and BNA should be handled. incompISOIN is not valid in DDMA
and is not getting asserted.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/gadget.c | 6 --
1 file
From: Vahram Aharonyan
Check if endpoint is enabled during dwc2_hsotg_ep_disable() function
processing and call dwc2_hsotg_ep_stop_xfr() to disable it and flush
associated FIFO.
Move dwc2_hsotg_ep_stop_xfr() and dwc2_hsotg_wait_bit_set() functions
upper before dwc2_hsotg_ep_enable and dwc2_hsotg
From: Vardan Mikayelyan
Add new device IDs for IOT gadget. Done changes in probe to
configure core accordingly depending on device ID value.
Signed-off-by: Vardan Mikayelyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/core.h | 18 ++
drivers/usb/dwc2/params.c | 9
From: Vahram Aharonyan
Do modifications in dwc2_hsotg_core_init_disconnected() function to
enable USB 1.1 Full-Speed Serial Transceiver Select in GUSBCFG register
if corresponding speed and PHY types are chosen. Adjust device speed
selection in DCFG register as well.
Signed-off-by: Vahram Aharon
From: Vahram Aharonyan
Add DCFG register field macro for descriptor DMA mode and update core
initialization routine to set that bit accordingly.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/gadget.c | 10 --
drivers/usb/dwc2/hw.h | 1 +
2 files ch
From: Vahram Aharonyan
Add dwc2_gadget_start_isoc_ddma() function calls in NAK and OUTTknEPDis
interrupts to start isochronous transfer once Host has sent a token.
Add call of dwc2_gadget_fill_isoc_desc() function in
dwc2_hsotg_ep_queue() to fill descriptor chain's half that is under SW
control
From: Vahram Aharonyan
Add dwc2_gadget_set_ep0_desc_chain() function to switch between EP0 DDMA
chains depend on the stage of control transfer.
Include EP0 DDMA chain selection during ep_queue called from
dwc2_hsotg_enqueue_setup() for setup stage. Selecting and filling DDMA
chain for status pha
From: Vahram Aharonyan
Update transfer starting dwc2_hsotg_start_req() routine with call of
function dwc2_gadget_config_nonisoc_xfer_ddma() to fill descriptor
chain.
Add call of dwc2_gadget_get_xfersize_ddma() in
dwc2_hsotg_handle_outdone() and dwc2_hsotg_complete_in() interrupt
handlers for DDM
From: Vahram Aharonyan
Correct dwc2_hsotg_ep_stop_xfr() function to follow dwc2 programming
guide for setting NAK on specific endpoint, disabling it and flushing
corresponding FIFO.
Current code does not take into account whether core acts in shared or
dedicated FIFO mode, current endpoint is pe
From: Vahram Aharonyan
Add dwc2_gadget_get_chain_limit() function and its call in transfer
start routine to correctly estimate one go on transfer size if
descriptor DMA mode is selected.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/gadget.c | 32 ++
From: Vahram Aharonyan
Tests with various hosts show that depend on time difference between
host sending SETUP packet and IN/OUT token SW could get Xfercomplete
interrupt without SetUp interrupt. On the other hand, SW should parse
received SETUP packet only after ensuring that Host has moved to e
From: Vahram Aharonyan
Enable the BNA (Buffer Not Available) interrupt in descriptor DMA mode.
Signed-off-by: Vahram Aharonyan
Signed-off-by: John Youn
---
drivers/usb/dwc2/gadget.c | 4
drivers/usb/dwc2/hw.h | 1 +
2 files changed, 5 insertions(+)
diff --git a/drivers/usb/dwc2/gadg
From: Vahram Aharonyan
Preparing for isochronous transfers support adding in DDMA mode. In DDMA
isochronous transfers are handled differently compared to Slave and BDMA
modes. This is caused by fact that isoc requests contain data for one
frame/microframe. HW descriptor should contain data of one
If usb_submit_urb() called from the open function fails, the following
crash may be observed.
r8152 8-1:1.0 eth0: intr_urb submit failed: -19
...
r8152 8-1:1.0 eth0: v1.08.3
Unable to handle kernel paging request at virtual address 6b6b6b6b6b6b6b7b
pgd = ffc0e7305000
[6b6b6b6b6b6b6b7b] *pgd=00
Hi,
On Wed, Nov 9, 2016 at 8:32 PM, Bjørn Mork wrote:
> Oliver Neukum writes:
>
>> On Tue, 2016-11-08 at 13:44 -0500, Alan Stern wrote:
>>
>>> These problems could very well be caused by running at SuperSpeed
>>> (USB-3) instead of high speed (USB-2).
Yes, it's running at SuperSpeed, on a Kabyl
Hi,
On 9 November 2016 at 23:35, Eugene Korenevsky wrote:
> Rework smelling code (goto inside compound statement). Perhaps this is
> legacy. Anyway such code is not appropriate for Linux kernel.
>
> Changes since v3: fix typo
> Changes since v2: extract the code to static function
> Changes since
85 matches
Mail list logo