RE: Address spaces on a i386 - Getting Confused

Eric Lowe (ELowe@SYSTRAN.com)
Thu, 1 Apr 1999 09:11:55 -0500


This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01BE7C49.996FC3B0
Content-Type: text/plain;
charset="iso-8859-1"

>
> > As a future problem, some user-space pages will not be reachable by
> > DMA anyway, because they are outside the bus address range of the
> > device doing DMA. (cf. 32-bit PCI cards on >4GB memory machines, or
> > complexities of multi-bus machines).
>
> Indeed, and this is one of the problems I'll have to deal with for the
> large memory support. IO bounce buffers will be necessary, but that
> will be entirely transparent above the block device request layer.
>

How about a dmamalloc() function? Such a beast exists under systems like
VxWorks. It guarantees not only that all memory allocated will be hardware
addressable, but that it will be page aligned (so no offsets need to be
computed when doing scatter/gather lists). The buffers could be allocated
internally with it, and devices that are going to do streaming I/O could
just allocate their memory using this call instead of malloc().

--
Eric Lowe
elowe@systran.com
Software Engineer Co-op, Systran Corporation
937-252-5601 x330
((sorry for the HTML, my e-mail gateway is adding it, I can't disable it..))

------_=_NextPart_001_01BE7C49.996FC3B0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> RE: Address spaces on a i386 - Getting Confused

>
> > As a future problem, some user-space pages = will not be reachable by
> > DMA anyway, because they are outside the = bus address range of the
> > device doing DMA.  (cf. 32-bit PCI = cards on >4GB memory machines, or
> > complexities of multi-bus = machines).
>
> Indeed, and this is one of the problems I'll = have to deal with for the
> large memory support.  IO bounce buffers = will be necessary, but that
> will be entirely transparent above the block = device request layer.
>

How about a dmamalloc() function?  Such a beast = exists under systems like VxWorks.  It guarantees not only that = all memory allocated will be hardware addressable, but that it will be = page aligned (so no offsets need to be computed when doing = scatter/gather lists).  The buffers could be allocated internally = with it, and devices that are going to do streaming I/O could just = allocate their memory using this call instead of malloc().

--
Eric Lowe
elowe@systran.com
Software Engineer Co-op, Systran Corporation
937-252-5601 x330
((sorry for the HTML, my e-mail gateway is adding = it, I can't disable it..))

------_=_NextPart_001_01BE7C49.996FC3B0--

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/