6651f8f2 | 11-Nov-2024 |
Klaus Jensen <k.jensen@samsung.com> |
hw/nvme: take a reference on the subsystem on vf realization
Make sure we grab a reference on the subsystem when a VF is realized. Otherwise, the subsytem will be unrealized automatically when the V
hw/nvme: take a reference on the subsystem on vf realization
Make sure we grab a reference on the subsystem when a VF is realized. Otherwise, the subsytem will be unrealized automatically when the VFs are unregistered and unreffed.
This fixes a latent bug but was not exposed until commit 08f632848008 ("pcie: Release references of virtual functions"). This was then fixed (or rather, hidden) by commit c613ad25125b ("pcie_sriov: Do not manually unrealize"), but that was then reverted (due to other issues) in commit b0fdaee5d1ed, exposing the bug yet again.
Cc: qemu-stable@nongnu.org Fixes: 08f632848008 ("pcie: Release references of virtual functions") Reviewed-by: Jesper Wendel Devantier <foss@defmacro.it> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
e8598778 | 11-Nov-2024 |
Klaus Jensen <k.jensen@samsung.com> |
hw/nvme: SR-IOV VFs must hardwire pci interrupt pin register to zero
The PCI Interrupt Pin Register does not apply to VFs and MUST be hardwired to zero.
Fixes: 44c2c09488db ("hw/nvme: Add support f
hw/nvme: SR-IOV VFs must hardwire pci interrupt pin register to zero
The PCI Interrupt Pin Register does not apply to VFs and MUST be hardwired to zero.
Fixes: 44c2c09488db ("hw/nvme: Add support for SR-IOV") Reviewed-by: Jesper Wendel Devantier <foss@defmacro.it> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
149f6e90 | 10-Nov-2024 |
Klaus Jensen <k.jensen@samsung.com> |
hw/nvme: fix use/unuse of msix vectors
Only call msix_{un,}use_vector() when interrupts are actually enabled for a completion queue.
Reviewed-by: Jesper Wendel Devantier <foss@defmacro.it> Signed-o
hw/nvme: fix use/unuse of msix vectors
Only call msix_{un,}use_vector() when interrupts are actually enabled for a completion queue.
Reviewed-by: Jesper Wendel Devantier <foss@defmacro.it> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
8f472a0e | 22-Oct-2024 |
Arun Kumar <arun.kka@samsung.com> |
hw/nvme: remove dead code
Remove dead code which always returns success, since PRCHK will have a value of zero.
Signed-off-by: Arun Kumar <arun.kka@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@
hw/nvme: remove dead code
Remove dead code which always returns success, since PRCHK will have a value of zero.
Signed-off-by: Arun Kumar <arun.kka@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Link: https://lore.kernel.org/r/20241022222105.3609223-1-arun.kka@samsung.com Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
dbaa2936 | 30-Sep-2024 |
Ayush Mishra <ayush.m55@samsung.com> |
hw/nvme: add NPDAL/NPDGL
Add the NPDGL and NPDAL fields to support large alignment and granularities.
Signed-off-by: Ayush Mishra <ayush.m55@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@samsung
hw/nvme: add NPDAL/NPDGL
Add the NPDGL and NPDAL fields to support large alignment and granularities.
Signed-off-by: Ayush Mishra <ayush.m55@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Link: https://lore.kernel.org/r/20241001012833.3551820-1-ayush.m55@samsung.com [k.jensen: renamed the enum values] Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
ebd1568f | 26-Sep-2024 |
Alan Adamson <alan.adamson@oracle.com> |
hw/nvme: add atomic write support
Adds support for the controller atomic parameters: AWUN and AWUPF. Atomic Compare and Write Unit (ACWU) is not currently supported.
Writes that adhere to the ACWU
hw/nvme: add atomic write support
Adds support for the controller atomic parameters: AWUN and AWUPF. Atomic Compare and Write Unit (ACWU) is not currently supported.
Writes that adhere to the ACWU and AWUPF parameters are guaranteed to be atomic.
New NVMe QEMU Parameters (See NVMe Specification for details): atomic.dn (default off) - Set the value of Disable Normal. atomic.awun=UINT16 (default: 0) atomic.awupf=UINT16 (default: 0)
By default (Disable Normal set to zero), the maximum atomic write size is set to the AWUN value. If Disable Normal is set, the maximum atomic write size is set to AWUPF.
Signed-off-by: Alan Adamson <alan.adamson@oracle.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
e4bcb586 | 24-Sep-2024 |
Klaus Jensen <k.jensen@samsung.com> |
hw/nvme: add knob for CTRATT.MEM
Add a boolean prop (ctratt.mem) for setting CTRATT.MEM and default it to unset (false) to keep existing behavior of the device intact.
Reviewed-by: Minwoo Im <minwo
hw/nvme: add knob for CTRATT.MEM
Add a boolean prop (ctratt.mem) for setting CTRATT.MEM and default it to unset (false) to keep existing behavior of the device intact.
Reviewed-by: Minwoo Im <minwoo.im@samsung.com> Reviewed-by: Arun Kumar <arun.kka@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
a1ab6788 | 16-Jul-2024 |
Arun Kumar <arun.kka@samsung.com> |
hw/nvme: support CTRATT.MEM
Indicate that 'MDTS and Size Limits Exclude Metadata (MEM)' in the Controller Attributes (CTRATT) I/O Command Set Independent Identify Controller Data Structure.
Signed-
hw/nvme: support CTRATT.MEM
Indicate that 'MDTS and Size Limits Exclude Metadata (MEM)' in the Controller Attributes (CTRATT) I/O Command Set Independent Identify Controller Data Structure.
Signed-off-by: Arun Kumar <arun.kka@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> [k.jensen: updated commit message] Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
16eb2ea8 | 05-Sep-2024 |
Arun Kumar <arun.kka@samsung.com> |
hw/nvme: clear masked events from the aer queue
Clear masked events from the aer queue when get log page is issued with RAE 0 without checking for the presence of outstanding aer requests.
Signed-o
hw/nvme: clear masked events from the aer queue
Clear masked events from the aer queue when get log page is issued with RAE 0 without checking for the presence of outstanding aer requests.
Signed-off-by: Arun Kumar <arun.kka@samsung.com> [k.jensen: remove unnecessary QTAILQ_EMPTY check] Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
4ea3de93 | 22-Jul-2024 |
Yao Xingtao <yaoxt.fnst@fujitsu.com> |
hw/nvme: remove useless type cast
The type of req->cmd is NvmeCmd, cast the pointer of this type to NvmeCmd* is useless.
Signed-off-by: Yao Xingtao <yaoxt.fnst@fujitsu.com> Reviewed-by: Klaus Jense
hw/nvme: remove useless type cast
The type of req->cmd is NvmeCmd, cast the pointer of this type to NvmeCmd* is useless.
Signed-off-by: Yao Xingtao <yaoxt.fnst@fujitsu.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
75209c07 | 02-Jul-2024 |
Ayush Mishra <ayush.m55@samsung.com> |
hw/nvme: actually implement abort
Abort was not implemented previously, but we can implement it for AERs and asynchrnously for I/O.
Signed-off-by: Ayush Mishra <ayush.m55@samsung.com> Reviewed-by:
hw/nvme: actually implement abort
Abort was not implemented previously, but we can implement it for AERs and asynchrnously for I/O.
Signed-off-by: Ayush Mishra <ayush.m55@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
d522aef8 | 01-Jul-2024 |
Arun Kumar <arun.kka@samsung.com> |
hw/nvme: add cross namespace copy support
Extend copy command to copy user data across different namespaces via support for specifying a namespace for each source range
Signed-off-by: Arun Kumar <a
hw/nvme: add cross namespace copy support
Extend copy command to copy user data across different namespaces via support for specifying a namespace for each source range
Signed-off-by: Arun Kumar <arun.kka@samsung.com> Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
15ef124c | 29-May-2024 |
Minwoo Im <minwoo.im@samsung.com> |
hw/nvme: Expand VI/VQ resource to uint32
VI and VQ resources cover queue resources in each VFs in SR-IOV. Current maximum I/O queue pair size is 0xffff, we can expand them to cover the full number o
hw/nvme: Expand VI/VQ resource to uint32
VI and VQ resources cover queue resources in each VFs in SR-IOV. Current maximum I/O queue pair size is 0xffff, we can expand them to cover the full number of I/O queue pairs.
This patch also fixed Identify Secondary Controller List overflow due to expand of number of secondary controllers.
Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Minwoo Im <minwoo.im@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
c6159d0e | 29-May-2024 |
Minwoo Im <minwoo.im@samsung.com> |
hw/nvme: Allocate sec-ctrl-list as a dynamic array
To prevent further bumping up the number of maximum VF te support, this patch allocates a dynamic array (NvmeCtrl *)->sec_ctrl_list based on number
hw/nvme: Allocate sec-ctrl-list as a dynamic array
To prevent further bumping up the number of maximum VF te support, this patch allocates a dynamic array (NvmeCtrl *)->sec_ctrl_list based on number of VF supported by sriov_max_vfs property.
Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Minwoo Im <minwoo.im@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|
1a494d11 | 29-May-2024 |
Minwoo Im <minwoo.im@samsung.com> |
hw/nvme: separate identify data for sec. ctrl list
Secondary controller list for virtualization has been managed by Identify Secondary Controller List data structure with NvmeSecCtrlList where up to
hw/nvme: separate identify data for sec. ctrl list
Secondary controller list for virtualization has been managed by Identify Secondary Controller List data structure with NvmeSecCtrlList where up to 127 secondary controller entries can be managed. The problem hasn't arisen so far because NVME_MAX_VFS has been 127.
This patch separated identify data itself from the actual secondary controller list managed by controller to support more than 127 secondary controllers with the following patch. This patch reused NvmeSecCtrlEntry structure to manage all the possible secondary controllers, and copy entries to identify data structure when the command comes in.
Reviewed-by: Klaus Jensen <k.jensen@samsung.com> Signed-off-by: Minwoo Im <minwoo.im@samsung.com> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
show more ...
|