Skip to content

rewrites discard support

Ming Lin linux-nvme 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v2 Latest4 patches 0 repliesNew

Changes in v2 from the cover letter

- add helper nvme_map_len()
- allocates only 16 bytes for discard payload
- moves command setup to common helper nvme_setup_cmd()
- returns BLK_MQ_RQ_QUEUE_BUSY when out of memory

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4nvme: add helper nvme_map_len()drivers/nvme/host/nvme.h drivers/nvme/host/pci.c+13 -81 reply
2/4block: add offset in blk_add_request_payload()block/blk-core.c drivers/block/skd_main.c drivers/scsi/sd.c +1 more+6 -51 reply
3/4nvme: rewrite discard supportdrivers/nvme/host/pci.c+39 -291 reply
4/4nvme: add helper nvme_setup_cmd()drivers/nvme/host/core.c drivers/nvme/host/nvme.h drivers/nvme/host/pci.c+108 -971 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/4] rewrites discard support

From: Ming Lin <[email protected]>

This rewrites nvme_setup_discard() with blk_add_request_payload(). And moves it to common code so fabrics driver can also use it.

v2:
- add helper nvme_map_len()
- allocates only 16 bytes for discard payload
- moves command setup to common helper nvme_setup_cmd()
- returns BLK_MQ_RQ_QUEUE_BUSY when out of memory

Ming Lin (4):
nvme: add helper nvme_map_len()
block: add offset in blk_add_request_payload()
nvme: rewrite discard support
nvme: add helper nvme_setup_cmd()

 block/blk-core.c         |   5 ++-
 drivers/block/skd_main.c |   2 +-
 drivers/nvme/host/core.c | 105 +++++++++++++++++++++++++++++++++++++++++++++++
 drivers/nvme/host/nvme.h |  55 ++++---------------------
 drivers/nvme/host/pci.c  |  68 +++++++-----------------------
 drivers/scsi/sd.c        |   2 +-
 include/linux/blkdev.h   |   2 +-
 7 files changed, 133 insertions(+), 106 deletions(-)
Signature · 1 line
1.9.1