public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Manfred Spraul <manfred@colorfullife.com>
To: Christoph Hellwig <hch@lst.de>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] make kmem_find_general_cachep static in slab.c
Date: Tue, 07 Sep 2004 18:50:17 +0200	[thread overview]
Message-ID: <413DE6C9.5050402@colorfullife.com> (raw)
In-Reply-To: <20040907143632.GA8480@lst.de>

Christoph Hellwig wrote:

>--- 1.35/include/linux/slab.h	2004-09-03 11:08:25 +02:00
>+++ edited/include/linux/slab.h	2004-09-07 14:47:58 +02:00
>@@ -55,7 +55,6 @@
> /* prototypes */
> extern void kmem_cache_init(void);
> 
>-extern kmem_cache_t *kmem_find_general_cachep(size_t, int gfpflags);
>  
>

Why?
It's intended for users that want to kmalloc always the same amount of 
memory.
For example the network layer could call kmem_find_general_cachep once 
for dev->mtu and then just call kmem_cache_alloc instead of kmalloc. The 
loop in kmalloc often needs more cpu cycles than the actual alloc.

--
    Manfred

  reply	other threads:[~2004-09-07 17:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-07 14:36 [PATCH] make kmem_find_general_cachep static in slab.c Christoph Hellwig
2004-09-07 16:50 ` Manfred Spraul [this message]
2004-09-07 16:52   ` Christoph Hellwig

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=413DE6C9.5050402@colorfullife.com \
    --to=manfred@colorfullife.com \
    --cc=akpm@osdl.org \
    --cc=hch@lst.de \
    --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