]> www.infradead.org Git - users/hch/block.git/commit
nvme: move setting the write cache flags out of nvme_set_queue_limits
authorChristoph Hellwig <hch@lst.de>
Mon, 26 Feb 2024 17:54:39 +0000 (12:54 -0500)
committerChristoph Hellwig <hch@lst.de>
Thu, 29 Feb 2024 15:01:56 +0000 (07:01 -0800)
commit4e7a508532df906355dccaca4dfb265e0dcbfc1e
tree566689dc6b2b85354c77afc4f84789367f34a3db
parent70ef8a1b730da52b6ac9ed8b76153d518bc982e1
nvme: move setting the write cache flags out of nvme_set_queue_limits

nvme_set_queue_limits is used on the admin queue and all gendisks
including hidden ones that don't support block I/O.  The write cache
setting on the other hand only makes sense for block I/O.  Move the
blk_queue_write_cache call to nvme_update_ns_info_block instead.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Max Gurtovoy <mgurtovoy@nvidia.com>
drivers/nvme/host/core.c