mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Matti Aarnio <matti.aarnio@zmailer.org>
To: Pannaga Bhushan <bhushan@multitech.co.in>
Cc: linux-kernel@vger.kernel.org
Subject: Re: A hole in kernel space!
Date: Wed, 6 Nov 2002 14:19:18 +0200	[thread overview]
Message-ID: <20021106121918.GJ26330@mea-ext.zmailer.org> (raw)
In-Reply-To: <3DC903BE.F4CD5A52@multitech.co.in>

On Wed, Nov 06, 2002 at 05:27:50PM +0530, Pannaga Bhushan wrote:
> Hi all,
>         I am looking for a setup where I need to have a certain amount
> of data always available to the kernel. The size of data I am looking at
> is abt 40MB(preferably, but I will settle for 20MB too) . So the normal
> kmalloc will not help me.

  Will  vmalloc()  help ?  The allocated memory is in special
  vmalloc address space (which is limited!) within the kernel,
  but accesses to it go via page-mapping tables, thus while it
  is virtually contiguous, physically it might be well scattered.

  What properties do you need, to be exact ?

  You are writing some sort of a device driver for a device that
  has somewhat stupid direct-memory-access facilities ?

> if yes, are the pages corresponding to this region swappable or
> is it that since this hole appears in kernel image, it is locked to a
> physical space and this is never swapped. (basically, i want by data
> in kernel space always available to kernel without having to bother
> abt swapping the pages back)

  Both  kmalloc()  and  vmalloc()  allocate kernel space memory that
  is unswappable, and therefore can not be allocated in excessive
  amounts.

  Doing things in BIGMEM fashion will let you have gigabytes of
  in-core memory, but to access it, you must go thru the hoops
  (in i686 architecture) each time you access a page of it.

> Thanx in advance,
> Pannaga Bhushan

/Matti Aarnio

  parent reply	other threads:[~2002-11-06 12:12 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-06 11:57 Pannaga Bhushan
2002-11-06 12:02 ` Abraham vd Merwe
2002-11-06 12:19 ` Matti Aarnio [this message]
2002-11-06 13:49 ` Marc A. Volovic
2002-11-06 14:07   ` Richard B. Johnson
2002-11-06 16:09     ` Marc A. Volovic
2002-11-06 21:07       ` Adrian Bunk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20021106121918.GJ26330@mea-ext.zmailer.org \
    --to=matti.aarnio@zmailer.org \
    --cc=bhushan@multitech.co.in \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®