Public bug reported:

---Problem Description---
Using Ubuntu mainline kernel
if we try to enable SRIOV in Mellanox CX4 card it will fail. 

# uname -r
root@c158f2u09os:~# echo 7 > /sys/class/net/enP5p1s0f0/device/sriov_numvfs
-bash: echo: write error: Cannot allocate memory

logs show:
Sep 16 00:52:46 c158f2u09os kernel: [ 1419.778118] mlx5_core 0005:01:00.0: not 
enough MMIO resources for SR-IOV
Sep 16 00:52:46 c158f2u09os kernel: [ 1419.778238] mlx5_core 0005:01:00.0: 
enable sriov failed -12
Sep 16 00:52:46 c158f2u09os kernel: [ 1419.778604] mlx5_core 0005:01:00.0: 
mlx5_core_sriov_enable failed -12

---uname output---
---Additional Hardware Info---
To recreate this you need power system and a Mellanox card that can be used for 

Machine Type = P8 
---Steps to Reproduce---
 with a Mellanox card like CX4 with SRIOV enabled.
just do this echo to the PF interface in this case was enP5p1s0f0.
echo 1 > /sys/class/net/enP5p1s0f0/device

If I take kernel 4.8 and I revert the following patch I can get it to
work again:

 From 5958d19a143eb229e9ece20bd4c781ad41cb7d24 Mon Sep 17 00:00:00 2001
 From: Benjamin Herrenschmidt <>
 Date: Fri, 8 Jul 2016 15:55:43 +1000
 Subject: powerpc/pnv/pci: Fix incorrect PE reservation attempt on some 64-bit 

** Affects: linux (Ubuntu)
     Importance: Undecided
     Assignee: Taco Screen team (taco-screen-team)
         Status: New

** Tags: architecture-ppc64le bugnameltc-146447 severity-critical 

** Tags added: architecture-ppc64le bugnameltc-146447 severity-critical

** Changed in: ubuntu
     Assignee: (unassigned) => Taco Screen team (taco-screen-team)

** Package changed: ubuntu => linux (Ubuntu)

You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

  Ubuntu 16.10 KVM: kernel 4.8 can not enable SRIOV for power systems

To manage notifications about this bug go to:

ubuntu-bugs mailing list

Reply via email to