From: Andrew Morton <akpm@osdl.org>
To: "Zou, Nanhai" <nanhai.zou@intel.com>
Cc: linux-kernel@vger.kernel.org, davidm@napali.hpl.hp.com,
tony.luck@intel.com
Subject: Re: [Patch 2.6.7]might-sleep-in-atomic while dumping elf
Date: Wed, 4 Aug 2004 15:46:44 -0700 [thread overview]
Message-ID: <20040804154644.211c5ae5.akpm@osdl.org> (raw)
In-Reply-To: <C0ECD887E2CBE349ACF9C483510BF8381C22DD@pdsmsx401.ccr.corp.intel.com>
"Zou, Nanhai" <nanhai.zou@intel.com> wrote:
>
> Here is a patch to fix a problem of might-sleep-in-atomic which
> David Mosberger mentioned at
> http://www.gelato.unsw.edu.au/linux-ia64/0407/10526.html
>
> On IA64 platform, a might-sleep-in-atomic warning raise while dumping a
> multi-thread process.
> That is because elf_cord_dump hold the tasklist_lock before kernel doing
> a access_process_vm in elf_core_copy_task_regs,
>
> This patch detached elf_core_copy_task_regs function from inside
> tasklist_lock to remove the warning.
hm, OK, no worse than what we had there before :(
That GFP_ATOMIC allocation of one 824-byte-on-x86 structure for each
thread looks really, really nasty. It could easily chew up 100% of the page
reserves and fail. I wonder if it is safe to drop the tasklist_lock while we
allocate the memory?
You're still testing for a zero return from elf_dump_thread_status(). I
think that with your changes, that is no longer possible, is it?
Please edit in 80-col xterms. You'll find that a layout such as the below
becomes more agreeable.
+ list_for_each(t, &thread_list) {
+ struct elf_thread_status *tmp;
+ int sz;
+
+ tmp = list_entry(t, struct elf_thread_status, list);
+ sz = elf_dump_thread_status(signr, tmp);
next prev parent reply other threads:[~2004-08-04 22:43 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-08-04 1:45 Zou, Nanhai
2004-08-04 22:46 ` Andrew Morton [this message]
2004-08-05 2:53 Zou, Nanhai
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=20040804154644.211c5ae5.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=davidm@napali.hpl.hp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nanhai.zou@intel.com \
--cc=tony.luck@intel.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
all inboxes | Powered by JetHome®