public inbox for linux-block@vger.kernel.org
 help / color / mirror / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Jianchao Wang <jianchao.w.wang@oracle.com>
Cc: axboe@kernel.dk, linux-block@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] block: don't check position contiguity for DISCARD in attempt_merge
Date: Fri, 19 Oct 2018 11:57:18 -0400	[thread overview]
Message-ID: <yq15zxyj5ep.fsf@oracle.com> (raw)
In-Reply-To: <1539941093-32058-1-git-send-email-jianchao.w.wang@oracle.com> (Jianchao Wang's message of "Fri, 19 Oct 2018 17:24:53 +0800")


Jianchao,

> Discard command supports multiple ranges of blocks, so needn't
> checking position contiguity when merging. Let's do the same thing
> in attempt_merge as the blk_try_merge.

Discards need to be contiguous unless queue->limits.max_discard_segments
is bigger than 1. So if you remove this I think you need to add a
contiguity check in req_attempt_discard_merge().

-- 
Martin K. Petersen	Oracle Linux Engineering

  parent reply	other threads:[~2018-10-19 15:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-19  9:24 [PATCH] block: don't check position contiguity for DISCARD in attempt_merge Jianchao Wang
2018-10-19  9:46 ` Ming Lei
2018-10-19 15:57 ` Martin K. Petersen [this message]
2018-10-20 13:57   ` jianchao.wang

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=yq15zxyj5ep.fsf@oracle.com \
    --to=martin.petersen@oracle.com \
    --cc=axboe@kernel.dk \
    --cc=jianchao.w.wang@oracle.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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