Re: Could convert a buffer that allocated by vmalloc to pages?

From: Anton Altaparmakov
Date: Tue Jan 23 2007 - 08:12:51 EST


On Tue, 2007-01-23 at 21:04 +0800, Yu-Chen Wu wrote:
> Hi,
> I write a driver have a big buffer (16MB,allocated by vmalloc).
> I want to use the buffer to do DMA transmission so I need getting the pages
> of the buffer.
> Have any kernel API can do this?
> My platform is x86_64 and 2GB RAM

vmalloc_to_page()...

See mm/memory.c for the function and how to use it.

Best regards,

Anton
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Unix Support, Computing Service, University of Cambridge, CB2 3QH, UK
Linux NTFS maintainer, http://www.linux-ntfs.org/

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