[PATCH v5 0/3] Fix virtio console port assignment issue

Aaron M. Brown posted 3 patches 3 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/20250606000924.75241-1-aaronmbr@linux.ibm.com
There is a newer version of this series
src/conf/domain_addr.c                        | 27 +++++---
...onsole-virtio-vioserial.x86_64-latest.args | 44 +++++++++++++
...console-virtio-vioserial.x86_64-latest.xml | 63 +++++++++++++++++++
.../console-virtio-vioserial.xml              | 48 ++++++++++++++
tests/qemuxmlconftest.c                       |  1 +
5 files changed, 173 insertions(+), 10 deletions(-)
create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.x86_64-latest.args
create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.x86_64-latest.xml
create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.xml
[PATCH v5 0/3] Fix virtio console port assignment issue
Posted by Aaron M. Brown 3 months ago
Changelog:
---
v5:
 - Added xml tests to tests/qemuxmlconfdata
 - Fixed virito -> virtio typo in commit message
---
v4:
 - Update commit messages
---
v3:
 - Added Reviewed-By
 - Included CI Results Link
---
v2:
 - Split patch into two commits
 - Added fixes tag
---

This libvirt patch series does the following:
1. fixes an issue with virtio console device port auto assignment on vioserial buses
2. updates console port reservation comment and changes the allowZero variable to allowPortZero for clarity
3. Adds tests for virtio console on the vioserial bus

Currently in libvirt, a virtio console device cannot be auto assigned a port number greater than zero on a vioserial bus. This leads to port collision errors when adding more than 1 virtio console device on a single vioserial bus.

After applying this patch, one can add multiple console ports under a single vioserial bus.

Here is a link to CI results for this series: https://gitlab.com/aaronbmalik/libvirt/-/pipelines/1855918840

Aaron M. Brown (3):
  qemuxmlconftest: Add console-virtio-vioserial tests
  virDomainVirtioSerialAddrAssign: Fix virtio console port auto
    assignment on vioserial bus
  domain_addr.c: update console port reservation comment and allowZero
    var to allowPortZero for clarity

 src/conf/domain_addr.c                        | 27 +++++---
 ...onsole-virtio-vioserial.x86_64-latest.args | 44 +++++++++++++
 ...console-virtio-vioserial.x86_64-latest.xml | 63 +++++++++++++++++++
 .../console-virtio-vioserial.xml              | 48 ++++++++++++++
 tests/qemuxmlconftest.c                       |  1 +
 5 files changed, 173 insertions(+), 10 deletions(-)
 create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.x86_64-latest.args
 create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.x86_64-latest.xml
 create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.xml

--
2.39.5 (Apple Git-154)
Re: [PATCH v5 0/3] Fix virtio console port assignment issue
Posted by Cam Miller 3 months ago
I see patch 3/3 as a reply in this email thread, but don't see 1 or 2. Is this problem only on my
end, or did you forgot to send some of the patches in this version?

On 6/5/25 20:09, Aaron M. Brown wrote:
> Changelog:
> ---
> v5:
>  - Added xml tests to tests/qemuxmlconfdata
>  - Fixed virito -> virtio typo in commit message
> ---
> v4:
>  - Update commit messages
> ---
> v3:
>  - Added Reviewed-By
>  - Included CI Results Link
> ---
> v2:
>  - Split patch into two commits
>  - Added fixes tag
> ---
> 
> This libvirt patch series does the following:
> 1. fixes an issue with virtio console device port auto assignment on vioserial buses
> 2. updates console port reservation comment and changes the allowZero variable to allowPortZero for clarity
> 3. Adds tests for virtio console on the vioserial bus
> 
> Currently in libvirt, a virtio console device cannot be auto assigned a port number greater than zero on a vioserial bus. This leads to port collision errors when adding more than 1 virtio console device on a single vioserial bus.
> 
> After applying this patch, one can add multiple console ports under a single vioserial bus.
> 
> Here is a link to CI results for this series: https://gitlab.com/aaronbmalik/libvirt/-/pipelines/1855918840
> 
> Aaron M. Brown (3):
>   qemuxmlconftest: Add console-virtio-vioserial tests
>   virDomainVirtioSerialAddrAssign: Fix virtio console port auto
>     assignment on vioserial bus
>   domain_addr.c: update console port reservation comment and allowZero
>     var to allowPortZero for clarity
> 
>  src/conf/domain_addr.c                        | 27 +++++---
>  ...onsole-virtio-vioserial.x86_64-latest.args | 44 +++++++++++++
>  ...console-virtio-vioserial.x86_64-latest.xml | 63 +++++++++++++++++++
>  .../console-virtio-vioserial.xml              | 48 ++++++++++++++
>  tests/qemuxmlconftest.c                       |  1 +
>  5 files changed, 173 insertions(+), 10 deletions(-)
>  create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.x86_64-latest.args
>  create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.x86_64-latest.xml
>  create mode 100644 tests/qemuxmlconfdata/console-virtio-vioserial.xml
> 
> --
> 2.39.5 (Apple Git-154)
Re: [PATCH v5 0/3] Fix virtio console port assignment issue
Posted by Peter Krempa via Devel 3 months ago
On Fri, Jun 06, 2025 at 08:57:31 -0400, Cam Miller wrote:
> I see patch 3/3 as a reply in this email thread, but don't see 1 or 2. Is this problem only on my
> end, or did you forgot to send some of the patches in this version?

I did receive them via email and they are present in archives:

Subject: [PATCH v5 1/3] qemuxmlconftest: Add console-virtio-vioserial tests
Message-Id: <20250606000924.75241-2-aaronmbr@linux.ibm.com>
Archived-At: <https://lists.libvirt.org/archives/list/devel@lists.libvirt.org/message/BA2V2GHJ3W5SMYDRM66VP7W5ASQBZIYA/>


Subject: [PATCH v5 2/3] virDomainVirtioSerialAddrAssign: Fix virtio console port auto assignment on vioserial bus
Message-Id: <20250606000924.75241-3-aaronmbr@linux.ibm.com>
Archived-At: <https://lists.libvirt.org/archives/list/devel@lists.libvirt.org/message/67UBPOQS7X4YO46DHTMSRCOU33NICM74/>