From: Andrew Morton <akpm@digeo.com>
To: Paul Larson <plars@linuxtestproject.org>
Cc: William Lee Irwin III <wli@holomorphy.com>,
linux-mm <linux-mm@kvack.org>
Subject: Re: Hangs in 2.5.41-mm1
Date: Wed, 09 Oct 2002 14:29:29 -0700 [thread overview]
Message-ID: <3DA49FB9.5551F0D2@digeo.com> (raw)
In-Reply-To: <1034198228.30973.70.camel@plars>
Paul Larson wrote:
>
> I got an oops out of it this time, after running it that test several
> times, I retried case 2 and got this:
>
> ...
> EIP is at cache_alloc_refill+0xbb/0x170
I seem to be giving this patch to everyone lately. Hopefully
it will fix that.
--- 2.5.41/mm/slab.c~slab-split-10-list_for_each_fix Tue Oct 8 15:40:52 2002
+++ 2.5.41-akpm/mm/slab.c Tue Oct 8 15:40:52 2002
@@ -461,7 +461,7 @@ static kmem_cache_t cache_cache = {
static struct semaphore cache_chain_sem;
static rwlock_t cache_chain_lock = RW_LOCK_UNLOCKED;
-#define cache_chain (cache_cache.next)
+struct list_head cache_chain;
/*
* chicken and egg problem: delay the per-cpu array allocation
@@ -617,6 +617,7 @@ void __init kmem_cache_init(void)
init_MUTEX(&cache_chain_sem);
INIT_LIST_HEAD(&cache_chain);
+ list_add(&cache_cache.next, &cache_chain);
cache_estimate(0, cache_cache.objsize, 0,
&left_over, &cache_cache.num);
@@ -2093,10 +2094,10 @@ static void *s_start(struct seq_file *m,
down(&cache_chain_sem);
if (!n)
return (void *)1;
- p = &cache_cache.next;
+ p = cache_chain.next;
while (--n) {
p = p->next;
- if (p == &cache_cache.next)
+ if (p == &cache_chain)
return NULL;
}
return list_entry(p, kmem_cache_t, next);
@@ -2107,9 +2108,9 @@ static void *s_next(struct seq_file *m,
kmem_cache_t *cachep = p;
++*pos;
if (p == (void *)1)
- return &cache_cache;
- cachep = list_entry(cachep->next.next, kmem_cache_t, next);
- return cachep == &cache_cache ? NULL : cachep;
+ return list_entry(cache_chain.next, kmem_cache_t, next);
+ return cachep->next.next == &cache_chain ? NULL
+ : list_entry(cachep->next.next, kmem_cache_t, next);
}
static void s_stop(struct seq_file *m, void *p)
.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
next prev parent reply other threads:[~2002-10-09 21:29 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-10-09 18:36 Paul Larson
2002-10-09 20:17 ` Andrew Morton
2002-10-09 20:29 ` Paul Larson
2002-10-09 21:00 ` William Lee Irwin III
2002-10-09 21:17 ` Paul Larson
2002-10-09 21:29 ` Andrew Morton [this message]
2002-10-09 21:32 ` Andrew Morton
2002-10-10 15:45 ` Paul Larson
2002-10-10 16:53 ` Andrew Morton
2002-10-10 17:01 ` Andrew Morton
2002-10-10 18:32 ` William Lee Irwin III
2002-10-10 18:39 ` Manfred Spraul
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=3DA49FB9.5551F0D2@digeo.com \
--to=akpm@digeo.com \
--cc=linux-mm@kvack.org \
--cc=plars@linuxtestproject.org \
--cc=wli@holomorphy.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox