mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-12 13:55:32 +00:00
igb: warn if max_vfs limit is exceeded
Currently there's no warning printed when max_vfs > 7 is specified with igb and the maximum of 7 is silently enforced. This patch prints a warning and informs the user of the actions taken. Signed-off-by: Stefan Assmann <sassmann@redhat.com> Tested-by: Jeff Pieper <jeffrey.e.pieper@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
This commit is contained in:
parent
dc6ed1df5a
commit
9b082d734a
1 changed files with 6 additions and 1 deletions
|
@ -2291,7 +2291,12 @@ static int __devinit igb_sw_init(struct igb_adapter *adapter)
|
|||
switch (hw->mac.type) {
|
||||
case e1000_82576:
|
||||
case e1000_i350:
|
||||
adapter->vfs_allocated_count = (max_vfs > 7) ? 7 : max_vfs;
|
||||
if (max_vfs > 7) {
|
||||
dev_warn(&pdev->dev,
|
||||
"Maximum of 7 VFs per PF, using max\n");
|
||||
adapter->vfs_allocated_count = 7;
|
||||
} else
|
||||
adapter->vfs_allocated_count = max_vfs;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue