netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Question on IOAT
@ 2007-02-05 16:59 Olaf Kirch
  2007-02-05 18:24 ` Chris Leech
  0 siblings, 1 reply; 3+ messages in thread
From: Olaf Kirch @ 2007-02-05 16:59 UTC (permalink / raw)
  To: netdev


Hi,

I looked into the IOAT code today as I'm trying to find out how to add support
for it to NFS. I ran into this piece of code, which waits for the DMA
operation to complete:

                while (dma_async_memcpy_complete(tp->ucopy.dma_chan,
                                                 tp->ucopy.dma_cookie, &done,
                                                 &used) == DMA_IN_PROGRESS) {
                        /* do partial cleanup of sk_async_wait_queue */
                        while ((skb = skb_peek(&sk->sk_async_wait_queue)) &&
                               (dma_async_is_complete(skb->dma_cookie, done,
                                                      used) == DMA_SUCCESS)) {
                                __skb_dequeue(&sk->sk_async_wait_queue);
                                kfree_skb(skb);
                        }
                }

Nowhere in the dma_async_*complete functions can I see any code
that would sleep if the DMA is not yet complete. Am I missing something,
or are we really busy-waiting on the DMA engine? Wouldn't this kind of
defeat the purpose of freeing up the CPU from the chores of memcpying?

I also checked the code in ioatdma.c - I would have expected there to
be some kind of interrupt handler that kicks the upper layers when a
DMA operation completes. But the interrupt handler seems to be for
error reporting exclusively... 

Olaf
-- 
Olaf Kirch  |  --- o --- Nous sommes du soleil we love when we play
okir@lst.de |    / | \   sol.dhoop.naytheet.ah kin.ir.samse.qurax

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-02-05 20:05 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-02-05 16:59 Question on IOAT Olaf Kirch
2007-02-05 18:24 ` Chris Leech
2007-02-05 20:03   ` Olaf Kirch

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).