From: Andrea Arcangeli <andrea@suse.de>
To: "David S. Miller" <davem@redhat.com>
Cc: Trond Myklebust <trond.myklebust@fys.uio.no>,
Jeff Garzik <jgarzik@pobox.com>, Andrew Morton <akpm@digeo.com>,
Marc-Christian Petersen <m.c.p@wolk-project.de>,
t.baetzler@bringe.com, linux-kernel@vger.kernel.org,
marcelo@conectiva.com.br
Subject: Re: xdr nfs highmem deadlock fix [Re: filesystem access slowing system to a crawl]
Date: Sun, 23 Feb 2003 16:22:36 +0100 [thread overview]
Message-ID: <20030223152236.GC29467@dualathlon.random> (raw)
In-Reply-To: <1045874441.25412.0.camel@rth.ninka.net>
On Fri, Feb 21, 2003 at 04:40:41PM -0800, David S. Miller wrote:
> On Fri, 2003-02-21 at 01:41, Andrea Arcangeli wrote:
> > On Fri, Feb 21, 2003 at 12:12:19AM +0100, Trond Myklebust wrote:
> > > >>>>> " " == Jeff Garzik <jgarzik@pobox.com> writes:
> > >
> > > > One should also consider kmap_atomic... (bcrl suggest)
> > >
> > > The problem is that sendmsg() can sleep. kmap_atomic() isn't really
> > > appropriate here.
> >
> > 100% correct.
>
> It actually depends upon whether you have sk->priority set
> to GFP_ATOMIC or GFP_KERNEL.
You must not disable preemption when entering sock_sendmsg no matter
sk->priority. disabling preemption inside sock_sendmsg is way too late
so even if you have such preemption bug in sock_sendmsg, it won't help.
you would need to disable preemption in the caller before doing the
kmap_atomic if something. And again that is a preemption bug.
Not to tell you'd need to allocate a big pool of atomic kmaps to do
that, and this would eat hundred megs of virtual address space since
it's replicated per-cpu. This is has even less sense, those machines
where the highmem deadlock triggers eats normal zone big time.
Really, the claim that it can be solved with atomic kmaps doesn't make
any sense to me, nor the fact the sock_sendmsg will not schedule if
called with GFP_ATOMIC. Of course it must not schedule if it can be
called from an irq with priority=GFP_ATOMIC, but this isn't the case
we're discussing here, an irq implicitly just disabled preemption by
design and calling sock_sendmsg from irq isn't really desiderable (even
if technically possible maybe with priority=GFP_ATOMIC according to you)
because it will take some time.
Andrea
next prev parent reply other threads:[~2003-02-23 15:12 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-04 9:29 filesystem access slowing system to a crawl Thomas Bätzler
2003-02-05 9:03 ` Denis Vlasenko
2003-02-05 9:39 ` Andrew Morton
2003-02-19 16:42 ` Marc-Christian Petersen
2003-02-19 17:49 ` Andrea Arcangeli
2003-02-20 15:29 ` Marc-Christian Petersen
2003-02-20 18:35 ` Andrew Morton
2003-02-20 21:32 ` Marc-Christian Petersen
2003-02-20 21:41 ` Andrew Morton
2003-02-20 22:08 ` Andrea Arcangeli
2003-02-20 21:54 ` xdr nfs highmem deadlock fix [Re: filesystem access slowing system to a crawl] Andrea Arcangeli
2003-02-20 22:56 ` Trond Myklebust
2003-02-20 23:04 ` Jeff Garzik
2003-02-20 23:12 ` Trond Myklebust
2003-02-21 9:41 ` Andrea Arcangeli
2003-02-22 0:40 ` David S. Miller
2003-02-23 15:22 ` Andrea Arcangeli [this message]
2003-02-21 9:41 ` Andrea Arcangeli
2003-02-21 9:37 ` Andrea Arcangeli
2003-02-21 20:52 ` Andrew Morton
2003-02-21 21:32 ` Trond Myklebust
2003-02-20 23:15 ` Andreas Dilger
2003-02-21 9:46 ` Andrea Arcangeli
2003-02-21 19:41 ` Andreas Dilger
2003-02-21 19:46 ` Andrea Arcangeli
2003-02-26 23:17 ` filesystem access slowing system to a crawl Marc-Christian Petersen
2003-02-27 8:51 ` Marc-Christian Petersen
2003-02-20 19:30 ` William Stearns
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=20030223152236.GC29467@dualathlon.random \
--to=andrea@suse.de \
--cc=akpm@digeo.com \
--cc=davem@redhat.com \
--cc=jgarzik@pobox.com \
--cc=linux-kernel@vger.kernel.org \
--cc=m.c.p@wolk-project.de \
--cc=marcelo@conectiva.com.br \
--cc=t.baetzler@bringe.com \
--cc=trond.myklebust@fys.uio.no \
/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