From: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
To: Christoph Lameter <cl@linux-foundation.org>,
Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] Add might_sleep_if() for slub
Date: Wed, 19 Nov 2008 21:23:59 +0900 [thread overview]
Message-ID: <87abbv29b4.fsf@devron.myhome.or.jp> (raw)
Hi,
I don't know it is intention, or not. However, current SLUB not seems to
warn about might_sleep_if(gfpflags & __GFP_WAIT);
If it's not intention, please apply.
--
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Currently SLUB doesn't warn about __GFP_WAIT. Add it into slab_alloc().
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
---
mm/slub.c | 1 +
1 file changed, 1 insertion(+)
diff -puN mm/slub.c~slub-might-sleep mm/slub.c
--- linux-2.6/mm/slub.c~slub-might-sleep 2008-11-19 20:57:28.000000000 +0900
+++ linux-2.6-hirofumi/mm/slub.c 2008-11-19 20:57:28.000000000 +0900
@@ -1591,6 +1591,7 @@ static __always_inline void *slab_alloc(
unsigned long flags;
unsigned int objsize;
+ might_sleep_if(gfpflags & __GFP_WAIT);
local_irq_save(flags);
c = get_cpu_slab(s, smp_processor_id());
objsize = c->objsize;
_
next reply other threads:[~2008-11-19 12:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-19 12:23 OGAWA Hirofumi [this message]
2008-11-19 19:28 ` [PATCH] Add might_sleep_if() for slub Christoph Lameter
2008-11-20 9:28 ` Pekka Enberg
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=87abbv29b4.fsf@devron.myhome.or.jp \
--to=hirofumi@mail.parknet.co.jp \
--cc=akpm@linux-foundation.org \
--cc=cl@linux-foundation.org \
--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 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.