Re: [ PATCH vf-token 0/8] Introduce vf-token when using userspace PF

2024-01-08 Thread Vivek Kashyap
On Mon, 8 Jan 2024, Alex Williamson wrote: On Mon, 8 Jan 2024 23:32:04 +0530 (IST) Vivek Kashyap wrote: On Mon, 8 Jan 2024, Alex Williamson wrote: On Mon, 8 Jan 2024 18:42:19 +0530 (IST) Vivek Kashyap wrote: ... As I've stated above, for libvirt we should consider only passing i

Re: [ PATCH vf-token 0/8] Introduce vf-token when using userspace PF

2024-01-08 Thread Vivek Kashyap
On Mon, 8 Jan 2024, Alex Williamson wrote: On Mon, 8 Jan 2024 18:42:19 +0530 (IST) Vivek Kashyap wrote: ... As I've stated above, for libvirt we should consider only passing it via the 'secret' object. Sounds good. Will follow this up. Alex - will you be working on

Re: [ PATCH vf-token 0/8] Introduce vf-token when using userspace PF

2024-01-08 Thread Vivek Kashyap
... As I've stated above, for libvirt we should consider only passing it via the 'secret' object. Sounds good. Will follow this up. Alex - will you be working on the qemu update? Forgot to add: If you need a way to test it with a libvirt-started VM in the interim until the qemu commandline

Re: [ PATCH vf-token 0/8] Introduce vf-token when using userspace PF

2024-01-08 Thread Vivek Kashyap
If there is even a slight expectation of confidentiality (IMO just calling it a 'secret' in documentation is enough to justify that expectation) it should be treated as such. Thus qemu needs to add the possibility to pass it via the 'secret' object, so that libvirt can pass it encrypted. On the

Re: [ PATCH vf-token 0/8] Introduce vf-token when using userspace PF

2024-01-03 Thread Vivek Kashyap
On Tue, 2 Jan 2024, Alex Williamson wrote: On Tue, 2 Jan 2024 18:55:10 +0530 Vivek Kashyap wrote: The VFIO PCI ABI has been extended to require userspace PF driver to set a VF token to a known value. The VF drivers are then required to provide this token to access the VF device. The vf

[PATCH vf-token 8/8] NEWS: Update news about vf-token

2024-01-02 Thread Vivek Kashyap
Update news about vf-token Signed-off-by: Vivek Kashyap --- NEWS.rst | 8 1 file changed, 8 insertions(+) diff --git a/NEWS.rst b/NEWS.rst index dc40602c72..5e6a7c3147 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -17,6 +17,14 @@ v10.0.0 (unreleased) * **New features** + * qemu

[PATCH vf-token 7/8] test: add tests for the vf-token flag

2024-01-02 Thread Vivek Kashyap
Add tests for the vf-token flag to the qemuxml2argv and qemuxml2xml test suites Signed-off-by: Vivek Kashyap Signed-off-by: Ciara Loftus --- .../hostdev-vfio-vf-token.x86_64-latest.args | 34 .../hostdev-vfio-vf-token.xml | 22 ++ tests

[PATCH vf-token 6/8] docs: Update documentation and vf-token schema

2024-01-02 Thread Vivek Kashyap
Provide information about the vf-token flag Signed-off-by: Vivek Kashyap --- docs/formatdomain.rst | 3 +++ src/conf/schemas/basictypes.rng | 7 +++ 2 files changed, 10 insertions(+) diff --git a/docs/formatdomain.rst b/docs/formatdomain.rst index 310d2bc427..29a7b3145e 100644

[PATCH vf-token 4/8] conf: XML parsing and formatting of vf-token

2024-01-02 Thread Vivek Kashyap
This patch introduces new XML parser/formatter functions for parsing the vf-token Signed-off-by: Vivek Kashyap Signed-off-by: Ciara Loftus --- src/conf/device_conf.c | 49 ++-- src/conf/domain_conf.c | 8 +++ src/libvirt_private.syms | 1 + src

[PATCH vf-token 5/8] qemu: Introduce validation for vf-token

2024-01-02 Thread Vivek Kashyap
Introduce a validation function for vf-token support in qemu and generate vf-token device attribute in qemu command line Signed-off-by: Vivek Kashyap --- src/qemu/qemu_command.c | 8 src/qemu/qemu_validate.c | 20 2 files changed, 28 insertions(+) diff --git a

[PATCH vf-token 3/8] conf: Define PCI address vf-token extension

2024-01-02 Thread Vivek Kashyap
This patch introduces the PCI address extension flag for vf-token Signed-off-by: Vivek Kashyap --- src/conf/domain_addr.h | 1 + src/qemu/qemu_domain_address.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/src/conf/domain_addr.h b/src/conf/domain_addr.h index e72fb48847

[PATCH vf-token 2/8] qemu: capabilities: Introduce QEMU_CAPS_VFIO_VFTOKEN

2024-01-02 Thread Vivek Kashyap
Introduce the vf-token qemu capability Signed-off-by: Vivek Kashyap --- src/qemu/qemu_capabilities.c | 3 +++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_8.1.0_s390x.xml | 1 + tests/qemucapabilitiesdata/caps_8.1.0_x86_64.xml | 1

[ PATCH vf-token 0/8] Introduce vf-token when using userspace PF

2024-01-02 Thread Vivek Kashyap
ddr":"0x1"} Changes since initial RFC based on review comments received: 1. Added documentation 2. Added test cases and ran successful test suite after each patch commit 3. fixed spaces, coding sytle, and uuid string format 4. Used S:vftoken in virJSONValueObjectAdd instead of a condit

[PATCH vf-token 1/8] virpci: Define the vf-token extension for PCI device

2024-01-02 Thread Vivek Kashyap
Define the vf-token extension for PCI device Signed-off-by: Vivek Kashyap --- src/util/virpci.h | 8 1 file changed, 8 insertions(+) diff --git a/src/util/virpci.h b/src/util/virpci.h index bc7cb2329f..da32c2f4d2 100644 --- a/src/util/virpci.h +++ b/src/util/virpci.h @@ -50,6 +50,13

[vf-token 7/8] test: add tests for the vf-token flag

2023-12-18 Thread Vivek Kashyap
Add tests for the vf-token flag to the qemuxml2argv and qemuxml2xml test suites Signed-off-by: Vivek Kashyap Signed-off-by: Ciara Loftus --- .../hostdev-vfio-vf-token.x86_64-latest.args | 34 .../hostdev-vfio-vf-token.xml | 22 ++ tests

[vf-token 8/8] NEWS: Update news about vf-token

2023-12-18 Thread Vivek Kashyap
Update news about vf-token Signed-off-by: Vivek Kashyap --- NEWS.rst | 8 1 file changed, 8 insertions(+) diff --git a/NEWS.rst b/NEWS.rst index dc40602c72..5e6a7c3147 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -17,6 +17,14 @@ v10.0.0 (unreleased) * **New features** + * qemu

[vf-token 6/8] docs: Update documentation and vf-token schema

2023-12-18 Thread Vivek Kashyap
Provide information about the vf-token flag Signed-off-by: Vivek Kashyap --- docs/formatdomain.rst | 3 +++ src/conf/schemas/basictypes.rng | 7 +++ 2 files changed, 10 insertions(+) diff --git a/docs/formatdomain.rst b/docs/formatdomain.rst index 310d2bc427..29a7b3145e 100644

[vf-token 5/8] qemu: Introduce validation for vf-token

2023-12-18 Thread Vivek Kashyap
Introduce a validation function for vf-token support in qemu and generate vf-token device attribute in qemu command line Signed-off-by: Vivek Kashyap --- src/qemu/qemu_command.c | 8 src/qemu/qemu_validate.c | 20 2 files changed, 28 insertions(+) diff --git a

[vf-token 4/8] conf: XML parsing and formatting of vf-token

2023-12-18 Thread Vivek Kashyap
This patch introduces new XML parser/formatter functions for parsing the vf-token Signed-off-by: Vivek Kashyap Signed-off-by: Ciara Loftus --- src/conf/device_conf.c | 49 ++-- src/conf/domain_conf.c | 8 +++ src/libvirt_private.syms | 1 + src

[vf-token 3/8] conf: Define PCI address vf-token extension

2023-12-18 Thread Vivek Kashyap
This patch introduces the PCI address extension flag for vf-token Signed-off-by: Vivek Kashyap --- src/conf/domain_addr.h | 1 + src/qemu/qemu_domain_address.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/src/conf/domain_addr.h b/src/conf/domain_addr.h index e72fb48847

[vf-token 2/8] qemu: capabilities: Introduce QEMU_CAPS_VFIO_VFTOKEN

2023-12-18 Thread Vivek Kashyap
Introduce the vf-token qemu capability Signed-off-by: Vivek Kashyap --- src/qemu/qemu_capabilities.c | 3 +++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_8.1.0_s390x.xml | 1 + tests/qemucapabilitiesdata/caps_8.1.0_x86_64.xml | 1

[vf-token 0/8] Introduce vf-token when using userspace PF

2023-12-18 Thread Vivek Kashyap
dr":"0x1"} Changes since initial RFC: 1. Added documentation 2. Added test cases and ran successful test suite after each patch commit 3. fixed spaces, coding sytle, and uuid string format 4. Used S:vftoken in virJSONValueObjectAdd instead of a conditional Vivek Kashyap (8): Defin

[vf-token 1/8] virpci: Define the vf-token extension for PCI device

2023-12-18 Thread Vivek Kashyap
Define the vf-token extension for PCI device Signed-off-by: Vivek Kashyap --- src/util/virpci.h | 8 1 file changed, 8 insertions(+) diff --git a/src/util/virpci.h b/src/util/virpci.h index bc7cb2329f..da32c2f4d2 100644 --- a/src/util/virpci.h +++ b/src/util/virpci.h @@ -50,6 +50,13

[RFC v2: vf-token 5/7] conf: test cases

2023-11-29 Thread Vivek Kashyap
Add related test cases Signed-off-by: Vivek Kashyap Signed-off-by: Ciara Loftus --- .../qemucapabilitiesdata/caps_8.1.0_s390x.xml | 1 + .../caps_8.1.0_x86_64.xml | 1 + .../caps_8.2.0_x86_64.xml | 1 + .../hostdev-vfio-vf-token.x86_64-latest.args

[RFC v2: vf-token 7/7] doc: doc and news

2023-11-29 Thread Vivek Kashyap
Update documentation and information about vf-token Signed-off-by: Vivek Kashyap --- NEWS.rst | 8 docs/formatdomain.rst | 4 2 files changed, 12 insertions(+) diff --git a/NEWS.rst b/NEWS.rst index f12734c2a1..3fb0230e71 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -22,6

[RFC v2: vf-token 6/7] qemu: validate & generate command line

2023-11-29 Thread Vivek Kashyap
Introduce a validation function for vf-token support in qemu and generate vf-token device attribute in qemu command line Signed-off-by: Vivek Kashyap --- src/qemu/qemu_command.c | 13 + src/qemu/qemu_validate.c | 20 2 files changed, 33 insertions(+) diff

[RFC v2: vf-token 4/7] conf: vf-token parsing and formatting

2023-11-29 Thread Vivek Kashyap
XML parsing and formatting of vf-token attribute Signed-off-by: Vivek Kashyap --- src/conf/device_conf.c | 32 ++-- src/conf/device_conf.h | 3 +++ src/conf/domain_conf.c | 8 src/conf/schemas/basictypes.rng | 7 +++ src

[RFC v2: vf-token 2/7] qemu: vf-token capability

2023-11-29 Thread Vivek Kashyap
Introduce qemu capability for vf-token Signed-off-by: Vivek Kashyap --- src/qemu/qemu_capabilities.c | 3 +++ src/qemu/qemu_capabilities.h | 1 + 2 files changed, 4 insertions(+) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 83119e871a..f4cacd48d0 100644 --- a

[RFC v2: vf-token 3/7] conf: vf-token flag

2023-11-29 Thread Vivek Kashyap
Define PCI address extension flag for vf-token Signed-off-by: Vivek Kashyap --- src/conf/domain_addr.h | 1 + src/qemu/qemu_domain_address.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/src/conf/domain_addr.h b/src/conf/domain_addr.h index e72fb48847..29e7257177 100644 --- a

[RFC v2: vf-token 0/7] Introduce vf-token when using userspace PF

2023-11-29 Thread Vivek Kashyap
d test cases and ran test suite - virtsocketest fails when run with 'ninja test' 3. fixed spaces and uuid string format 4. Used S:vftoken in virJSONValueObjectAdd instead of introducing a conditional Vivek Kashyap (7): virpci: Define vf-token qemu: vf-token capability conf

[RFC v2: vf-token 1/7] virpci: Define vf-token

2023-11-29 Thread Vivek Kashyap
Define the vf-token extension for PCI device Signed-off-by: Vivek Kashyap --- src/util/virpci.h | 9 + 1 file changed, 9 insertions(+) diff --git a/src/util/virpci.h b/src/util/virpci.h index faca6cf6f9..f080fceb97 100644 --- a/src/util/virpci.h +++ b/src/util/virpci.h @@ -50,7 +50,15