This bug has been migrated to another issue tracking site. It has been closed here and may no longer be being monitored.

If you would like to get updates for this issue, or to participate in it, you may do so at Red Hat Issue Tracker .
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1951489 - [RFE] Add support for new QEMU features: rss, hash report, ebpf
Summary: [RFE] Add support for new QEMU features: rss, hash report, ebpf
Keywords:
Status: CLOSED MIGRATED
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libvirt
Version: 9.0
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: beta
: ---
Assignee: Michal Privoznik
QA Contact: yalzhang@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-04-20 09:11 UTC by ybendito
Modified: 2023-09-22 17:32 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-09-22 17:32:41 UTC
Type: Story
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker   RHEL-7483 0 None Migrated None 2023-09-22 17:32:27 UTC

Description ybendito 2021-04-20 09:11:36 UTC
Description of problem:

These features are supported (the ebpf will be supported soon, the patches were accepted for QEMU 6.1), but can't be controlled from the libvirt profile.

For RSS and hash report this is simple - just support respective attributes and propagate them to the command line
For BPF this is more complicated: QEMU is not able to load the EBPF when runs under libvirt so the QEMU needs libvirt assistance for loading the EBPF and providing respective file descriptors to QEMU. To simplify the task probably we need to add QEMU command-line switch to just load the ebpf and return file descriptors (or create QEMU helper for the same)

Comment 2 Michal Privoznik 2021-08-26 14:30:16 UTC
There were some patches posted on the list:

https://listman.redhat.com/archives/libvir-list/2021-July/msg00836.html

Comment 3 yalzhang@redhat.com 2022-05-30 05:44:56 UTC
Hi Michal, do you think the steps are enough to test in on libvirt side? 
bug 1865786 comment 7 shows the method to verify the function. I will try it with windows guest. Linux guest do not support it yet now. 

Since 8.3.0 and QEMU 5.1 , rss and rss_hash_report are implemented in libvirt, refer to https://libvirt.org/formatdomain.html#setting-nic-driver-specific-options

# rpm -q libvirt qemu-kvm
libvirt-8.3.0-1.el9.x86_64
qemu-kvm-7.0.0-4.el9.x86_64

SC1: Start vm with the settings
1. Start vm with the settings:
# virsh dumpxml test | grep /interface -B8
    <interface type='bridge'>
      <mac address='52:54:00:fc:5e:27'/>
      <source bridge='br0'/>
      <target dev='vnet27'/>
      <model type='virtio'/>
      <driver queues='4' rss='on' rss_hash_report='on'/>
      <alias name='net0'/>
      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
    </interface>

# ps aux | grep rss
...
-netdev tap,fds=23:25:26:27,id=hostnet0,vhost=on,vhostfds=28:29:30:31 
-device {"driver":"virtio-net pci","mq":true,"vectors":10,"rss":true,"hash":true,"netdev":"hostnet0","id":"net0","mac":"52:54:00:fc:5e:27","bus":"pci.1","addr":"0x0"}

SC2: hotplug with the settings:
# cat interface.xml 
<interface type='network'>
  <source network='default'/>
  <model type='virtio'/>
   <driver queues='4' rss='on' rss_hash_report='on'/>
</interface>

# cat interface.xml 
<interface type='network'>
  <source network='default'/>
  <model type='virtio'/>
   <driver queues='4' rss='on' rss_hash_report='on'/>
</interface>

# virsh dumpxml test | grep /interface -B12
......
<interface type='network'>
      <mac address='52:54:00:b4:25:51'/>
      <source network='default' portid='beb6df7f-e605-4eea-8eec-ee27fa5ef159' bridge='virbr0'/>
      <target dev='vnet28'/>
      <model type='virtio'/>
      <driver queues='4' rss='on' rss_hash_report='on'/>
      <alias name='net1'/>
      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
    </interface>

SC3: Update-device, refer to bug 2082540

Comment 4 Michal Privoznik 2022-05-30 07:43:36 UTC
(In reply to yalzhang from comment #3)
> Hi Michal, do you think the steps are enough to test in on libvirt side? 

Looks good to me.

BTW: this was merged upstream as:

4e4def21d3 qemu_command: Generate cmd line for virtio-net.rss hash properties
7ab013655d qemu_capabilities: Add capability for virtio-net "rss" and "hash".
a8b1cbe77e domain_conf: Add configs for virtio net RSS and Hash report.

v8.3.0-rc1~160

and there's one follow up commit:

2df6849d78 qemu_hotplug: Deny changing @rss and @rss_hash_report attributes of virtio vNICs

v8.4.0-rc1~43

Comment 5 Yvugenfi@redhat.com 2022-05-30 12:05:57 UTC
(In reply to Michal Privoznik from comment #4)
> (In reply to yalzhang from comment #3)
> > Hi Michal, do you think the steps are enough to test in on libvirt side? 
> 
> Looks good to me.
> 
> BTW: this was merged upstream as:
> 
> 4e4def21d3 qemu_command: Generate cmd line for virtio-net.rss hash properties
> 7ab013655d qemu_capabilities: Add capability for virtio-net "rss" and "hash".
> a8b1cbe77e domain_conf: Add configs for virtio net RSS and Hash report.
> 
> v8.3.0-rc1~160
> 
> and there's one follow up commit:
> 
> 2df6849d78 qemu_hotplug: Deny changing @rss and @rss_hash_report attributes
> of virtio vNICs
> 
> v8.4.0-rc1~43

Hi Michal,

This is just a basic support. Still some work is going on upstream to enable the usage with libvirt when QEMU runs without root privileges by using ebpf helper.

Comment 6 yalzhang@redhat.com 2022-05-31 00:17:28 UTC
(In reply to Yvugenfi from comment #5)
> 
> Hi Michal,
> 
> This is just a basic support. Still some work is going on upstream to enable
> the usage with libvirt when QEMU runs without root privileges by using ebpf
> helper.

Hi Yan, downstream qemu do not enable the ebpf support, do we have the plan to enable it?

Comment 7 Michal Privoznik 2022-05-31 06:52:15 UTC
(In reply to Yvugenfi from comment #5)
> 

Alright then. Let me move this back to ASSIGNED so that the rest of the feature can be picked up by this bug later on.

Comment 8 Yvugenfi@redhat.com 2022-05-31 06:54:59 UTC
(In reply to yalzhang from comment #6)
> (In reply to Yvugenfi from comment #5)
> > 
> > Hi Michal,
> > 
> > This is just a basic support. Still some work is going on upstream to enable
> > the usage with libvirt when QEMU runs without root privileges by using ebpf
> > helper.
> 
> Hi Yan, downstream qemu do not enable the ebpf support, do we have the plan
> to enable it?

In general yes. But we need to have a helper support in libvirt for this.

Comment 12 RHEL Program Management 2023-09-22 17:31:05 UTC
Issue migration from Bugzilla to Jira is in process at this time. This will be the last message in Jira copied from the Bugzilla bug.

Comment 13 RHEL Program Management 2023-09-22 17:32:41 UTC
This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there.

Due to differences in account names between systems, some fields were not replicated.  Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "RHEL-" followed by an integer.  You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like:

"Bugzilla Bug" = 1234567

In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information.


Note You need to log in before you can comment on or make changes to this bug.