[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-08-27 Thread imperia via ubuntu-bugs
this is dmidecode output of my machine, in case the fix is FW related,
it may be useful in order to contact the motherboard vendor

** Attachment added: "dmidecode.out"
   
https://bugs.launchpad.net/ubuntu/artful/+source/linux/+bug/1749961/+attachment/5181405/+files/dmidecode.out

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-04-11 Thread imperia via ubuntu-bugs
Hello,

I am unable to test with the kernel you provided, because my tuner card
doesn't have driver in mainline kernel tree. So I have to compile it
myself and I need kernel headers for this.

So I compiled kernel 4.16 from debian linux-source-4.16 package and
applied the patch you provided:

>From dd0375ffba55172194999d40b35344e9dc2682df Mon Sep 17 00:00:00 2001
From: "Guilherme G. Piccoli" 
Date: Wed, 11 Apr 2018 11:04:13 +
Subject: [PATCH] xhci: Add quirk to ASMedia 0x1242 adapter to avoid BEI

Signed-off-by: Guilherme G. Piccoli 
---
 drivers/usb/host/xhci-pci.c | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/drivers/usb/host/xhci-pci.c b/drivers/usb/host/xhci-pci.c
index d9f831b..0654461 100644
--- a/drivers/usb/host/xhci-pci.c
+++ b/drivers/usb/host/xhci-pci.c
@@ -213,6 +213,12 @@ static void xhci_pci_quirks(struct device *dev, struct 
xhci_hcd *xhci)
xhci->quirks |= XHCI_TRUST_TX_LENGTH;

if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA &&
+   pdev->device == 0x1242) {
+   xhci->quirks |= XHCI_AVOID_BEI;
+   pr_warn("QUIRK: XHCI_AVOID_BEI");
+   }
+
+   if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA &&
pdev->device == PCI_DEVICE_ID_ASMEDIA_1042A_XHCI)
xhci->quirks |= XHCI_ASMEDIA_MODIFY_FLOWCONTROL;

--
2.7.4

Compiled my tuner card driver now and I am testing.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-04-01 Thread imperia via ubuntu-bugs
Hello,

I think I am ready with the trace log. Hopefully it is full, because machine 
run out of disk space :)
http://imperia.mine.nu/trace1.log.bz2
Interesting is that it took ~12 hours to crash it this time.

The problem with ssh access is that this is virtual machine under XEN
and when you reboot it, the USB controller is gone(not assigned to
virtual machine anymore). I have to re-assign the USB controller for
passthrough from xen host. (this is xen bug I think, it wasn't like this
before).

This is what I do when I have to restart vdr virtual machine:
xl pci-assignable-remove 03:00.0
xl pci-assignable-add 03:00.0
xl create /etc/xen/vdr.cfg

Anyway we can get in touch on irc and I can do restarts for you.

BTW, I shutdown the whole xen server. Then I turn off the power button
on PSU and pressed the power button on the case to discharge any
electricity left and put it in consistent state before getting the trace
logs.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-03-29 Thread imperia via ubuntu-bugs
** Also affects: linux (Debian)
   Importance: Undecided
   Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-03-29 Thread imperia via ubuntu-bugs
echo xhci-hcd >> /sys/kernel/debug/tracing/set_event
(tail -F -n0 /var/log/kern.log &) | grep -q "TRB DMA"
cp /var/log/kern.log /home/imperia/log1.log

Is this correct command to get traces?
I will run it in advance. 

Somebody told me to run this before when I was looking for help.

BTW did you download the full logs so I can remove it from web page?

I will can provide ssh access to box affected if needed.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-03-29 Thread imperia via ubuntu-bugs
Mar 29 20:20:03 vdr kernel: [119370.230528]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Removing canceled TD starting at 0x2ae36c590 (dma).
Mar 29 20:20:03 vdr kernel: [119370.230533]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Finding endpoint context
Mar 29 20:20:03 vdr kernel: [119370.230537]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Cycle state = 0x0
Mar 29 20:20:03 vdr kernel: [119370.230542]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: New dequeue segment = 573583cc (virtual)
Mar 29 20:20:03 vdr kernel: [119370.230547]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: New dequeue pointer = 0x2ae36c5a0 (DMA)
Mar 29 20:20:03 vdr kernel: [119370.230553]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Set TR Deq Ptr cmd, new deq seg = 573583cc (0x2ae36c000 
dma), new deq ptr = 41e92668 (0x2ae36c5a0 dma), new cycle = 0
Mar 29 20:20:03 vdr kernel: [119370.230558]  xhci_ring_cmd_db:282: 
xhci_hcd :00:00.0: // Ding dong!
Mar 29 20:20:03 vdr kernel: [119370.230631] [27868] xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Cancel URB 60641c50, dev 2, ep 0x82, starting at offset 
0x2ae36c5a0
Mar 29 20:20:03 vdr kernel: [119370.230638] [27868] xhci_ring_cmd_db:282: 
xhci_hcd :00:00.0: // Ding dong!
Mar 29 20:20:03 vdr kernel: [119370.230650]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Successful Set TR Deq Ptr cmd, deq = @2ae36c5a0
Mar 29 20:20:03 vdr kernel: [119370.230700]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Removing canceled TD starting at 0x2ae36c5a0 (dma).
Mar 29 20:20:03 vdr kernel: [119370.230705]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Finding endpoint context
Mar 29 20:20:03 vdr kernel: [119370.230710]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Cycle state = 0x0
Mar 29 20:20:03 vdr kernel: [119370.230715]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: New dequeue segment = 573583cc (virtual)
Mar 29 20:20:03 vdr kernel: [119370.230719]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: New dequeue pointer = 0x2ae36c5b0 (DMA)
Mar 29 20:20:03 vdr kernel: [119370.230725]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Set TR Deq Ptr cmd, new deq seg = 573583cc (0x2ae36c000 
dma), new deq ptr = 50070757 (0x2ae36c5b0 dma), new cycle = 0
Mar 29 20:20:03 vdr kernel: [119370.230730]  xhci_ring_cmd_db:282: 
xhci_hcd :00:00.0: // Ding dong!
Mar 29 20:20:03 vdr kernel: [119370.230798] [27868] xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Cancel URB 588cca08, dev 2, ep 0x82, starting at offset 
0x2ae36c5b0
Mar 29 20:20:03 vdr kernel: [119370.230805] [27868] xhci_ring_cmd_db:282: 
xhci_hcd :00:00.0: // Ding dong!
Mar 29 20:20:03 vdr kernel: [119370.230816]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Successful Set TR Deq Ptr cmd, deq = @2ae36c5b0
Mar 29 20:20:03 vdr kernel: [119370.230865]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Removing canceled TD starting at 0x2ae36c5b0 (dma).
Mar 29 20:20:03 vdr kernel: [119370.230870]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Finding endpoint context
Mar 29 20:20:03 vdr kernel: [119370.230874]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Cycle state = 0x0
Mar 29 20:20:03 vdr kernel: [119370.230879]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: New dequeue segment = 573583cc (virtual)
Mar 29 20:20:03 vdr kernel: [119370.230884]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: New dequeue pointer = 0x2ae36c5c0 (DMA)
Mar 29 20:20:03 vdr kernel: [119370.230910]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Set TR Deq Ptr cmd, new deq seg = 573583cc (0x2ae36c000 
dma), new deq ptr = a598b646 (0x2ae36c5c0 dma), new cycle = 0
Mar 29 20:20:03 vdr kernel: [119370.230918]  xhci_ring_cmd_db:282: 
xhci_hcd :00:00.0: // Ding dong!
Mar 29 20:20:03 vdr kernel: [119370.231023]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Successful Set TR Deq Ptr cmd, deq = @2ae36c5c0
Mar 29 20:20:03 vdr kernel: [119370.231041] [27868] xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Cancel URB 6bc9f6cb, dev 2, ep 0x82, starting at offset 
0x2ae36c5c0
Mar 29 20:20:03 vdr kernel: [119370.231051] [27868] xhci_ring_cmd_db:282: 
xhci_hcd :00:00.0: // Ding dong!
Mar 29 20:20:03 vdr kernel: [119370.231121]  handle_tx_event:2385: 
xhci_hcd :00:00.0: Babble error for slot 1 ep 0 on endpoint
Mar 29 20:20:03 vdr kernel: [119370.231126] xhci_hcd :00:00.0: ERROR 
Transfer event TRB DMA ptr not part of current TD ep_index 0 comp_code 3
Mar 29 20:20:03 vdr kernel: [119370.231211] xhci_hcd :00:00.0: Looking for 
event-dma 0002afce2120 trb-start 0002afce2380 trb-end 0002afce23a0 
seg-start 0002afce2000 seg-end 0002afce2ff0
Mar 29 20:20:03 vdr kernel: [119370.231327]  handle_tx_event:2358: 
xhci_hcd :00:00.0: Stopped on Transfer TRB for slot 1 ep 4
Mar 29 20:20:03 vdr kernel: [119370.231340]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Removing canceled TD starting at 0x2ae36c5c0 (dma).
Mar 29 20:20:03 vdr kernel: [119370.231356]  xhci_dbg_trace:31: xhci_hcd 
:00:00.0: Finding endpoint context
Mar 29 2

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-03-29 Thread imperia via ubuntu-bugs
Hello,

00:00.0 USB controller [0c03]: ASMedia Technology Inc. ASM1142 USB 3.1
Host Controller [1b21:1242]

Actually I am on debian buster. I am running kernel 4.16-rc6 from
experimental repository.

I am running program for watching satellite channels called vdr.
When I am not watching TV, while idle, every few minutes vdr scans for channel 
list updates from satellites. It is safe to say that tuner is occupied every 
few minutes for a scan, but not occupied with bandwidth like when watching TV. 
While in this mode vdr is able to crash the driver in ~6-30 hours.

There is program that you use to initially create your channels list for
vdr. When I use it I am able to crash the driver in ~1-2 hours.

But when I just watch one channel and don't change it for hours, driver
is least likely to crash.

I think something in consecutive opening (initializing) of the usb port/driver 
forces this error.
Because the program that scans for channels crash it much faster.
This program work like this:

:go
open port
scan some frequency
write to file new channels
close port
goto go


I made this script that I will use to capture the log.

echo "module xhci_hcd +flpt" > /sys/kernel/debug/dynamic_debug/control
(tail -F -n0 /var/log/kern.log &) | grep -q "TRB DMA"
cp /var/log/kern.log /home/imperia/log1.log

And I will run initial channels list scan to force it faster.

I will be back later with the logs.
Thanks for your help.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1749961] Re: xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1 Controller

2018-03-28 Thread imperia via ubuntu-bugs
Hello,
Looks like I am having the same problem.

After some hours(random time) my USB 3.1 asmedia controller crashes the driver 
with following error:
[  873.661534] xhci_hcd :00:00.0: ERROR Transfer event TRB DMA ptr not part 
of current TD ep_index 0 comp_code 3
[  873.661629] xhci_hcd :00:00.0: Looking for event-dma 0002722ed630 
trb-start 0002722ed9b0 trb-end 0002722ed9d0 seg-start 0002722ed000 
seg-end 0002722edff0
[  875.673409] xhci_hcd :00:00.0: WARN Set TR Deq Ptr cmd failed due to 
incorrect slot or ep state.
I am struggling with this error for more than year. Its very annoying to have 
to restart the PC every few hours. USB tuner card is connected to the port.
I would like to provide whatever information and support is necessary to fix 
this damn bug. Logs, ssh access to the affected box and everything else what is 
needed.

Please ask me here or write to my e mail imperia777_yahoo.com
Thanks.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1749961

Title:
  xhci_hcd: TRB DMA errors reported with ASMedia ASM1142 USB 3.1
  Controller

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1749961/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs