All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nick Piggin <nickpiggin@yahoo.com.au>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Matt Mackall <mpm@selenic.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linux Memory Management <linux-mm@kvack.org>
Subject: Re: [patch] slob: implement RCU freeing
Date: Thu, 10 May 2007 18:26:57 +1000	[thread overview]
Message-ID: <4642D751.4060103@yahoo.com.au> (raw)
In-Reply-To: <1178785328.6810.19.camel@twins>

[-- Attachment #1: Type: text/plain, Size: 569 bytes --]

Peter Zijlstra wrote:
> On Thu, 2007-05-10 at 17:15 +1000, Nick Piggin wrote:
> 
> 
>>@@ -283,6 +295,12 @@
>> 	if (c) {
>> 		c->name = name;
>> 		c->size = size;
>>+		if (flags & SLAB_DESTROY_BY_RCU) {
>>+			BUG_ON(c->dtor);
>>+			/* leave room for rcu footer at the end of object */
>>+			c->size += sizeof(struct slob_rcu);
>>+		}
>>+		c->flags = flags;
> 
> 
> might want to put this hunt below
> 
> 
>>		c->ctor = ctor;
>> 		c->dtor = dtor;
> 
> 
> here; for c->dtor is not initialised quite yet at the BUG_ON site.

Indeed, how's this?

-- 
SUSE Labs, Novell Inc.

[-- Attachment #2: slob-add-rcu-fix.patch --]
[-- Type: text/plain, Size: 426 bytes --]

Index: linux-2.6/mm/slob.c
===================================================================
--- linux-2.6.orig/mm/slob.c
+++ linux-2.6/mm/slob.c
@@ -296,7 +296,7 @@ struct kmem_cache *kmem_cache_create(con
 		c->name = name;
 		c->size = size;
 		if (flags & SLAB_DESTROY_BY_RCU) {
-			BUG_ON(c->dtor);
+			BUG_ON(dtor);
 			/* leave room for rcu footer at the end of object */
 			c->size += sizeof(struct slob_rcu);
 		}

  reply	other threads:[~2007-05-10  8:26 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-08 23:02 + fix-spellings-of-slab-allocator-section-in-init-kconfig.patch added to -mm tree akpm
2007-05-09  0:23 ` Matt Mackall
2007-05-09  0:32   ` Alan Cox
2007-05-09  0:33     ` Matt Mackall
2007-05-09  0:43       ` Christoph Lameter
2007-05-09  0:51   ` Christoph Lameter
2007-05-09  1:27     ` Matt Mackall
2007-05-09  1:32       ` Christoph Lameter
2007-05-09  1:51         ` David Miller
2007-05-09  1:53           ` Christoph Lameter
2007-05-09  1:55             ` David Miller
2007-05-09  1:57               ` Christoph Lameter
2007-05-09  2:06                 ` David Miller
2007-05-09  2:10                   ` Nick Piggin
2007-05-09  2:20                     ` Christoph Lameter
2007-05-09  2:02           ` Nick Piggin
2007-05-09  2:56             ` Matt Mackall
2007-05-09  3:18               ` Nick Piggin
2007-05-09  3:27                 ` Christoph Lameter
2007-05-09  3:47                 ` Nick Piggin
2007-05-10  0:42             ` Andrew Morton
2007-05-10  1:00               ` Nick Piggin
2007-05-10  2:27                 ` Matt Mackall
2007-05-10  7:15                   ` [patch] slob: implement RCU freeing Nick Piggin
2007-05-10  7:19                     ` Nick Piggin
2007-05-10  8:22                     ` Peter Zijlstra
2007-05-10  8:26                       ` Nick Piggin [this message]
2007-05-10  8:29                         ` Peter Zijlstra
2007-05-09  2:19         ` + fix-spellings-of-slab-allocator-section-in-init-kconfig.patch added to -mm tree Matt Mackall
2007-05-09  2:24           ` Christoph Lameter
2007-05-09  2:43             ` Nick Piggin
2007-05-09  2:57               ` Christoph Lameter
2007-05-09  3:04                 ` Nick Piggin
2007-05-09  3:08                   ` Christoph Lameter
2007-05-09  3:25                 ` Matt Mackall
2007-05-09  3:16             ` Matt Mackall
2007-05-09  3:24               ` Christoph Lameter
  -- strict thread matches above, loose matches on Subject: below --
2007-05-09  4:17 [patch] slob: implement RCU freeing Nick Piggin

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=4642D751.4060103@yahoo.com.au \
    --to=nickpiggin@yahoo.com.au \
    --cc=a.p.zijlstra@chello.nl \
    --cc=akpm@linux-foundation.org \
    --cc=linux-mm@kvack.org \
    --cc=mpm@selenic.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.