[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 21/24] nvme: support multiple namespaces
From: |
Michal Prívozník |
Subject: |
Re: [PATCH v4 21/24] nvme: support multiple namespaces |
Date: |
Thu, 19 Dec 2019 16:11:20 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.3.0 |
On 12/19/19 2:09 PM, Klaus Jensen wrote:
> This adds support for multiple namespaces by introducing a new 'nvme-ns'
> device model. The nvme device creates a bus named from the device name
> ('id'). The nvme-ns devices then connect to this and registers
> themselves with the nvme device.
>
> This changes how an nvme device is created. Example with two namespaces:
>
> -drive file=nvme0n1.img,if=none,id=disk1
> -drive file=nvme0n2.img,if=none,id=disk2
> -device nvme,serial=deadbeef,id=nvme0
> -device nvme-ns,drive=disk1,bus=nvme0,nsid=1
> -device nvme-ns,drive=disk2,bus=nvme0,nsid=2
>
> The drive property is kept on the nvme device to keep the change
> backward compatible, but the property is now optional. Specifying a
> drive for the nvme device will always create the namespace with nsid 1.
>
> Signed-off-by: Klaus Jensen <address@hidden>
> Signed-off-by: Klaus Jensen <address@hidden>
Klaus, just to make sure I understand correctly, this implements
multiple namespaces for *emulated* NVMe, right? I'm asking because I
just merged libvirt patches to support:
-drive
file.driver=nvme,file.device=0000:01:00.0,file.namespace=1,format=raw,if=none,id=drive-virtio-disk0
-device
virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1
and seeing these patches made me doubt my design. But if your patches
touch emulated NVMe only, then libvirt's fine because it doesn't expose
that just yet.
Michal
- [PATCH v4 14/24] nvme: make sure ncqr and nsqr is valid, (continued)
- Message not available
- Message not available
- Message not available
- Message not available
- Message not available
- Message not available
- Message not available
- Message not available
- Message not available
Message not available
- [PATCH v4 22/24] nvme: bump controller pci device id, Klaus Jensen, 2019/12/19
- Re: [PATCH v4 22/24] nvme: bump controller pci device id, Keith Busch, 2019/12/19
- Re: [PATCH v4 22/24] nvme: bump controller pci device id, Klaus Birkelund Jensen, 2019/12/19
- Re: [PATCH v4 22/24] nvme: bump controller pci device id, Keith Busch, 2019/12/19
- Re: [PATCH v4 22/24] nvme: bump controller pci device id, Klaus Birkelund Jensen, 2019/12/19