aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/elevator.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2017-02-08 14:46:49 +0100
committerJens Axboe <axboe@fb.com>2017-02-08 13:43:08 -0700
commit1e739730c5b9ea80a2f25e9cf6e1025d47e3d8ed (patch)
tree4f48ed6c92153fb9941185182e918232eb3472f4 /include/linux/elevator.h
parentblock: enumify ELEVATOR_*_MERGE (diff)
downloadwireguard-linux-1e739730c5b9ea80a2f25e9cf6e1025d47e3d8ed.tar.xz
wireguard-linux-1e739730c5b9ea80a2f25e9cf6e1025d47e3d8ed.zip
block: optionally merge discontiguous discard bios into a single request
Add a new merge strategy that merges discard bios into a request until the maximum number of discard ranges (or the maximum discard size) is reached from the plug merging code. I/O scheduler merging is not wired up yet but might also be useful, although not for fast devices like NVMe which are the only user for now. Note that for now we don't support limiting the size of each discard range, but if needed that can be added later. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'include/linux/elevator.h')
-rw-r--r--include/linux/elevator.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/elevator.h b/include/linux/elevator.h
index b38b4e651ea6..8265b6330cc2 100644
--- a/include/linux/elevator.h
+++ b/include/linux/elevator.h
@@ -16,6 +16,7 @@ enum elv_merge {
ELEVATOR_NO_MERGE = 0,
ELEVATOR_FRONT_MERGE = 1,
ELEVATOR_BACK_MERGE = 2,
+ ELEVATOR_DISCARD_MERGE = 3,
};
typedef enum elv_merge (elevator_merge_fn) (struct request_queue *, struct request **,