Re: kernel memory
- From: "Peter Wieland [MSFT]" <peterwie@xxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 4 Feb 2008 13:31:47 -0800
Kernel virtual address space is used for a number of things. Page tables, PFN database, cache manager regions, registry pages, mapped data transfers, etc... Pat of this are the memory pools, from which you can allocate memory for your drivers.
The pools will attempt to grow (up to some limits that I don’t know off the top of my head, and which I suspect are adjustable) but probably won't ever take up all of the kernel space, since we still need room to handle direct mapped I/O transfers.
That's all virtual space. Physical pages are allocated to all of these things as well as to the address spaces of processes. You can allocate physical memory using a DDI like MmAllocatePagesForMdl and then map those into the system address space.
Don't fall into the mistaken assumption that your driver is the only thing running on the system. You have to share the system resources with everyone else. That's probably the easiest way to explain why you cannot allocate 1GB of non-paged pool for yourself :)
-p
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"kobi n" <kobin@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:37C6B380-DAD0-4661-B94F-E5634E19A61F@xxxxxxxxxxxxxxxx
Hi,
i have a very basic question regarding kernel memory allocation.
is allocating kernel memory always performed on some kind of pool (paged or
nopaged) ? is there any memory allocation methods that acts on a "regular"
memory, meaning type of memory other than paged or nopaged ?
since kernel memory space is about 1G, i'm a bit confused since both the
paged pool and the non paged pool are smaller than 1G. so what with the rest
of the memory ? can i allocate more than the pools have to offer ? if so, how
? since all the routines deal with a pool type (paged or non paged).
thanks a lot,
kobi.
.
- Follow-Ups:
- Re: kernel memory
- From: Tim Roberts
- Re: kernel memory
- Prev by Date: Re: PM IRPs won't complete in KMDF bus driver
- Next by Date: Re: PM IRPs won't complete in KMDF bus driver
- Previous by thread: OS platform for Win2K only in INF file
- Next by thread: Re: kernel memory
- Index(es):
Relevant Pages
|