From owner-freebsd-hackers Mon Jul 23 8:24:25 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from technokratis.com (modemcable052.174-202-24.mtl.mc.videotron.ca [24.202.174.52]) by hub.freebsd.org (Postfix) with ESMTP id A840437B406 for ; Mon, 23 Jul 2001 08:24:19 -0700 (PDT) (envelope-from bmilekic@technokratis.com) Received: (from bmilekic@localhost) by technokratis.com (8.11.3/8.11.3) id f6NFQYi07447; Mon, 23 Jul 2001 11:26:34 -0400 (EDT) (envelope-from bmilekic) Date: Mon, 23 Jul 2001 11:26:34 -0400 From: Bosko Milekic To: vishwanath pargaonkar Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: kernel malloc Message-ID: <20010723112634.A7434@technokratis.com> References: <20010720101239.A12857@technokratis.com> <20010723113755.21267.qmail@web5301.mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010723113755.21267.qmail@web5301.mail.yahoo.com>; from vishubp@yahoo.com on Mon, Jul 23, 2001 at 12:37:55PM +0100 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Jul 23, 2001 at 12:37:55PM +0100, vishwanath pargaonkar wrote: > Hi, > > thx for ur reply. > i wanted to know in side kernel is there any limit to > the malloc that a user can do.what you told in ur > previous mail is that at a time user can malloc 4k.but No. You _can_ malloc over 4k and I never said that you could not. All I said was that if you do malloc() a buffer larger than PAGE_SIZE that the buffer will likely not be contiguous in physical memory. What that means is that your buffer may span across two non-contiguous physical pages. Usually you won't care unless you're DMAing into the buffer, or relying on the physical pages to be contiguous. > suppose i am doing 2k memory allocations. how many > such mallocs i can do? In the kernel, you can do "as many as you want." That is, until you run out of physical memory or until you exhaust the kmem_map virtual address space, whichever comes first. > is there any configuration we can do depending on our > RAM size? > please reply. > thx > vishwanath Regards, -- Bosko Milekic bmilekic@technokratis.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message