On 10/10/2017 22:13, Mathias Nyman wrote: > On 10.10.2017 12:41, David Laight wrote: >> From: Robin Murphy >>> Sent: 09 October 2017 18:39 >> ... >>>> - without the IOMMU, block sizes >=128K all settle down into a >>>> suspiciously-periodic error every 2048 sectors. >> >> That stinks of being a problem where either the link TRB is part >> way through a USB packet or where a buffer fragment crosses >> a 64k boundary. >> >> Neither is allowed. >> > > Those should be taken care of by the xhci driver already > > xhci_align_td() should make sure the link TRB is at packet boundary, and > TRB_BUFF_LEN_UP_TO_BOUNDARY(addr) in xhci_queue_bulk_tx() should prevent > crossing 64k boundary in a TRB when queuing it. > > more traces and logs of the VIA xhci controller could maybe tell something. > > with the latest kernel: > > echo 81920 > /sys/kernel/debug/tracing/buffer_size_kb > echo 1 > /sys/kernel/debug/tracing/events/xhci-hcd/enable > after failure: > cat /sys/kernel/debug/tracing/trace Unfortunately since the failure on my VL805 is during xhci init tracing doesn't produce anything we don't already know.. # tracer: nop # # _-----=> irqs-off # / _----=> need-resched # | / _---=> hardirq/softirq # || / _--=> preempt-depth # ||| / delay # TASK-PID CPU# |||| TIMESTAMP FUNCTION # | | | |||| | | modprobe-964 [003] .... 240.271468: xhci_dbg_quirks: QUIRK: Resetting on resume modprobe-964 [003] .... 240.271471: xhci_dbg_init: // Halt the HC modprobe-964 [003] .... 240.271477: xhci_dbg_init: // Reset the HC And the associated DMA faults: [ 265.286686] DMAR: DRHD: handling fault status reg 2 [ 265.286688] DMAR: [DMA Read] Request device [03:00.0] fault addr de28a000 [fault reason 01] Present bit in root entry is clear I'll try and figure out exactly what de28a000 points at (or points after..). Thanks. -- Hao Wei -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html