linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Mathias Nyman <mathias.nyman@linux.intel.com>,
	Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Cc: Mathias Nyman <mathias.nyman@intel.com>,
	linux-usb@vger.kernel.org, lukaszx.szulc@intel.com,
	Christoph Hellwig <hch@lst.de>,
	Marek Szyprowski <m.szyprowski@samsung.com>,
	iommu@lists.linux-foundation.org
Subject: usb HC busted?
Date: Wed, 06 Jun 2018 18:36:35 +0300	[thread overview]
Message-ID: <42ec4ab07d96b4302b875ac9c5eb76675bf85690.camel@linux.intel.com> (raw)

On Wed, 2018-06-06 at 17:12 +0300, Mathias Nyman wrote:
> On 04.06.2018 18:28, Sudip Mukherjee wrote:
> > On Thu, May 24, 2018 at 04:35:34PM +0300, Mathias Nyman wrote:
> > > 

> Odd and unlikely, but to me this looks like some issue in allocating
> dma memory
> from pool using dma_pool_zalloc()
> 
> Adding people with DMA knowledge to cc, maybe someone knows what is
> going on.
> 
> Here's the story:
> Sudip sees usb issues on a Intel Atom based board with 4.14.2 kernel.
> All tracing points to dma_pool_zalloc() returning the same dma address
> block on
> consecutive calls.
> 
> In the failing case dma_pool_zalloc() is called 3 - 6us apart.
> 
> <...>-26362 [002] ....  1186.756739: xhci_ring_mem_detail: MATTU
> xhci_segment_alloc dma @ 0x000000002d92b000
> <...>-26362 [002] ....  1186.756745: xhci_ring_mem_detail: MATTU
> xhci_segment_alloc dma @ 0x000000002d92b000
> <...>-26362 [002] ....  1186.756748: xhci_ring_mem_detail: MATTU
> xhci_segment_alloc dma @ 0x000000002d92b000
> 
> dma_pool_zalloc() is called from xhci_segment_alloc() in
> drivers/usb/host/xhci-mem.c
> see:
> https://elixir.bootlin.com/linux/v4.14.2/source/drivers/usb/host/xhci-
> mem.c#L52
> 
> prints above are custom traces added right after dma_pool_zalloc()

For better understanding it would be good to have dma_pool_free() calls
debugged as well.

Is it possible that something in parallel just fast enough to free the
allocated resource from pool?

             reply	other threads:[~2018-06-06 15:36 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-06 15:36 Andy Shevchenko [this message]
  -- strict thread matches above, loose matches on Subject: below --
2018-07-21 10:55 usb HC busted? Sudip Mukherjee
2018-07-20 14:09 Alan Stern
2018-07-20 12:54 Sudip Mukherjee
2018-07-20 11:46 Mathias Nyman
2018-07-20 11:10 Mathias Nyman
2018-07-19 17:32 Sudip Mukherjee
2018-07-19 15:42 Mathias Nyman
2018-07-19 14:57 Alan Stern
2018-07-19 11:34 Sudip Mukherjee
2018-07-19 10:59 Mathias Nyman
2018-07-17 17:01 Sudip Mukherjee
2018-07-17 15:59 Sudip Mukherjee
2018-07-17 15:52 Greg Kroah-Hartman
2018-07-17 15:10 Sudip Mukherjee
2018-07-17 15:08 Alan Stern
2018-07-17 14:49 Sudip Mukherjee
2018-07-17 14:40 Sudip Mukherjee
2018-07-17 14:31 Alan Stern
2018-07-17 14:28 Alan Stern
2018-07-17 13:53 Greg Kroah-Hartman
2018-07-17 13:20 Sudip Mukherjee
2018-07-17 12:04 Greg Kroah-Hartman
2018-07-17 11:41 Sudip Mukherjee
2018-06-30 21:07 Sudip Mukherjee
2018-06-29 11:41 Mathias Nyman
2018-06-27 12:20 Sudip Mukherjee
2018-06-27 11:59 Sudip Mukherjee
2018-06-25 16:15 Sudip Mukherjee
2018-06-21 11:01 Mathias Nyman
2018-06-21  0:53 Sudip Mukherjee
2018-06-08  9:07 Sudip Mukherjee
2018-06-07  7:40 Mathias Nyman
2018-06-06 16:45 Sudip Mukherjee
2018-06-06 16:42 Sudip Mukherjee
2018-06-06 14:12 Mathias Nyman
2018-06-04 15:28 Sudip Mukherjee
2018-06-03 19:37 Sudip Mukherjee
2018-05-24 13:35 Mathias Nyman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=42ec4ab07d96b4302b875ac9c5eb76675bf85690.camel@linux.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=hch@lst.de \
    --cc=iommu@lists.linux-foundation.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=lukaszx.szulc@intel.com \
    --cc=m.szyprowski@samsung.com \
    --cc=mathias.nyman@intel.com \
    --cc=mathias.nyman@linux.intel.com \
    --cc=sudipm.mukherjee@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).