]> git.baikalelectronics.ru Git - kernel.git/commit
nvmet: support fabrics sq flow control
authorSagi Grimberg <sagi@grimberg.me>
Mon, 19 Nov 2018 22:11:12 +0000 (14:11 -0800)
committerJens Axboe <axboe@kernel.dk>
Sat, 8 Dec 2018 05:26:57 +0000 (22:26 -0700)
commit5c46fd48dfbf908970cf5e14c8f051e6f2cf01a5
tree23c128b4f918466bea9dc3c7a2669ea9916ea849
parente7df808f6d65dcdf091ffa6f45bab1c3cb55d66a
nvmet: support fabrics sq flow control

Technical proposal 8005 "fabrics SQ flow control" introduces a mode
where a host and controller agree to omit sq_head pointer updates
when sending nvme completions.

In case the host indicated desire to operate in this mode (connect attribute)
the controller will return back a connect completion with sq_head value
of 0xffff as indication that it will omit sq_head pointer updates.

This mode saves us an atomic update in the I/O path.

Reviewed-by: Hannes Reinecke <hare@suse.com>
[hch: suggested better implementation]
Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/nvme/target/core.c
drivers/nvme/target/fabrics-cmd.c
drivers/nvme/target/nvmet.h
include/linux/nvme.h