fix iavf build failed

This commit is contained in:
haochenstar 2021-09-16 14:09:24 +08:00
parent d47cf99c90
commit 8f29896ccd
2 changed files with 70 additions and 1 deletions

View File

@ -0,0 +1,60 @@
From f3ccfda1931977b80267ba54070a1aeafa18f6ca Mon Sep 17 00:00:00 2001
From: Yufeng Mo <moyufeng@huawei.com>
Date: Fri, 20 Aug 2021 15:35:18 +0800
Subject: [PATCH] ethtool: extend coalesce setting uAPI with CQE mode
In order to support more coalesce parameters through netlink,
add two new parameter kernel_coal and extack for .set_coalesce
and .get_coalesce, then some extra info can return to user with
the netlink API.
Signed-off-by: Yufeng Mo <moyufeng@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
src/iavf_ethtool.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/src/iavf_ethtool.c b/src/iavf_ethtool.c
index 3f7d427..4b60027 100644
--- a/src/iavf_ethtool.c
+++ b/src/iavf_ethtool.c
@@ -753,6 +753,8 @@ static int __iavf_get_coalesce(struct net_device *netdev,
* iavf_get_coalesce - Get interrupt coalescing settings
* @netdev: network interface device structure
* @ec: ethtool coalesce structure
+ * @kernel_coal: ethtool CQE mode setting structure
+ * @extack: extack for reporting error messages
*
* Returns current coalescing settings. This is referred to elsewhere in the
* driver as Interrupt Throttle Rate, as this is how the hardware describes
@@ -760,7 +762,9 @@ static int __iavf_get_coalesce(struct net_device *netdev,
* only represents the settings of queue 0.
**/
static int iavf_get_coalesce(struct net_device *netdev,
- struct ethtool_coalesce *ec)
+ struct ethtool_coalesce *ec,
+ struct kernel_ethtool_coalesce *kernel_coal,
+ struct netlink_ext_ack *extack)
{
return __iavf_get_coalesce(netdev, ec, -1);
}
@@ -898,11 +902,15 @@ static int __iavf_set_coalesce(struct net_device *netdev,
* iavf_set_coalesce - Set interrupt coalescing settings
* @netdev: network interface device structure
* @ec: ethtool coalesce structure
+ * @kernel_coal: ethtool CQE mode setting structure
+ * @extack: extack for reporting error messages
*
* Change current coalescing settings for every queue.
**/
static int iavf_set_coalesce(struct net_device *netdev,
- struct ethtool_coalesce *ec)
+ struct ethtool_coalesce *ec,
+ struct kernel_ethtool_coalesce *kernel_coal,
+ struct netlink_ext_ack *extack)
{
return __iavf_set_coalesce(netdev, ec, -1);
}
--
2.30.0

View File

@ -9,7 +9,7 @@
Name: iavf
Summary: Intel(R) Ethernet Adaptive Virtual Function Driver
Version: 4.0.1
Release: 5
Release: 6
Vendor: Intel Corporation
License: GPL-2.0
URL: http://support.intel.com
@ -21,12 +21,15 @@ BuildRequires: kernel-devel hwdata uname-build-checks gcc
Patch0: fix-build-error-with-Linux-5.10.patch
Patch6000: backport-extend-coalesce-setting-uAPI-with-CQE-mode.patch
%description
This package contains the Intel(R) Ethernet Adaptive Virtual Function Driver.
%prep
%setup
%patch0 -p1
%patch6000 -p1
%build
make -C src clean
@ -385,6 +388,12 @@ else
fi
%changelog
* Thu Sep 16 2021 xihaochen<xihaochen@huawei.com> - 4.0.1-6
- Type:bugfix
- ID:NA
- SUG:NA
- DESC:fix iavf build failed
* Wed Jul 7 2021 gaihuiying <gaihuiying1@huawei.com> - 4.0.1-5
- Type:bugfix
- ID:NA