From: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
To: kosaki.motohiro@jp.fujitsu.com
Cc: linux-kernel@vger.kernel.org
Subject: Re: Q: semaphore and kmalloc(GFP_KERNEL)?
Date: Mon, 11 May 2009 12:19:09 +0900 [thread overview]
Message-ID: <200905110319.n4B3J9hc092830@www262.sakura.ne.jp> (raw)
In-Reply-To: <20090511115410.B0EA.A69D9226@jp.fujitsu.com>
KOSAKI Motohiro wrote:
> > Can the kernel detect that we need to let kmalloc() fail and
> > wake up the writer process so that the writer process releases
> > the rw_semaphore and reader processes can continue?
>
> it can't. Plus it shouldn't.
> some caller don't want kmalloc() failure.
Thanks.
Then, should I move kmalloc(GFP_KERNEL) to outside the lock whenever possible?
(I worry some lock held by the caller interferes kmalloc(GFP_KERNEL).)
next prev parent reply other threads:[~2009-05-11 3:19 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-11 2:30 Tetsuo Handa
2009-05-11 2:56 ` KOSAKI Motohiro
2009-05-11 3:19 ` Tetsuo Handa [this message]
2009-05-11 3:21 ` KOSAKI Motohiro
2009-05-11 3:26 ` Tetsuo Handa
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=200905110319.n4B3J9hc092830@www262.sakura.ne.jp \
--to=penguin-kernel@i-love.sakura.ne.jp \
--cc=kosaki.motohiro@jp.fujitsu.com \
--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
all inboxes | Powered by JetHome®