Re: [PATCH v2 00/13] libmultipath: a generic multipath lib for block drivers
Mike Snitzer <[email protected]>
| Newsgroups | dev.linux.lists.dm-devel,org.infradead.lists.linux-nvme,org.kernel.vger.linux-kernel,org.kernel.vger.linux-scsi |
|---|---|
| Message-ID | <[email protected]> |
On Tue, Apr 28, 2026 at 11:10:52AM +0000, John Garry wrote: > libmultipath: a generic multipath lib for block drivers > > This series introduces libmultipath. It is essentially a refactoring of > NVME multipath support, so we can have a common library to also support > native SCSI multipath. > > Much of the code is taken directly from the NVMe multipath code. However, > NVMe specifics are removed. A template structure is provided so the driver > may provide callbacks for driver specifics, like ANA support for NVMe. > > Important new structures introduced include: > > - mpath_head > These contain much of the multipath-specific functionality from > nvme_ns_head, including a pointer to the gendisk structure and > a path SRCU-based array. > > - mpath_device > This is the per-path structure, and contains much the same > multipath-specific functionality in nvme_ns > > libmultipath provides functionality for path management, path selection, > data path, and failover handling. > > Since the NVMe driver has some code in the sysfs and ioctl handling > which iterate all multipath NSes, functions like mpath_call_for_device() > are added to do the same per-path iteration. To get upstream this library needs an in-tree consumer. So at the end of the series, it'd makes sense to include the NVMe and/or SCSI changes that uses it. Mike