From: Richard Yao <ryao@gentoo.org>
To: gentoo-dev@lists.gentoo.org
Cc: Sergei Trofimovich <slyfox@gentoo.org>,
Kernel development list <linux-kernel@vger.kernel.org>,
kernel@gentoo.org, gentooligan@gmail.com
Subject: Re: [gentoo-dev] dm-crypt reordering BIOs across barriers?
Date: Sat, 08 Jun 2013 05:17:08 -0400 [thread overview]
Message-ID: <51B2F694.7010008@gentoo.org> (raw)
In-Reply-To: <20130608091114.441c5f17@sf>
[-- Attachment #1: Type: text/plain, Size: 1116 bytes --]
On 06/08/2013 02:11 AM, Sergei Trofimovich wrote:
> On Fri, 07 Jun 2013 23:47:33 -0400
> Richard Yao <ryao@gentoo.org> wrote:
>
>> When you use dm-crypt, block IO requests to a dm-* device will invoke
>> dm_request_fn() -> map_request() -> crypt_map(). If a BIO is a write
>> barrier, crypt_map() will return DM_MAPIO_REMAPPED to map_request(),
>> which will immediately queue it to the device.
>>
>> If a few dozen IOs are queued in rapid succession with multiple write
>> barriers, all write barriers will be executed before any actual write
>> BIOs occur because the write IOs will be processed asynchronously in a
>> work queue. Since the barriers will be long gone by the time the write
>> IOs are queued, they can be queued in any order.
>>
>> Am I misunderstanding this or is dm-crypt ignoring proper write barrier
>> semantics?
>>
> http://www.saout.de/pipermail/dm-crypt/2012-April/002441.html
> http://lwn.net/Articles/400541/
>
It might be worth stating that I thought flush was a synonym for
barrier. It still looks like there is an issue, despite my incorrect
terminology.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 901 bytes --]
prev parent reply other threads:[~2013-06-08 9:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-08 3:47 dm-crypt reordering BIOs across barriers? Richard Yao
2013-06-08 6:11 ` [gentoo-dev] " Sergei Trofimovich
2013-06-08 9:17 ` Richard Yao [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=51B2F694.7010008@gentoo.org \
--to=ryao@gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
--cc=gentooligan@gmail.com \
--cc=kernel@gentoo.org \
--cc=linux-kernel@vger.kernel.org \
--cc=slyfox@gentoo.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