mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Milan Broz <gmazyland@gmail.com>
Cc: linux-block <linux-block@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Ondrej Kozina <okozina@redhat.com>
Subject: Re: Partial direct-io loop regression in 5.17-rc
Date: Fri, 4 Feb 2022 08:33:47 -0700	[thread overview]
Message-ID: <65bfe3d6-504c-8fba-2bf4-541ab24b324b@kernel.dk> (raw)
In-Reply-To: <54f98c2a-4a40-75ed-8f66-11cc6b2fd190@gmail.com>

On 2/4/22 8:03 AM, Milan Broz wrote:
> 
> 
> On 04/02/2022 14:32, Jens Axboe wrote:
>> On 2/4/22 2:22 AM, Milan Broz wrote:
>>> Hi Jens,
>>>
>>> It seems that there is a regression in direct-io over loop for partial
>>> direct-io reads (or perhaps even for other situations).
>>>
>>> If I run this code (loop over 6M file, dd direct-io read with 4M blocks)
>>>
>>> IMG=tst.img
>>> LOOP=/dev/loop66
>>>
>>> truncate -s 6M $IMG
>>> losetup $LOOP $IMG
>>> dd if=$LOOP of=/dev/null bs=4M iflag=direct
>>> losetup -d $LOOP
>>>
>>>
>>> on older kernel (<=5.16) it reads the whole file
>>>     6291456 bytes (6.3 MB, 6.0 MiB) copied, 0.201591 s, 31.2 MB/s
>>>
>>>
>>> while on 5.17-rc (tested on today/s Linus' git) it reads only the full blocks:
>>>     4194304 bytes (4.2 MB, 4.0 MiB) copied, 0.201904 s, 20.8 MB/s
>>>
>>> No error reported, exit code is 0.
>>
>> Can you try:
>>
>> https://git.kernel.dk/cgit/linux-block/commit/?h=block-5.17&id=3e1f941dd9f33776b3df4e30f741fe445ff773f3
> 
> Yes, it works now.
> (Not sure why I did not check if this patch is mainline, as I know
> about it. My bad...)
> 
> So this is going to some next rc, right?

Yes, it'll be in -rc3, pushing it out today or tomorrow.

-- 
Jens Axboe


      reply	other threads:[~2022-02-04 15:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-04  9:22 Milan Broz
2022-02-04 13:32 ` Jens Axboe
2022-02-04 15:03   ` Milan Broz
2022-02-04 15:33     ` Jens Axboe [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=65bfe3d6-504c-8fba-2bf4-541ab24b324b@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=gmazyland@gmail.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=okozina@redhat.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

Powered by JetHome