bus_dmamap_sync() for bounced client buffers from user address space

Warner Losh imp at bsdimp.com
Tue Apr 28 16:19:23 UTC 2015


> On Apr 28, 2015, at 7:40 AM, John Baldwin <jhb at FreeBSD.org> wrote:
> 
>> I believe UIO_USERSPACE is almost unused, it might be there for some
>> obscure (and buggy) driver.
> 
> I believe it was added (and only ever used) in crypto drivers, and that they
> all did bus_dma operations in the context of the thread that passed in the
> uio.  I definitely think it is fragile and should be replaced with something
> more reliable.

Fusion I/O’s SDK used this trick to allow mapping of userspace buffers down
into the block layer after doing the requisite locking / pinning / etc of the buffers
into memory. That’s if memory serves correctly (the SDK did these things, I can’t
easily check on that detail since I’m no longer at FIO).

Warner

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freebsd.org/pipermail/freebsd-arch/attachments/20150428/993f8d6e/attachment.sig>


More information about the freebsd-arch mailing list