Re: API change for bus_dma
From: Andrew Gallatin (gallatin_at_cs.duke.edu)
Date: 06/27/03
- Previous message: Scott Long: "Re: API change for bus_dma"
- In reply to: Scott Long: "Re: API change for bus_dma"
- Next in thread: Scott Long: "Re: API change for bus_dma"
- Reply: Scott Long: "Re: API change for bus_dma"
- Reply: Terry Lambert: "Re: API change for bus_dma"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Fri, 27 Jun 2003 17:21:58 -0400 (EDT) To: Scott Long <scott_long@btc.adaptec.com>
Scott Long writes:
>
> The approach taken with busdma is that you don't assume coherency. The
Unfortunately, in our application we must assume coherency in some
situations. We have kernel memory mmap'ed into user space for
zero-copy io of small messages. Doing a system call to force the dma
sync would add unacceptable latency. (we're talking sub 10us latencies
here, without syscalls).
> idea is to call bus_dmamap_sync() with the appropriate opcode to signal
> pre|post read|write, and have that take care of the platform-specific
> magic. On i386 when bouncing does not occur, these are NOOP, otherwise
> the actual bouncing bcopy() takes place. On sparc64 it looks like it
> does the appropriate IOMMU and memory barrier magic.
Sure, but we're a 64-bit card and never bounce. If we've bounced, we
might as well take the ball and go home, so to speak ;)
Anyway, this has saved me a lot of time. Its now apparent that
there's no point in our using busdma, since the main gain would have
been to enable us to run on sparc64. Directly using physical
addresses works great everywhere else..
Drew
_______________________________________________
freebsd-arch@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-arch
To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org"
- Previous message: Scott Long: "Re: API change for bus_dma"
- In reply to: Scott Long: "Re: API change for bus_dma"
- Next in thread: Scott Long: "Re: API change for bus_dma"
- Reply: Scott Long: "Re: API change for bus_dma"
- Reply: Terry Lambert: "Re: API change for bus_dma"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
- Re: API change for bus_dma
... > Scott Long writes: ... >> The approach taken with busdma is
that you don't assume coherency. ... but we're a 64-bit card and never bounce. ...
(freebsd-arch) - Re: Request for feedback on common data backstore in the kernel
... performance issues with USB and busdma. ... Do you have any test data
that ... if you load a buffer pointer and length that is not cache aligned nor host aligned then
you should bounce all the data no matter what. ... struct my_softc { ...
(freebsd-arch)