Thread (98 messages) 98 messages, 9 authors, 2012-01-22

Re: [PATCH] sky2: Fix WARNING: at lib/dma-debug.c:902 check_sync

From: Jarek Poplawski <hidden>
Date: 2010-01-20 22:53:40
Also in: lkml

On Wed, Jan 20, 2010 at 10:24:14PM +0000, Alan Cox wrote:
quoted
quoted
Seems like an underlying bug in the DMA api. Maybe it just can't
handle operations on partial mapping.

Other drivers with same problem:
  bnx2, cassini, pcnet32, r8169, rrunner, skge, sungem, tg3, 
It seems using the same length (even without pci_unmap_len()) is
crucial here, but I hope maintainers (added to CC) will take care.
The API needs fixing - if you've got a large mapping and you want to sync
part of it then we need to support that. Now it might well be that the
implementation on some braindead platform has to sync the entire thing,
and some implementations entire pages or cache lines.

You can't fix this in the drivers, they requested a service and they
don't have enough information nor is it their job to know about all the
platform specific rules.
Yes, the need to repeat some other values if there is a dedicated
structure/pointer could be misleading. Btw, it seems to be a trivial
overlooking since there is dma_sync_single_range() ready to use.

Jarek P.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help