From mboxrd@z Thu Jan 1 00:00:00 1970 From: j.neuschaefer@gmx.net (Jonathan =?utf-8?Q?Neusch=C3=A4fer?=) Date: Tue, 23 Aug 2011 00:27:38 +0200 Subject: Can i allocate 4GB virtual addresses (more than a certain limit) using vmalloc? In-Reply-To: References: Message-ID: <20110822222738.GA29752@debian.debian> To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org On Mon, Aug 22, 2011 at 04:43:55PM -0500, subin gangadharan wrote: > Hi Dave, > > >Also keep in mind that when you vmalloc stuff you're allocating in > >units of pages, and there is a guard page between each allocation. So > >if you had 512 Mb of virtual space (which is 131,072 pages), you'll be > >able to vmalloc a maximum of 65536 objects or 1 page each. Fewer > >objects if they're bigger than a page. > > A quick question, Suppose if I alloc 1MB of memory using vmalloc,Is there a > guard page between each page or is it after the 1MB. If you do it one vmalloc call your 1MiB should be continuous, i.e. if there's a guard page it will be after your megabyte. HTH, Jonathan Neusch?fer