public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Stephen C. Tweedie" <sct@redhat.com>
To: Manfred Spraul <manfred@colorfullife.com>
Cc: linux-kernel@vger.kernel.org, Stephen Tweedie <sct@redhat.com>
Subject: Re: lock_kiovec question
Date: Wed, 3 Oct 2001 17:30:16 +0100	[thread overview]
Message-ID: <20011003173016.C5209@redhat.com> (raw)
In-Reply-To: <3BB58FAF.D1AF2D25@colorfullife.com>
In-Reply-To: <3BB58FAF.D1AF2D25@colorfullife.com>; from manfred@colorfullife.com on Sat, Sep 29, 2001 at 11:09:03AM +0200

Hi,

On Sat, Sep 29, 2001 at 11:09:03AM +0200, Manfred Spraul wrote:
> lock_kiovec tries to lock each page in the kiovec, and fails if it can't
> lock one of the pages.
> 
> What if the zero page is mapped multiple times in the kiobuf?

Don't Do That then.  lock_kiobuf can be called if some caller really
wants the kiobuf pages locked, but kiobuf page mapping is much cleaner
in 2.4 than it had to be in 2.2 and there's no need to keep pages
locked during the mapping.  raw IO doesn't ever use lock_kiobuf in
2.4.

> AFAICS map_user_pages doesn't break zero page mappings if it's called
> with rw==WRITE (i.e write to disk, read from kiobuf)

Correct.  The raw IO code for 2.2 had to exempt zero pages from
locking for this reason.

Cheers,
 Stephen

      parent reply	other threads:[~2001-10-03 16:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-09-29  9:09 lock_kiovec question Manfred Spraul
2001-09-29 17:51 ` Benjamin LaHaise
2001-10-03 16:30 ` Stephen C. Tweedie [this message]

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=20011003173016.C5209@redhat.com \
    --to=sct@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=manfred@colorfullife.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