Allocating lots of DMA RAM?

From: Jeff Garzik (
Date: Thu Feb 15 2001 - 08:58:19 EST

Hi all. Is the following loop (from drivers/sound/i810_audio.c among
others) still the best way to allocate a large amount of DMA RAM for
audio? ie. for audio devices that do not support scatter-gather.



        /* alloc as big a chunk as we can, FIXME: is this necessary ?? */
        for (order = DMABUF_DEFAULTORDER; order >= DMABUF_MINORDER; order--)
                if ((rawbuf = pci_alloc_consistent(state->card->pci_dev,
                                                   PAGE_SIZE << order,
        if (!rawbuf)
                return -ENOMEM;

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Thu Feb 15 2001 - 21:00:26 EST