Hi,
you'd want to compare the lsmod and lspci output of the case that worked, you 
said "If I bring up the guest using a generic image (not the kvm specific 
kernal) the interface appears for SRIOV VF".
Now in this guest I'd expect the following section:

00:06.0 Ethernet controller: Intel Corporation Ethernet Virtual Function 700 
Series (rev 02)
        Subsystem: Intel Corporation Ethernet Virtual Function 700 Series
        Physical Slot: 6
        Flags: fast devsel
        Memory at fe000000 (64-bit, prefetchable) [size=64K]
        Memory at fe018000 (64-bit, prefetchable) [size=16K]
        Capabilities: [70] MSI-X: Enable- Count=5 Masked-
        Capabilities: [a0] Express Endpoint, MSI 00

To also have
        Kernel driver in use: ?????

Finding which driver exactly that is would be step one.
I think for the card that I see here that would be "i40evf", but please confirm 
that to be sure.


Now (still on the working environment) check where you have that module from
$ modinfo i40evf
filename:       
/lib/modules/5.4.0-42-generic/kernel/drivers/net/ethernet/intel/iavf/iavf.ko
...

$ dpkg -S 
/lib/modules/5.4.0-42-generic/kernel/drivers/net/ethernet/intel/iavf/iavf.ko
linux-modules-5.4.0-42-generic: 
/lib/modules/5.4.0-42-generic/kernel/drivers/net/ethernet/intel/iavf/iavf.ko

So in my case I have confirmed that I
a) have the module installed
b) which package it is from


Now switch to your bad environment.
Check modinfo there, does the module exist (I'd assume it isn't).
In that case is the "linux-modules-5.4.0-42-generic" (or whatever matches your 
case) package installed - if not why is that since the dependencies should have 
pulled it in?

I hope this already helps to resolve, looking forward to hear back from
you.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1892422

Title:
  Pci passthrough interface not showing up in Ubuntu 20.04 but does show
  in 18.04

Status in linux package in Ubuntu:
  Confirmed
Status in qemu package in Ubuntu:
  Confirmed

Bug description:
  
  After setting up pci pass through for a virtual function it did not show up 
as an interface in Ubuntu 20.04, it did however show up as a PCI device. 
  After reverting back to 18.04 with exactly the same configuration the 
interface showed up as expected.
  Bellow is the configuration and output for both 18.04 and 20.04.

  virt-install 
      --import 
      --connect qemu:///system --name emsk8sm1 --ram 8192 
      --disk pool/emsk8sm1/emsk8sm1.img,format=img,bus=virtio   
      --disk  cidata.img,device=cdrom,format=img  
      --vcpus 4 --cpu host --os-type linux --os-variant ubuntu18.04
      --network 
bridge=br0,model=virtio,virtualport_type=openvswitch,mac=52:54:00:8a:9c:ea
      --hostdev 3b:02.5
      --console pty,target_type=serial    
      --graphics type=vnc,listen=0.0.0.0     
      --noautoconsole
      --autostart -v
        

  Configuration of 18.04 where the passthrough works

  Version
  Linux emsk8sm1 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 
x86_64 x86_64 x86_64 GNU/Linux

  virsh dumpxml emsk8sm1
  <hostdev mode='subsystem' type='pci' managed='yes'>
    <driver name='vfio'/>
    <source>
        <address domain='0x0000' bus='0x3b' slot='0x02' function='0x5'/>
    </source>
    <alias name='hostdev0'/>
    <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
  </hostdev>
        
        
  lspci | grep Ethernet
  00:03.0 Ethernet controller: Red Hat, Inc. Virtio network device
  00:06.0 Ethernet controller: Intel Corporation Ethernet Virtual Function 700 
Series (rev 02)  <--- Pass through interface

  
  ip link show [interface shows inside of vm ens6]
  1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode 
DEFAULT group default qlen 1000
      link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
  2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP 
mode DEFAULT group default qlen 1000
      link/ether 52:54:00:8a:9c:ea brd ff:ff:ff:ff:ff:ff
  3: ens6: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode 
DEFAULT group default qlen 1000
      link/ether ea:99:ea:36:3e:63 brd ff:ff:ff:ff:ff:ff

        
  Configuration of 20.04 where the VF shows as a PCI device but does not show 
as an interface

  Version
  Linux emsk8sm1 5.4.0-1020-kvm #20-Ubuntu SMP Fri Jul 10 05:03:04 UTC 2020 
x86_64 x86_64 x86_64 GNU/Linux

  virsh dumpxml emsk8sm1
  <hostdev mode='subsystem' type='pci' managed='yes'>
    <driver name='vfio'/>
    <source>
        <address domain='0x0000' bus='0x3b' slot='0x02' function='0x5'/>
    </source>
    <alias name='hostdev0'/>
    <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
  </hostdev>

        
  lspci | grep Ethernet
  00:03.0 Ethernet controller: Red Hat, Inc. Virtio network device
  00:06.0 Ethernet controller: Intel Corporation Ethernet Virtual Function 700 
Series (rev 02)   <--- Pass through interface

  
  ip link show [ens 6 does not show as an interface} 
  1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode 
DEFAULT group default qlen 1000
      link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
  2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP 
mode DEFAULT group default qlen 1000
      link/ether 52:54:00:8a:9c:ea brd ff:ff:ff:ff:ff:ff
  3: tunl0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN mode DEFAULT group 
default qlen 1000
      link/ipip 0.0.0.0 brd 0.0.0.0
  4: sit0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN mode DEFAULT group 
default qlen 1000
      link/sit 0.0.0.0 brd 0.0.0.0

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1892422/+subscriptions

-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to