linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bart Van Assche <bvanassche@acm.org>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-block@vger.kernel.org, linux-scsi@vger.kernel.org,
	linux-fsdevel@vger.kernel.org,
	"Martin K . Petersen" <martin.petersen@oracle.com>,
	Christoph Hellwig <hch@lst.de>,
	Niklas Cassel <Niklas.Cassel@wdc.com>,
	Avri Altman <Avri.Altman@wdc.com>, Bean Huo <huobean@gmail.com>,
	Daejun Park <daejun7.park@samsung.com>,
	Bart Van Assche <bvanassche@acm.org>
Subject: [PATCH v3 00/14] Pass data temperature information to SCSI disk devices
Date: Tue, 17 Oct 2023 13:47:08 -0700	[thread overview]
Message-ID: <20231017204739.3409052-1-bvanassche@acm.org> (raw)

Hi Jens,

UFS vendors need the data lifetime information to achieve good performance.
Without this information there is significantly higher write amplification due
to garbage collection. Hence this patch series that add support in F2FS and
also in the block layer for data lifetime information. The SCSI disk (sd)
driver is modified such that it passes write hint information to SCSI devices
via the GROUP NUMBER field.

Please consider this patch series for the next merge window.

Thanks,

Bart.

Changes compared to v1:
- Instead of storing data lifetime information in bi_ioprio, introduce the
  new struct bio member bi_lifetime and also the struct request member
  'lifetime'.
- Removed the bio_set_data_lifetime() and bio_get_data_lifetime() functions
  and replaced these with direct assignments.
- Dropped all changes related to I/O priority.
- Improved patch descriptions.

Changes compared to v1:
- Use six bits from the ioprio field for data lifetime information. The
  bio->bi_write_hint / req->write_hint / iocb->ki_hint members that were
  introduced in v1 have been removed again.
- The F_GET_FILE_RW_HINT and F_SET_FILE_RW_HINT fcntls have been removed.
- In the SCSI disk (sd) driver, query the stream status and check the PERM bit.
- The GET STREAM STATUS command has been implemented in the scsi_debug driver.

Bart Van Assche (14):
  fs: Move enum rw_hint into a new header file
  block: Restore data lifetime support in struct bio and struct request
  fs: Restore write hint support
  fs/f2fs: Restore data lifetime support
  scsi: core: Query the Block Limits Extension VPD page
  scsi_proto: Add structures and constants related to I/O groups and
    streams
  sd: Translate data lifetime information
  scsi_debug: Reduce code duplication
  scsi_debug: Support the block limits extension VPD page
  scsi_debug: Rework page code error handling
  scsi_debug: Rework subpage code error handling
  scsi_debug: Implement the IO Advice Hints Grouping mode page
  scsi_debug: Implement GET STREAM STATUS
  scsi_debug: Maintain write statistics per group number

 Documentation/filesystems/f2fs.rst |  70 ++++++++
 block/bio.c                        |   2 +
 block/blk-crypto-fallback.c        |   1 +
 block/blk-merge.c                  |   6 +
 block/blk-mq.c                     |   1 +
 block/bounce.c                     |   1 +
 block/fops.c                       |   3 +
 drivers/scsi/scsi.c                |   2 +
 drivers/scsi/scsi_debug.c          | 247 +++++++++++++++++++++--------
 drivers/scsi/scsi_sysfs.c          |  10 ++
 drivers/scsi/sd.c                  | 111 ++++++++++++-
 drivers/scsi/sd.h                  |   3 +
 fs/f2fs/data.c                     |   2 +
 fs/f2fs/f2fs.h                     |  10 ++
 fs/f2fs/segment.c                  |  95 +++++++++++
 fs/f2fs/super.c                    |  32 +++-
 fs/fcntl.c                         |   1 +
 fs/inode.c                         |   1 +
 fs/iomap/buffered-io.c             |   2 +
 fs/iomap/direct-io.c               |   1 +
 fs/mpage.c                         |   1 +
 include/linux/blk-mq.h             |   2 +
 include/linux/blk_types.h          |   2 +
 include/linux/fs.h                 |  16 +-
 include/linux/rw_hint.h            |  20 +++
 include/scsi/scsi_device.h         |   1 +
 include/scsi/scsi_proto.h          |  75 +++++++++
 27 files changed, 635 insertions(+), 83 deletions(-)
 create mode 100644 include/linux/rw_hint.h


             reply	other threads:[~2023-10-17 20:48 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-17 20:47 Bart Van Assche [this message]
2023-10-17 20:47 ` [PATCH v3 01/14] fs: Move enum rw_hint into a new header file Bart Van Assche
2023-10-30 11:11   ` Kanchan Joshi
2023-10-30 16:10     ` Bart Van Assche
     [not found]     ` <CGME20231017204823epcas5p2798d17757d381aaf7ad4dd235f3f0da3@epcms2p1>
2023-11-01  6:39       ` Daejun Park
2023-11-01 16:45         ` (2) " Bart Van Assche
     [not found]         ` <CGME20231017204823epcas5p2798d17757d381aaf7ad4dd235f3f0da3@epcms2p3>
2023-11-02  7:31           ` Daejun Park
2023-10-17 20:47 ` [PATCH v3 02/14] block: Restore data lifetime support in struct bio and struct request Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 03/14] fs: Restore write hint support Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 04/14] fs/f2fs: Restore data lifetime support Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 05/14] scsi: core: Query the Block Limits Extension VPD page Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 06/14] scsi_proto: Add structures and constants related to I/O groups and streams Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 07/14] sd: Translate data lifetime information Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 08/14] scsi_debug: Reduce code duplication Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 09/14] scsi_debug: Support the block limits extension VPD page Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 10/14] scsi_debug: Rework page code error handling Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 11/14] scsi_debug: Rework subpage " Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 12/14] scsi_debug: Implement the IO Advice Hints Grouping mode page Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 13/14] scsi_debug: Implement GET STREAM STATUS Bart Van Assche
2023-10-17 20:47 ` [PATCH v3 14/14] scsi_debug: Maintain write statistics per group number Bart Van Assche
2023-10-18 19:09 ` [PATCH v3 00/14] Pass data temperature information to SCSI disk devices Jens Axboe
2023-10-18 19:34   ` Bart Van Assche
2023-10-19  0:33     ` Damien Le Moal
2023-10-19 16:48       ` Bart Van Assche
2023-10-19 22:40         ` Damien Le Moal
2023-10-19 23:00           ` Damien Le Moal
2023-10-20 20:45   ` Bart Van Assche

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=20231017204739.3409052-1-bvanassche@acm.org \
    --to=bvanassche@acm.org \
    --cc=Avri.Altman@wdc.com \
    --cc=Niklas.Cassel@wdc.com \
    --cc=axboe@kernel.dk \
    --cc=daejun7.park@samsung.com \
    --cc=hch@lst.de \
    --cc=huobean@gmail.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.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;
as well as URLs for NNTP newsgroup(s).