All of lore.kernel.org
 help / color / mirror / Atom feed
From: corbet@lwn.net (Jonathan Corbet)
To: Timur Tabi <timur@freescale.com>
Cc: andi@firstfloor.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH][RFC] Add alloc_pages_exact() and free_pages_exact()
Date: Wed, 14 May 2008 08:05:23 -0600	[thread overview]
Message-ID: <16468.1210773923@vena.lwn.net> (raw)
In-Reply-To: Your message of "Tue, 13 May 2008 16:26:46 CDT." <1210714006-8976-1-git-send-email-timur@freescale.com>

Timur Tabi writes:

> alloc_pages_exact() is similar to alloc_pages(), except that it allocates
> the minimum number of pages to fulfill the request.  This is useful if you
> want to allocate a very large buffer that is slightly larger than an
> even power-of-two number of pages.  In that case, alloc_pages() will waste
> a lot of memory.

FWIW, I wished I had something like this when doing the cafe_ccic
driver.  I can't really attest to the validity of the core VM stuff, but
I will say that the interface is worth having.

Thanks for doing this!

jon

  reply	other threads:[~2008-05-14 14:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-13 21:26 [PATCH][RFC] Add alloc_pages_exact() and free_pages_exact() Timur Tabi
2008-05-14 14:05 ` Jonathan Corbet [this message]
2008-05-14 16:03 ` Randy Dunlap

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=16468.1210773923@vena.lwn.net \
    --to=corbet@lwn.net \
    --cc=andi@firstfloor.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=timur@freescale.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.