linux/drivers/nvme/host
Roland Dreier 489beb91e6 nvme-fabrics: Convert nvmf_transports_mutex to an rwsem
The mutex protects against the list of transports changing while a
controller is being created, but using a plain old mutex means that it
also serializes controller creation.  This unnecessarily slows down
creating multiple controllers - for example for the RDMA transport,
creating a controller involves establishing one connection for every IO
queue, which involves even more network/software round trips, so the
delay can become significant.

The simplest way to fix this is to change the mutex to an rwsem and only
hold it for writing when the list is being mutated.  Since we can take
the rwsem for reading while creating a controller, we can create multiple
controllers in parallel.

Signed-off-by: Roland Dreier <roland@purestorage.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
2017-08-30 14:51:22 +02:00
..
core.c nvme: don't blindly overwrite identifiers on disk revalidate 2017-08-29 10:23:04 +02:00
fabrics.c nvme-fabrics: Convert nvmf_transports_mutex to an rwsem 2017-08-30 14:51:22 +02:00
fabrics.h nvme: read the subsystem NQN from Identify Controller 2017-06-28 08:14:13 -06:00
fc.c nvme-fc: Reattach to localports on re-registration 2017-08-28 23:00:40 +03:00
Kconfig nvme: Remove SCSI translations 2017-06-28 08:14:13 -06:00
lightnvm.c block: replace bi_bdev with a gendisk pointer and partitions index 2017-08-23 12:49:55 -06:00
Makefile nvme: Makefile: remove dead build rule 2017-06-29 09:43:23 -06:00
nvme.h nvme: remove unused struct nvme_ns fields 2017-08-29 10:22:26 +02:00
pci.c nvme: fix uninitialized prp2 value on small transfers 2017-08-28 23:00:44 +03:00
rdma.c nvme-rdma: Use unlikely macro in the fast path 2017-08-28 23:00:43 +03:00