archive mirror
 help / color / mirror / Atom feed
From: Chao Yu <>
To: Damien Le Moal <>,
	Jaegeuk Kim <>,
Cc: <>,
	Matias Bjorling <>,
	Masato Suzuki <>
Subject: Re: [PATCH 3/3] f2fs: improve discard handling with multi-device volumes
Date: Tue, 19 Mar 2019 19:02:39 +0800	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

On 2019/3/16 8:13, Damien Le Moal wrote:
> f2fs_hw_support_discard() only tests if the super block device supports
> discard. However, for a multi-device volume, not all disks used may
> support discard. Improve the check performed to test all devices of
> the volume and report discard as supported if at least one device of
> the volume supports discard. To implement this, introduce the helper
> function f2fs_bdev_support_discard(), which returns true for zoned block
> devices (where discard is processed as a zone reset) and for regular
> disks supporting the discard command.
> f2fs_bdev_support_discard() is also used in __queue_discard_cmd() to
> handle discard command issuing for a particular device of the volume.
> That is, prevent issuing a discard command for block devices that do
> not support it.
> Signed-off-by: Damien Le Moal <>

Reviewed-by: Chao Yu <>


      reply	other threads:[~2019-03-19 11:02 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-16  0:13 [PATCH V2 0/3] f2fs: bug fix and improvement Damien Le Moal
2019-03-16  0:13 ` [PATCH 1/3] f2fs: Fix use of number of devices Damien Le Moal
2019-03-16  0:13 ` [PATCH 2/3] f2fs: Reduce zoned block device memory usage Damien Le Moal
2019-03-19 11:01   ` Chao Yu
2019-03-16  0:13 ` [PATCH 3/3] f2fs: improve discard handling with multi-device volumes Damien Le Moal
2019-03-19 11:02   ` Chao Yu [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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \

* 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;
as well as URLs for NNTP newsgroup(s).