From: Manfred Spraul <manfred@colorfullife.com>
To: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Cc: Oleg <graycardinal@pisem.net>, linux-kernel@vger.kernel.org
Subject: Re: PROBLEM: kmem_cache_create: duplicate cache fat_cache
Date: Mon, 06 Jun 2005 21:43:54 +0200 [thread overview]
Message-ID: <42A4A77A.5060101@colorfullife.com> (raw)
In-Reply-To: <87br779jen.fsf@devron.myhome.or.jp>
[-- Attachment #1: Type: text/plain, Size: 432 bytes --]
OGAWA Hirofumi wrote:
>Ummm... why is this normal situation? Didn't you run the
>modules_install after changed .config? Anyway, this patch returns
>NULL instead of calling BUG(). This case seems to also happen with
>user error.
>
>
>
Either return NULL or ignore the collision. I don't know what's the
better solution.
I'm open to either approach - it depends on what the kmem_cache_create()
caller expects.
--
Manfred
[-- Attachment #2: patch-slab-nobug --]
[-- Type: text/plain, Size: 615 bytes --]
--- 2.6/mm/slab.c 2005-06-05 17:29:01.000000000 +0200
+++ build-2.6/mm/slab.c 2005-06-06 21:34:38.000000000 +0200
@@ -1480,9 +1480,14 @@
}
if (!strcmp(pc->name,name)) {
printk("kmem_cache_create: duplicate cache %s\n",name);
- up(&cache_chain_sem);
- unlock_cpu_hotplug();
- BUG();
+ /* This is a severe bug, because it breaks
+ * tuning by writing to /proc/slabinfo.
+ * But everything else works, and since
+ * duplicate caches typically happen if
+ * someone inserts a module twice, we'll
+ * continue.
+ */
+ WARN_ON(1);
}
}
set_fs(old_fs);
next prev parent reply other threads:[~2005-06-06 19:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-18 8:17 PROBLEM: kmem_cache_create: duplicate cache fat_cache Oleg
2005-05-19 18:10 ` OGAWA Hirofumi
2005-05-20 14:31 ` Re[2]: " Oleg
2005-05-20 13:16 ` OGAWA Hirofumi
2005-06-06 19:43 ` Manfred Spraul [this message]
2005-06-07 14:26 ` OGAWA Hirofumi
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=42A4A77A.5060101@colorfullife.com \
--to=manfred@colorfullife.com \
--cc=graycardinal@pisem.net \
--cc=hirofumi@mail.parknet.co.jp \
--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