kernel-modules: upgrade ice,i40e,iavf drivers to the bundle 29.1
This upgrades the intel driver versions to the ones listed in Intel driver bundle 29.1. The list can be found here: https://cdrdv2.intel.com/v1/dl/getContent/822537?fileName=Intel +Ethernet+Controller+Products_Release+Notes_29.1.pdf The new versions are: ice-1.14.9.2 (Add automatic VF reset on Tx MDD events, please refer to https://github.com/intel/ethernet-linux-ice/releases) i40e-2.25.7 iavf-4.11.1 Verification: - installs from iso succeed on servers with ice(Intel Ethernet Controller E810-XXVDA4T Westport Channel) and i40e hw(Intel Ethernet Controller X710) for rt and std. - interfaces are up and pass packets for rt and std. - create vfs, ensure that they are picked up by the new iavf driver and that the interface can come up and pass packets on rt and std system. - Check dmesg to see DDP package is loaded successfully and the version is 1.3.36.0 for rt and std. Story: 2011056 Task: 50798 Change-Id: I3acf66e6404c993f4ae56fd45916f24e0b7ec400 Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
This commit is contained in:
parent
2e912eed62
commit
e1164656fb
@ -1,3 +1,9 @@
|
||||
i40e (2.25.7-1) unstable; urgency=medium
|
||||
|
||||
* Update the version to 2.25.7.
|
||||
|
||||
-- Jiping Ma <jiping.ma2@windriver.com> Mon, 11 Jun 2024 15:39:53 +0800
|
||||
|
||||
i40e (2.20.12-1) unstable; urgency=medium
|
||||
|
||||
* Update iavf driver to 4.5.3, and that dictates the upgrade of the i40e
|
||||
|
@ -0,0 +1,30 @@
|
||||
From d7641a342e22d9992ec56242e9e34106923964dc Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Tue, 11 Jun 2024 06:49:13 +0000
|
||||
Subject: [PATCH] i40e: pass linux common header
|
||||
|
||||
For debian, there are two header pkgs, e.g. linux-headers-6.6.0-1-amd64
|
||||
and linux-headers-6.6.0-1-common. So pass linux-headers-6.6.0-1-common
|
||||
to meet the requirement.
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/common.mk | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/common.mk b/src/common.mk
|
||||
index 52cee1a..8c1f2ad 100644
|
||||
--- a/src/common.mk
|
||||
+++ b/src/common.mk
|
||||
@@ -344,7 +344,7 @@ minimum_kver_check = $(eval $(call _minimum_kver_check,${1},${2},${3}))
|
||||
# generated also via $(shell) call, which makes error handling ugly
|
||||
$(if $(shell \
|
||||
$(if $(findstring 1,${V}),,QUIET_COMPAT=1) \
|
||||
- KSRC=${KSRC} OUT=${src}/kcompat_generated_defs.h CONFFILE=${CONFIG_FILE} \
|
||||
+ KSRC=${KSRC_COMMON} OUT=${src}/kcompat_generated_defs.h CONFFILE=${CONFIG_FILE} \
|
||||
bash ${src}/kcompat-generator.sh && echo ok), , $(error kcompat-generator.sh failed))
|
||||
|
||||
KCOMPAT_DEFINITIONS := $(shell ${CC} ${EXTRA_CFLAGS} -E -dM \
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,61 +0,0 @@
|
||||
From 209dceb1559491b4415645df53fa3949f1e3a6db Mon Sep 17 00:00:00 2001
|
||||
From: "M. Vefa Bicakci" <vefa.bicakci@windriver.com>
|
||||
Date: Fri, 14 Jan 2022 17:25:25 -0500
|
||||
Subject: [PATCH 03/10] i40e_main: Use irq_update_affinity_hint
|
||||
|
||||
This commit makes i40e_main use irq_update_affinity_hint instead of
|
||||
irq_set_affinity_hint to set the CPU affinity hints. This is done
|
||||
because the latter function sets the IRQ CPU affinities, whereas the
|
||||
former does not, and this allows the use of the default IRQ affinity CPU
|
||||
mask provided via the irqaffinity= kernel command line option.
|
||||
|
||||
This commit essentially replicates the i40e patch in the following
|
||||
patch series:
|
||||
https://lore.kernel.org/netdev/20210903152430.244937-1-nitesh@redhat.com/t/#u
|
||||
|
||||
The i40e patch has been mainlined as of this writing:
|
||||
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d34c54d1739c2cdf2e4437b74e6da269147f4987
|
||||
|
||||
Signed-off-by: M. Vefa Bicakci <vefa.bicakci@windriver.com>
|
||||
---
|
||||
src/i40e_main.c | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/i40e_main.c b/src/i40e_main.c
|
||||
index 88050c6..1319cfa 100644
|
||||
--- a/src/i40e_main.c
|
||||
+++ b/src/i40e_main.c
|
||||
@@ -5034,10 +5034,10 @@ int i40e_vsi_request_irq_msix(struct i40e_vsi *vsi, char *basename)
|
||||
*
|
||||
* get_cpu_mask returns a static constant mask with
|
||||
* a permanent lifetime so it's ok to pass to
|
||||
- * irq_set_affinity_hint without making a copy.
|
||||
+ * irq_update_affinity_hint without making a copy.
|
||||
*/
|
||||
cpu = cpumask_local_spread(q_vector->v_idx, -1);
|
||||
- irq_set_affinity_hint(irq_num, get_cpu_mask(cpu));
|
||||
+ irq_update_affinity_hint(irq_num, get_cpu_mask(cpu));
|
||||
#endif /* HAVE_IRQ_AFFINITY_HINT */
|
||||
}
|
||||
|
||||
@@ -5052,7 +5052,7 @@ free_queue_irqs:
|
||||
irq_set_affinity_notifier(irq_num, NULL);
|
||||
#endif
|
||||
#ifdef HAVE_IRQ_AFFINITY_HINT
|
||||
- irq_set_affinity_hint(irq_num, NULL);
|
||||
+ irq_update_affinity_hint(irq_num, NULL);
|
||||
#endif
|
||||
free_irq(irq_num, &vsi->q_vectors[vector]);
|
||||
}
|
||||
@@ -5868,7 +5868,7 @@ static void i40e_vsi_free_irq(struct i40e_vsi *vsi)
|
||||
#endif
|
||||
#ifdef HAVE_IRQ_AFFINITY_HINT
|
||||
/* remove our suggested affinity mask for this IRQ */
|
||||
- irq_set_affinity_hint(irq_num, NULL);
|
||||
+ irq_update_affinity_hint(irq_num, NULL);
|
||||
#endif
|
||||
synchronize_irq(irq_num);
|
||||
free_irq(irq_num, vsi->q_vectors[i]);
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,34 +0,0 @@
|
||||
From 6f42a57b9e4dd9bfacc88422247d774a17e78ff0 Mon Sep 17 00:00:00 2001
|
||||
From: Peng Zhang <Peng.Zhang2@windriver.com>
|
||||
Date: Thu, 21 Sep 2023 04:14:55 +0800
|
||||
Subject: [PATCH 04/10] I40E: Add the condition of 'undef NEED_ETH_HW_ADDR_SET'
|
||||
to
|
||||
|
||||
avoid redefinition conflict
|
||||
|
||||
For function eth_hw_addr_set has already been defined in
|
||||
linux-headers-5.10.0-6-common, add the condition of
|
||||
'undef NEED_ETH_HW_ADDR_SET' to avoid redefinition conflict.
|
||||
|
||||
Signed-off-by: Peng Zhang <Peng.Zhang2@windriver.com>
|
||||
---
|
||||
src/kcompat_std_defs.h | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat_std_defs.h b/src/kcompat_std_defs.h
|
||||
index 1d8d2c7..b7534fb 100644
|
||||
--- a/src/kcompat_std_defs.h
|
||||
+++ b/src/kcompat_std_defs.h
|
||||
@@ -252,6 +252,9 @@
|
||||
#define NEED_DEVLINK_ALLOC_SETS_DEV
|
||||
#define HAVE_DEVLINK_REGISTER_SETS_DEV
|
||||
#define NEED_ETH_HW_ADDR_SET
|
||||
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(5,11,0) && LINUX_VERSION_CODE >= KERNEL_VERSION(5,10,188))
|
||||
+#undef NEED_ETH_HW_ADDR_SET
|
||||
+#endif
|
||||
#else /* >= 5.15.0 */
|
||||
#define HAVE_ETHTOOL_COALESCE_EXTACK
|
||||
#define HAVE_NDO_ETH_IOCTL
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,57 +0,0 @@
|
||||
From 68153951d8e0c330394caf7db1cd5c9d0bf730b6 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 19:56:45 -0700
|
||||
Subject: [PATCH 05/10] i40e: Accommodate removal of u64_stats_fetch_*_irq()
|
||||
|
||||
This commit accommodates commit dec5efcffad4 ("u64_stat: Remove
|
||||
the obsolete fetch_irq() variants.") merged in the v6.3 development
|
||||
cycle, which causes the compilation errors listed below with the
|
||||
new v6.6 kernel.
|
||||
|
||||
Our changes are inspired from the ones in commit 068c38ad88cc ("net:
|
||||
Remove the obsolte u64_stats_fetch_*_irq() users (drivers)."), which
|
||||
removes the use of the API functions in question from the i40e
|
||||
driver. We use C macros to alias the older API function names to the
|
||||
currently available API function names.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=dec5efcffad4
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=068c38ad88cc
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/i40e_main.c:493:11: error: implicit declaration of function \
|
||||
u64_stats_fetch_begin_irq; did you mean u64_stats_fetch_begin? \
|
||||
[-Werror=implicit-function-declaration]
|
||||
493 | start = u64_stats_fetch_begin_irq(&ring->syncp);
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
| u64_stats_fetch_begin
|
||||
src/i40e_main.c:496:11: error: implicit declaration of function \
|
||||
u64_stats_fetch_retry_irq; did you mean u64_stats_fetch_retry? \
|
||||
[-Werror=implicit-function-declaration]
|
||||
496 | } while (u64_stats_fetch_retry_irq(&ring->syncp, start));
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/kcompat.h | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat.h b/src/kcompat.h
|
||||
index 6a81d1c..c63901b 100644
|
||||
--- a/src/kcompat.h
|
||||
+++ b/src/kcompat.h
|
||||
@@ -5278,6 +5278,11 @@ static inline __u32 skb_get_hash_raw(const struct sk_buff *skb)
|
||||
#endif /* 3.14.0 */
|
||||
|
||||
/*****************************************************************************/
|
||||
+#if ( LINUX_VERSION_CODE > KERNEL_VERSION(6,6,0) )
|
||||
+#define u64_stats_fetch_begin_irq u64_stats_fetch_begin
|
||||
+#define u64_stats_fetch_retry_irq u64_stats_fetch_retry
|
||||
+#endif
|
||||
+
|
||||
#if ( LINUX_VERSION_CODE < KERNEL_VERSION(3,15,0) )
|
||||
#if ( LINUX_VERSION_CODE < KERNEL_VERSION(2,6,35) )
|
||||
#define HAVE_SKBUFF_RXHASH
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,49 +0,0 @@
|
||||
From fc3d1b2f61a4cba66ba8f952ad332b83e9baf308 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 20:32:57 -0700
|
||||
Subject: [PATCH 06/10] i40e: drop the weight argument from netif_napi_add
|
||||
|
||||
This patch accommodates commit b48b89f9c189 ("net: drop the weight argument
|
||||
from netif_napi_add") merged in the v6.1 development cycle, by applying a
|
||||
similar change to the out-of-tree i40e driver to resolve the compilation
|
||||
errors encountered with the v6.6 kernel, which are listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=b48b89f9c189
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/i40e_main.c:12759:3: error: too many arguments to function netif_napi_add
|
||||
12759 | netif_napi_add(vsi->netdev, &q_vector->napi,
|
||||
| ^~~~~~~~~~~~~~
|
||||
In file included from /usr/src/linux-headers-6.6.0-1-common/include/net/sock.h:46,
|
||||
from /usr/src/linux-headers-6.6.0-1-common/include/linux/tcp.h:19,
|
||||
from /usr/src/linux-headers-6.6.0-1-common/include/net/tcp.h:20,
|
||||
from /<<PKGBUILDDIR>>/src/i40e.h:7,
|
||||
from /<<PKGBUILDDIR>>/src/i40e_main.c:8:
|
||||
/usr/src/linux-headers-6.6.0-1-common/include/linux/netdevice.h:2642:1: note: \
|
||||
declared here
|
||||
2642 | netif_napi_add(struct net_device *dev, struct napi_struct *napi,
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/i40e_main.c | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/i40e_main.c b/src/i40e_main.c
|
||||
index 1319cfa..4c64e3e 100644
|
||||
--- a/src/i40e_main.c
|
||||
+++ b/src/i40e_main.c
|
||||
@@ -12756,8 +12756,7 @@ static int i40e_vsi_alloc_q_vector(struct i40e_vsi *vsi, int v_idx)
|
||||
cpumask_copy(&q_vector->affinity_mask, cpu_possible_mask);
|
||||
#endif
|
||||
if (vsi->netdev)
|
||||
- netif_napi_add(vsi->netdev, &q_vector->napi,
|
||||
- i40e_napi_poll, NAPI_POLL_WEIGHT);
|
||||
+ netif_napi_add(vsi->netdev, &q_vector->napi, i40e_napi_poll);
|
||||
|
||||
/* tie q_vector and vsi together */
|
||||
vsi->q_vectors[v_idx] = q_vector;
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,58 +0,0 @@
|
||||
From ac442ea3a8642c9d0f557ac996b252a48c93248b Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 20:36:25 -0700
|
||||
Subject: [PATCH 07/10] i40e: Remove use of pci_enable_pcie_error_reporting()
|
||||
|
||||
This commit accommodates commit 7ec4b34be423 ("PCI/AER: Unexport
|
||||
pci_enable_pcie_error_reporting()") merged in the v6.6 development cycle,
|
||||
by applying changes similar to the ones found in commit d04d9e769993
|
||||
("i40e: Remove redundant pci_enable_pcie_error_reporting()") to resolve the
|
||||
i40e driver compilation failures encountered with the v6.6 kernel, which are
|
||||
listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=d04d9e769993
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/i40e_main.c:17154:2: error: implicit declaration of function \
|
||||
pci_enable_pcie_error_reporting [-Werror=implicit-function-declaration]
|
||||
17154 | pci_enable_pcie_error_reporting(pdev);
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/i40e_main.c | 3 ---
|
||||
1 file changed, 3 deletions(-)
|
||||
|
||||
diff --git a/src/i40e_main.c b/src/i40e_main.c
|
||||
index 4c64e3e..7c86b01 100644
|
||||
--- a/src/i40e_main.c
|
||||
+++ b/src/i40e_main.c
|
||||
@@ -17150,7 +17150,6 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
||||
goto err_pci_reg;
|
||||
}
|
||||
|
||||
- pci_enable_pcie_error_reporting(pdev);
|
||||
pci_set_master(pdev);
|
||||
|
||||
/* Now that we have a PCI connection, we need to do the
|
||||
@@ -17768,7 +17767,6 @@ err_pf_reset:
|
||||
err_ioremap:
|
||||
kfree(pf);
|
||||
err_pf_alloc:
|
||||
- pci_disable_pcie_error_reporting(pdev);
|
||||
pci_release_mem_regions(pdev);
|
||||
err_pci_reg:
|
||||
err_dma:
|
||||
@@ -17934,7 +17932,6 @@ debug_mode_clear:
|
||||
kfree(pf);
|
||||
pci_release_mem_regions(pdev);
|
||||
|
||||
- pci_disable_pcie_error_reporting(pdev);
|
||||
pci_disable_device(pdev);
|
||||
}
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,43 +0,0 @@
|
||||
From eacc41c1ca0c36218698058b3f8954549952efee Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 22:44:57 -0700
|
||||
Subject: [PATCH 08/10] i40e: Include xdp.h where required
|
||||
|
||||
This commit accommodates commit 680ee0456a57 ("net: invert the netdevice.h
|
||||
vs xdp.h dependency") which removes the "#include <xdp.h>" C preprocessor
|
||||
directive from header file "netdevice.h". This commit was merged in the
|
||||
v6.6 development cycle and causes compilation failures with the v6.6 kernel,
|
||||
which are listed below.
|
||||
|
||||
We accommodate this commit by including the "xdp.h" header file as needed
|
||||
from "i40e_txrx.h".
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=680ee0456a57
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/i40e_txrx.h:467:22: error: field xdp_rxq has incomplete type
|
||||
467 | struct xdp_rxq_info xdp_rxq;
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/i40e_txrx.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/src/i40e_txrx.h b/src/i40e_txrx.h
|
||||
index f14c1ba..344de09 100644
|
||||
--- a/src/i40e_txrx.h
|
||||
+++ b/src/i40e_txrx.h
|
||||
@@ -4,6 +4,8 @@
|
||||
#ifndef _I40E_TXRX_H_
|
||||
#define _I40E_TXRX_H_
|
||||
|
||||
+#include <net/xdp.h>
|
||||
+
|
||||
/* Interrupt Throttling and Rate Limiting Goodies */
|
||||
#define I40E_DEFAULT_IRQ_WORK 256
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,76 +0,0 @@
|
||||
From d09b310a8d2a1726559fe6465433bb53f6d8606f Mon Sep 17 00:00:00 2001
|
||||
From: Jacob Keller <jacob.e.keller@intel.com>
|
||||
Date: Thu, 21 Jul 2022 14:29:58 -0700
|
||||
Subject: [PATCH 09/10] i40e: use mul_u64_u64_div_u64 for PTP frequency
|
||||
calculation
|
||||
|
||||
The i40e device has a different clock rate depending on the current link
|
||||
speed. This requires using a different increment rate for the PTP clock
|
||||
registers. For slower link speeds, the base increment value is larger.
|
||||
Directly multiplying the larger increment value by the parts per billion
|
||||
adjustment might overflow.
|
||||
|
||||
To avoid this, the i40e implementation defaults to using the lower
|
||||
increment value and then multiplying the adjustment afterwards. This causes
|
||||
a loss of precision for lower link speeds.
|
||||
|
||||
We can fix this by using mul_u64_u64_div_u64 instead of performing the
|
||||
multiplications using standard C operations. On X86, this will use special
|
||||
instructions that perform the multiplication and division with 128bit
|
||||
intermediate values. For other architectures, the fallback implementation
|
||||
will limit the loss of precision for large values. Small adjustments don't
|
||||
overflow anyways and won't lose precision at all.
|
||||
|
||||
This allows first multiplying the base increment value and then performing
|
||||
the adjustment calculation, since we no longer fear overflowing. It also
|
||||
makes it easier to convert to the even more precise .adjfine implementation
|
||||
in a following change.
|
||||
|
||||
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
|
||||
Tested-by: Gurucharan <gurucharanx.g@intel.com> (A Contingent worker at Intel)
|
||||
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
|
||||
(cherry picked from commit 3626a690b717c18a969274e1fe000f8885d5afad)
|
||||
[jma: This commit was cherry-picked from
|
||||
https://git.yoctoproject.org/linux-yocto/commit/?h=3626a690b ]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/i40e_ptp.c | 17 ++++-------------
|
||||
1 file changed, 4 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/src/i40e_ptp.c b/src/i40e_ptp.c
|
||||
index a94b774..956b0eb 100644
|
||||
--- a/src/i40e_ptp.c
|
||||
+++ b/src/i40e_ptp.c
|
||||
@@ -368,25 +368,16 @@ static int i40e_ptp_adjfreq(struct ptp_clock_info *ptp, s32 ppb)
|
||||
ppb = -ppb;
|
||||
}
|
||||
|
||||
- freq = I40E_PTP_40GB_INCVAL;
|
||||
- freq *= ppb;
|
||||
- diff = div_u64(freq, 1000000000ULL);
|
||||
+ smp_mb(); /* Force any pending update before accessing. */
|
||||
+ freq = I40E_PTP_40GB_INCVAL * READ_ONCE(pf->ptp_adj_mult);
|
||||
+ diff = mul_u64_u64_div_u64(freq, (u64)ppb,
|
||||
+ 1000000000ULL);
|
||||
|
||||
if (neg_adj)
|
||||
adj = I40E_PTP_40GB_INCVAL - diff;
|
||||
else
|
||||
adj = I40E_PTP_40GB_INCVAL + diff;
|
||||
|
||||
- /* At some link speeds, the base incval is so large that directly
|
||||
- * multiplying by ppb would result in arithmetic overflow even when
|
||||
- * using a u64. Avoid this by instead calculating the new incval
|
||||
- * always in terms of the 40GbE clock rate and then multiplying by the
|
||||
- * link speed factor afterwards. This does result in slightly lower
|
||||
- * precision at lower link speeds, but it is fairly minor.
|
||||
- */
|
||||
- smp_mb(); /* Force any pending update before accessing. */
|
||||
- adj *= READ_ONCE(pf->ptp_adj_mult);
|
||||
-
|
||||
wr32(hw, I40E_PRTTSYN_INC_L, (u32)adj);
|
||||
wr32(hw, I40E_PRTTSYN_INC_H, (u32)(adj >> 32));
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,86 +0,0 @@
|
||||
From 262c2d5e13edac5b7da4518e72a7696f28331465 Mon Sep 17 00:00:00 2001
|
||||
From: Jacob Keller <jacob.e.keller@intel.com>
|
||||
Date: Thu, 21 Jul 2022 14:29:59 -0700
|
||||
Subject: [PATCH 10/10] i40e: convert .adjfreq to .adjfine
|
||||
|
||||
The i40e driver currently implements the .adjfreq handler for frequency
|
||||
adjustments. This takes the adjustment parameter in parts per billion. The
|
||||
PTP core supports .adjfine which provides an adjustment in scaled parts per
|
||||
million. This has a higher resolution and can result in more precise
|
||||
adjustments for small corrections.
|
||||
|
||||
Convert the existing .adjfreq implementation to the newer .adjfine
|
||||
implementation. This is trivial since it just requires changing the divisor
|
||||
from 1000000000ULL to (1000000ULL << 16) in the mul_u64_u64_div_u64 call.
|
||||
|
||||
This improves the precision of the adjustments and gets us one driver
|
||||
closer to removing the old .adjfreq support from the kernel.
|
||||
|
||||
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
|
||||
Tested-by: Gurucharan <gurucharanx.g@intel.com> (A Contingent worker at Intel)
|
||||
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
|
||||
(cherry picked from commit ccd3bf98592117f59be2daa0f2ca00f352d7abbc)
|
||||
[jma: This commit was cherry-picked from
|
||||
https://git.yoctoproject.org/linux-yocto/commit/?h=ccd3bf985 ]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/i40e_ptp.c | 22 ++++++++++++----------
|
||||
1 file changed, 12 insertions(+), 10 deletions(-)
|
||||
|
||||
diff --git a/src/i40e_ptp.c b/src/i40e_ptp.c
|
||||
index 956b0eb..92af9f7 100644
|
||||
--- a/src/i40e_ptp.c
|
||||
+++ b/src/i40e_ptp.c
|
||||
@@ -349,29 +349,31 @@ static void i40e_ptp_convert_to_hwtstamp(struct skb_shared_hwtstamps *hwtstamps,
|
||||
}
|
||||
|
||||
/**
|
||||
- * i40e_ptp_adjfreq - Adjust the PHC frequency
|
||||
+ * i40e_ptp_adjfine - Adjust the PHC frequency
|
||||
* @ptp: The PTP clock structure
|
||||
- * @ppb: Parts per billion adjustment from the base
|
||||
+ * @scaled_ppm: Scaled parts per million adjustment from base
|
||||
*
|
||||
- * Adjust the frequency of the PHC by the indicated parts per billion from the
|
||||
- * base frequency.
|
||||
+ * Adjust the frequency of the PHC by the indicated delta from the base
|
||||
+ * frequency.
|
||||
+ *
|
||||
+ * Scaled parts per million is ppm with a 16 bit binary fractional field.
|
||||
**/
|
||||
-static int i40e_ptp_adjfreq(struct ptp_clock_info *ptp, s32 ppb)
|
||||
+static int i40e_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm)
|
||||
{
|
||||
struct i40e_pf *pf = container_of(ptp, struct i40e_pf, ptp_caps);
|
||||
struct i40e_hw *hw = &pf->hw;
|
||||
u64 adj, freq, diff;
|
||||
int neg_adj = 0;
|
||||
|
||||
- if (ppb < 0) {
|
||||
+ if (scaled_ppm < 0) {
|
||||
neg_adj = 1;
|
||||
- ppb = -ppb;
|
||||
+ scaled_ppm = -scaled_ppm;
|
||||
}
|
||||
|
||||
smp_mb(); /* Force any pending update before accessing. */
|
||||
freq = I40E_PTP_40GB_INCVAL * READ_ONCE(pf->ptp_adj_mult);
|
||||
- diff = mul_u64_u64_div_u64(freq, (u64)ppb,
|
||||
- 1000000000ULL);
|
||||
+ diff = mul_u64_u64_div_u64(freq, (u64)scaled_ppm,
|
||||
+ 1000000ULL << 16);
|
||||
|
||||
if (neg_adj)
|
||||
adj = I40E_PTP_40GB_INCVAL - diff;
|
||||
@@ -1549,7 +1551,7 @@ static long i40e_ptp_create_clock(struct i40e_pf *pf)
|
||||
sizeof(pf->ptp_caps.name) - 1);
|
||||
pf->ptp_caps.owner = THIS_MODULE;
|
||||
pf->ptp_caps.max_adj = 999999999;
|
||||
- pf->ptp_caps.adjfreq = i40e_ptp_adjfreq;
|
||||
+ pf->ptp_caps.adjfine = i40e_ptp_adjfine;
|
||||
pf->ptp_caps.adjtime = i40e_ptp_adjtime;
|
||||
#ifdef HAVE_PTP_CLOCK_INFO_GETTIME64
|
||||
pf->ptp_caps.gettime64 = i40e_ptp_gettime;
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,10 +1,3 @@
|
||||
0001-i40e-Enable-getting-link-status-from-VF.patch
|
||||
0002-i40e-add-more-debug-info-for-VFs-still-in-reset.patch
|
||||
0003-i40e_main-Use-irq_update_affinity_hint.patch
|
||||
0004-I40E-Add-the-condition-of-undef-NEED_ETH_HW_ADDR_SET.patch
|
||||
0005-i40e-Accommodate-removal-of-u64_stats_fetch_-_irq.patch
|
||||
0006-i40e-drop-the-weight-argument-from-netif_napi_add.patch
|
||||
0007-i40e-Remove-use-of-pci_enable_pcie_error_reporting.patch
|
||||
0008-i40e-Include-xdp.h-where-required.patch
|
||||
0009-i40e-use-mul_u64_u64_div_u64-for-PTP-frequency-calcu.patch
|
||||
0010-i40e-convert-.adjfreq-to-.adjfine.patch
|
||||
0003-i40e-pass-linux-common-header.patch
|
||||
|
@ -27,7 +27,9 @@
|
||||
WITH_MOD_SIGN ?= 1
|
||||
|
||||
kheaders_name=$(shell ls /usr/src | grep linux@KERNEL_TYPE@-headers | grep amd64)
|
||||
kheaders_common=$(shell ls /usr/src | grep linux@KERNEL_TYPE@-headers | grep common)
|
||||
export KSRC=/usr/src/$(kheaders_name)
|
||||
export KSRC_COMMON=/usr/src/$(kheaders_common)
|
||||
kversion=$(shell echo $(kheaders_name) | sed 's/linux@KERNEL_TYPE@-headers-//g')
|
||||
kmod_name=i40e
|
||||
version=$(shell dpkg-parsechangelog | sed -n 's/^Version: *\([^-]\+\)-.\+/\1/p')
|
||||
|
@ -1,12 +1,11 @@
|
||||
---
|
||||
debver: 2.20.12
|
||||
debver: 2.25.7
|
||||
debname: i40e
|
||||
dl_path:
|
||||
name: i40e-2.20.12.tar.gz
|
||||
name: i40e-2.25.7.tar.gz
|
||||
url: "https://sourceforge.net/projects/e1000/files/i40e%20stable/\
|
||||
2.20.12/i40e-2.20.12.tar.gz/download"
|
||||
md5sum: 05fe1a7b28d47fefaff9ec20600c19c0
|
||||
sha256sum: 11419e81b85946575338ab2b78260a647dc458753d6c10de68dc8a199425b8ec
|
||||
2.25.7/i40e-2.25.7.tar.gz/download"
|
||||
sha256sum: 3ee4d3ac2be2622b7ea811075bf7dd50cf74ec12db7d58bb37b83b884ceb283d
|
||||
revision:
|
||||
dist: $STX_DIST
|
||||
GITREVCOUNT:
|
||||
|
@ -1,3 +1,9 @@
|
||||
iavf (4.11.1-1) unstable; urgency=medium
|
||||
|
||||
* Update iavf driver from v4.5.3.2 to v4.11.1
|
||||
|
||||
-- Jiping Ma <jiping.ma2@windriver.com> Mon, 11 Jun 2024 15:30:32 +0800
|
||||
|
||||
iavf (4.5.3.4-1) unstable; urgency=medium
|
||||
|
||||
* Update iavf driver from v4.5.3.2 to v4.5.3.4.
|
||||
|
@ -1,61 +0,0 @@
|
||||
From f6ac2de1f031994764d5bed39b79298929ef5b67 Mon Sep 17 00:00:00 2001
|
||||
From: "M. Vefa Bicakci" <vefa.bicakci@windriver.com>
|
||||
Date: Fri, 14 Jan 2022 17:39:52 -0500
|
||||
Subject: [PATCH 1/8] iavf_main: Use irq_update_affinity_hint
|
||||
|
||||
This commit makes iavf_main use irq_update_affinity_hint instead of
|
||||
irq_set_affinity_hint to set the CPU affinity hints. This is done
|
||||
because the latter function sets the IRQ CPU affinities, whereas the
|
||||
former does not, and this allows the use of the default IRQ affinity CPU
|
||||
mask provided via the irqaffinity= kernel command line option.
|
||||
|
||||
This commit essentially replicates the iavf patch in the following
|
||||
patch series:
|
||||
https://lore.kernel.org/netdev/20210903152430.244937-1-nitesh@redhat.com/t/#u
|
||||
|
||||
The iavf patch has been mainlined as of this writing:
|
||||
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0f9744f4ed539f2e847d7ed41993b243e3ba5cff
|
||||
|
||||
Signed-off-by: M. Vefa Bicakci <vefa.bicakci@windriver.com>
|
||||
---
|
||||
src/iavf_main.c | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/iavf_main.c b/src/iavf_main.c
|
||||
index 69059ac..cc5ca85 100644
|
||||
--- a/src/iavf_main.c
|
||||
+++ b/src/iavf_main.c
|
||||
@@ -544,10 +544,10 @@ iavf_request_traffic_irqs(struct iavf_adapter *adapter, char *basename)
|
||||
#ifdef HAVE_IRQ_AFFINITY_HINT
|
||||
/* Spread the IRQ affinity hints across online CPUs. Note that
|
||||
* get_cpu_mask returns a mask with a permanent lifetime so
|
||||
- * it's safe to use as a hint for irq_set_affinity_hint.
|
||||
+ * it's safe to use as a hint for irq_update_affinity_hint.
|
||||
*/
|
||||
cpu = cpumask_local_spread(q_vector->v_idx, -1);
|
||||
- irq_set_affinity_hint(irq_num, get_cpu_mask(cpu));
|
||||
+ irq_update_affinity_hint(irq_num, get_cpu_mask(cpu));
|
||||
#endif /* HAVE_IRQ_AFFINITY_HINT */
|
||||
}
|
||||
|
||||
@@ -561,7 +561,7 @@ free_queue_irqs:
|
||||
irq_set_affinity_notifier(irq_num, NULL);
|
||||
#endif
|
||||
#ifdef HAVE_IRQ_AFFINITY_HINT
|
||||
- irq_set_affinity_hint(irq_num, NULL);
|
||||
+ irq_update_affinity_hint(irq_num, NULL);
|
||||
#endif
|
||||
free_irq(irq_num, &adapter->q_vectors[vector]);
|
||||
}
|
||||
@@ -617,7 +617,7 @@ static void iavf_free_traffic_irqs(struct iavf_adapter *adapter)
|
||||
irq_set_affinity_notifier(irq_num, NULL);
|
||||
#endif
|
||||
#ifdef HAVE_IRQ_AFFINITY_HINT
|
||||
- irq_set_affinity_hint(irq_num, NULL);
|
||||
+ irq_update_affinity_hint(irq_num, NULL);
|
||||
#endif
|
||||
free_irq(irq_num, &adapter->q_vectors[vector]);
|
||||
}
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,7 +1,7 @@
|
||||
From 5b4ad9d0df45bb9704b12927c793a65ccc7a42fa Mon Sep 17 00:00:00 2001
|
||||
From 62066d848460a02b1d718d8030dbf71a81fd9549 Mon Sep 17 00:00:00 2001
|
||||
From: Li Zhou <li.zhou@windriver.com>
|
||||
Date: Thu, 7 Apr 2022 11:42:47 +0800
|
||||
Subject: [PATCH 2/8] intel-iavf: pass linux common header to check_aux_bus
|
||||
Subject: [PATCH] intel-iavf: pass linux common header to check_aux_bus
|
||||
|
||||
For debian, there are two header pkgs, e.g. linux-headers-5.10.0-6-amd64
|
||||
and linux-headers-5.10.0-6-common. linux-headers-5.10.0-6-amd64 is
|
||||
@ -13,15 +13,26 @@ debian rules.
|
||||
Signed-off-by: Li Zhou <li.zhou@windriver.com>
|
||||
[jpm: Refresh patch for iavf v4.5.3)]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
[jpm: Refresh patch for iavf v4.11.1)]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/common.mk | 7 ++++++-
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
src/common.mk | 9 +++++++--
|
||||
1 file changed, 7 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/common.mk b/src/common.mk
|
||||
index 0b2ad05..a0b65d6 100644
|
||||
index 2035be3..2a0f4bf 100644
|
||||
--- a/src/common.mk
|
||||
+++ b/src/common.mk
|
||||
@@ -410,9 +410,14 @@ export INSTALL_MOD_DIR ?= updates/drivers/net/ethernet/intel/${DRIVER}
|
||||
@@ -320,7 +320,7 @@ minimum_kver_check = $(eval $(call _minimum_kver_check,${1},${2},${3}))
|
||||
# call script that populates defines automatically
|
||||
$(if $(shell \
|
||||
$(if $(findstring 1,${V}),,QUIET_COMPAT=1) \
|
||||
- KSRC=${KSRC} OUT=${src}/kcompat_generated_defs.h CONFFILE=${CONFIG_FILE} \
|
||||
+ KSRC=${KSRC_COMMON} OUT=${src}/kcompat_generated_defs.h CONFFILE=${CONFIG_FILE} \
|
||||
bash ${src}/kcompat-generator.sh && echo ok), , $(error kcompat-generator.sh failed))
|
||||
|
||||
################
|
||||
@@ -387,9 +387,14 @@ export INSTALL_MOD_DIR ?= updates/drivers/net/ethernet/intel/${DRIVER}
|
||||
# If the check_aux_bus script exists, then this driver depends on the
|
||||
# auxiliary module. Run the script to determine if we need to include
|
||||
# auxiliary files with this build.
|
||||
@ -38,5 +49,5 @@ index 0b2ad05..a0b65d6 100644
|
||||
|
||||
# The out-of-tree auxiliary module we ship should be moved into this
|
||||
--
|
||||
2.42.0
|
||||
2.43.0
|
||||
|
@ -1,104 +0,0 @@
|
||||
From cb27bf3ae02dde94988f643e71f59d94943c8798 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Tue, 4 Apr 2023 23:40:48 -0700
|
||||
Subject: [PATCH 3/8] Fix the invalid check in iavf_remove()
|
||||
|
||||
If the netdev pointer is NULL, then iavf_remove() returns early to
|
||||
ensure that it does not proceed with an already-freed netdev instance.
|
||||
However, drvdata field of the iavf driver's pci_dev structure continues
|
||||
to keep the former value of the netdev pointer, and this value can be
|
||||
acquired from the pci_dev structure via pci_get_drvdata(). This causes a
|
||||
kernel panic when a forced reboot/shutdown is in progress due to the
|
||||
following sequence of events:
|
||||
|
||||
- The iavf_shutdown() callback is called by the kernel. This function
|
||||
detaches the device, brings it down if it was running and frees
|
||||
resources.
|
||||
- Later, the associated PF driver's shutdown callback is called:
|
||||
ice_shutdown(). That callback calls, among others, sriov_disable(),
|
||||
which then indirectly calls iavf_remove() again.
|
||||
- Kernel WARNING is reported because the work adminq_task->func is NULL
|
||||
in cancel_work_sync(&adapter->adminq_task) during iavf_remove(), that
|
||||
reason is the resource already had been freed in the first iavf_remove()
|
||||
running stage.
|
||||
"WARNING: CPU: 63 PID: 93678 at kernel/workqueue.c:3047
|
||||
__flush_work.isra.0+0x6b/0x80"
|
||||
|
||||
The patch for iavf resolves this issue by checking the pci_dev
|
||||
structure's is_busmaster field at the beginning of iavf_remove(). If the
|
||||
PCI device had already been disabled by an earlier call to
|
||||
iavf_shutdown() or iavf_remove(), via a call to pci_disable_device(),
|
||||
then the is_busmaster field would be set to zero. Based on this logic,
|
||||
if the is_busmaster field is set to zero, then the iavf_remove function
|
||||
returns early. This in turn avoids the aforementioned kernel panic
|
||||
caused by multiple calls to iavf_remove().
|
||||
|
||||
Reproducer:
|
||||
1. Create container with VF on PF driven by ice.
|
||||
2. Ensure that the VF is bound to iavf driver
|
||||
3. Reboot -f
|
||||
|
||||
[ 341.561449] iavf 0000:51:05.2: Removing device
|
||||
[ 341.730407] iavf 0000:51:05.1: Removing device
|
||||
[ 341.924457] iavf 0000:51:05.0: Removing device
|
||||
[ 347.130324] pci 0000:51:05.0: Removing from iommu group 161
|
||||
[ 347.130367] ------------[ cut here ]------------
|
||||
[ 347.130372] WARNING: CPU: 63 PID: 93678 at kernel/workqueue.c:3047 \
|
||||
__flush_work.isra.0+0x6b/0x80
|
||||
[ 347.130373] Modules linked in: ...
|
||||
[ 347.130688] ...
|
||||
[ 347.130958] CPU: 63 PID: 93678 Comm: reboot Kdump: loaded \
|
||||
Tainted: G S O \
|
||||
5.10.0-6-amd64 #1 Debian 5.10.162-1.stx.64
|
||||
[ 347.130990] Hardware name: ...
|
||||
[ 347.130995] RIP: 0010:__flush_work.isra.0+0x6b/0x80
|
||||
...
|
||||
[ 347.131076] Call Trace:
|
||||
[ 347.131083] __cancel_work_timer+0xff/0x190
|
||||
[ 347.131089] ? kernfs_put.part.0+0xd9/0x1a0
|
||||
[ 347.131150] ? kmem_cache_free+0x3bd/0x410
|
||||
[ 347.131158] iavf_remove+0x5e/0xe0 [iavf]
|
||||
[ 347.131163] ? pci_device_remove+0x38/0xa0
|
||||
[ 347.131167] ? __device_release_driver+0x17b/0x250
|
||||
[ 347.131169] ? device_release_driver+0x24/0x30
|
||||
[ 347.131172] ? pci_stop_bus_device+0x6c/0x90
|
||||
[ 347.131174] ? pci_stop_and_remove_bus_device+0xe/0x20
|
||||
[ 347.131179] ? pci_iov_remove_virtfn+0xc0/0x130
|
||||
[ 347.131185] ? sriov_disable+0x34/0xe0
|
||||
[ 347.131210] ? ice_free_vfs+0x77/0x350 [ice]
|
||||
[ 347.131215] ? flow_indr_dev_unregister+0x243/0x250
|
||||
[ 347.131226] ? ice_remove+0x3e5/0x430 [ice]
|
||||
[ 347.131237] ? ice_shutdown+0x16/0x50 [ice]
|
||||
[ 347.131240] ? pci_device_shutdown+0x31/0x60
|
||||
[ 347.131243] ? device_shutdown+0x156/0x1b0
|
||||
[ 347.131248] ? __do_sys_reboot.cold+0x2f/0x5b
|
||||
[ 347.131251] ? vfs_writev+0xc5/0x160
|
||||
[ 347.131254] ? get_max_files+0x20/0x20
|
||||
[ 347.131258] ? sched_clock+0x5/0x10
|
||||
[ 347.131264] ? get_vtime_delta+0xf/0xc0
|
||||
[ 347.131267] ? vtime_user_exit+0x1c/0x70
|
||||
[ 347.131272] ? do_syscall_64+0x30/0x40
|
||||
[ 347.131276] ? entry_SYSCALL_64_after_hwframe+0x61/0xc6
|
||||
|
||||
Signed-off-by: Jiping Ma <Jiping.ma2@windriver.com>
|
||||
---
|
||||
src/iavf_main.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/src/iavf_main.c b/src/iavf_main.c
|
||||
index cc5ca85..8f8c459 100644
|
||||
--- a/src/iavf_main.c
|
||||
+++ b/src/iavf_main.c
|
||||
@@ -5757,6 +5757,9 @@ static void iavf_remove(struct pci_dev *pdev)
|
||||
struct iavf_mac_filter *f, *ftmp;
|
||||
struct iavf_hw *hw = &adapter->hw;
|
||||
|
||||
+ /* Don't proceed with remove if pci device is already disable */
|
||||
+ if(pdev->is_busmaster == 0)
|
||||
+ return;
|
||||
/* Indicate we are in remove and not to run/schedule any driver tasks */
|
||||
set_bit(__IAVF_IN_REMOVE_TASK, &adapter->crit_section);
|
||||
cancel_work_sync(&adapter->adminq_task);
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,34 +0,0 @@
|
||||
From a1f51d984045f17414a746bfc05bbea2c8d3bcff Mon Sep 17 00:00:00 2001
|
||||
From: Peng Zhang <Peng.Zhang2@windriver.com>
|
||||
Date: Thu, 21 Sep 2023 05:43:31 +0800
|
||||
Subject: [PATCH 4/8] IAVF: Add the condition of 'undef NEED_ETH_HW_ADDR_SET'
|
||||
to
|
||||
|
||||
avoid redefinition conflict
|
||||
|
||||
For function eth_hw_addr_set has already been defined in
|
||||
linux-headers-5.10.0-6-common, add the condition of
|
||||
'undef NEED_ETH_HW_ADDR_SET' to avoid redefinition conflict.
|
||||
|
||||
Signed-off-by: Peng Zhang <Peng.Zhang2@windriver.com>
|
||||
---
|
||||
src/kcompat_std_defs.h | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat_std_defs.h b/src/kcompat_std_defs.h
|
||||
index a751779..3b9ed48 100644
|
||||
--- a/src/kcompat_std_defs.h
|
||||
+++ b/src/kcompat_std_defs.h
|
||||
@@ -263,6 +263,9 @@
|
||||
#define NEED_DEVLINK_ALLOC_SETS_DEV
|
||||
#define HAVE_DEVLINK_REGISTER_SETS_DEV
|
||||
#define NEED_ETH_HW_ADDR_SET
|
||||
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(5,11,0) && LINUX_VERSION_CODE >= KERNEL_VERSION(5,10,188))
|
||||
+#undef NEED_ETH_HW_ADDR_SET
|
||||
+#endif
|
||||
#else /* >= 5.15.0 */
|
||||
#define HAVE_ETHTOOL_COALESCE_EXTACK
|
||||
#define HAVE_NDO_ETH_IOCTL
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,52 +0,0 @@
|
||||
From 5bb575e7e2caf352e5ee9a476ed134746984fb15 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 23:30:36 -0700
|
||||
Subject: [PATCH 5/8] iavf: Remove the obsolte u64_stats_fetch_*_irq() users
|
||||
(drivers).
|
||||
|
||||
This commit accommodates commit dec5efcffad4 ("u64_stat: Remove
|
||||
the obsolete fetch_irq() variants.") merged in the v6.3 development
|
||||
cycle, which causes the compilation errors listed below with the
|
||||
new v6.6 kernel.
|
||||
|
||||
Our changes are inspired from the ones in commit 068c38ad88cc ("net:
|
||||
Remove the obsolte u64_stats_fetch_*_irq() users (drivers)."), which
|
||||
removes the use of the API functions in question from the iavf driver.
|
||||
We use C macros to alias the older API function names to the currently
|
||||
available API function names.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=dec5efcffad4
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=068c38ad88cc
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/iavf_ethtool_stats.h:281:23: error: implicit declaration of\
|
||||
function u64_stats_fetch_begin_irq; did you mean u64_stats_fetch_begin?\
|
||||
[-Werror=implicit-function-declaration]
|
||||
281 | start = !ring ? 0 : u64_stats_fetch_begin_irq(&ring->syncp);
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/kcompat.h | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat.h b/src/kcompat.h
|
||||
index c91951d..43b83f2 100644
|
||||
--- a/src/kcompat.h
|
||||
+++ b/src/kcompat.h
|
||||
@@ -5183,6 +5183,11 @@ static inline __u32 skb_get_hash_raw(const struct sk_buff *skb)
|
||||
#endif /* 3.14.0 */
|
||||
|
||||
/*****************************************************************************/
|
||||
+#if ( LINUX_VERSION_CODE > KERNEL_VERSION(6,6,0) )
|
||||
+#define u64_stats_fetch_begin_irq u64_stats_fetch_begin
|
||||
+#define u64_stats_fetch_retry_irq u64_stats_fetch_retry
|
||||
+#endif
|
||||
+
|
||||
#if ( LINUX_VERSION_CODE < KERNEL_VERSION(3,15,0) )
|
||||
#if ( LINUX_VERSION_CODE < KERNEL_VERSION(2,6,35) )
|
||||
#define HAVE_SKBUFF_RXHASH
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,43 +0,0 @@
|
||||
From 7a24bda57c62b6b7c90035fc8f0963d08ec8d8f4 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 23:32:42 -0700
|
||||
Subject: [PATCH 6/8] iavf: Include xdp.h where required
|
||||
|
||||
This commit accommodates commit 680ee0456a57 ("net: invert the netdevice.h
|
||||
vs xdp.h dependency") which removes the "#include <xdp.h>" C preprocessor
|
||||
directive from header file "netdevice.h". This commit was merged in the
|
||||
v6.6 development cycle and causes compilation failures with the v6.6 kernel,
|
||||
which are listed below.
|
||||
|
||||
We accommodate this commit by including the "xdp.h" header file as needed
|
||||
from "iavf_txrx.h".
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=680ee0456a57
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/iavf_txrx.h:456:22: error: field xdp_rxq has incomplete type
|
||||
456 | struct xdp_rxq_info xdp_rxq;
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/iavf_txrx.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/src/iavf_txrx.h b/src/iavf_txrx.h
|
||||
index a2a6a22..777b601 100644
|
||||
--- a/src/iavf_txrx.h
|
||||
+++ b/src/iavf_txrx.h
|
||||
@@ -4,6 +4,8 @@
|
||||
#ifndef _IAVF_TXRX_H_
|
||||
#define _IAVF_TXRX_H_
|
||||
|
||||
+#include <net/xdp.h>
|
||||
+
|
||||
/* Interrupt Throttling and Rate Limiting Goodies */
|
||||
#define IAVF_DEFAULT_IRQ_WORK 256
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,47 +0,0 @@
|
||||
From 59af78038f9fcb61852e44701fb040f836359a5d Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 23:34:59 -0700
|
||||
Subject: [PATCH 7/8] iavf: drop the weight argument from netif_napi_add
|
||||
|
||||
This patch accommodates commit b48b89f9c189 ("net: drop the weight argument
|
||||
from netif_napi_add") merged in the v6.1 development cycle, by applying a
|
||||
similar change to the out-of-tree iavf driver to resolve the compilation
|
||||
errors encountered with the v6.6 kernel, which are listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=b48b89f9c189
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/iavf_main.c: In function iavf_alloc_q_vectors:
|
||||
src/iavf_main.c:1730:3: error: too many arguments to function\
|
||||
netif_napi_add
|
||||
1730 | netif_napi_add(adapter->netdev, &q_vector->napi,
|
||||
| ^~~~~~~~~~~~~~
|
||||
In file included from /<<PKGBUILDDIR>>/src/iavf.h:10,
|
||||
from /<<PKGBUILDDIR>>/src/iavf_main.c:4:
|
||||
/usr/src/linux-headers-6.1.0-1-common/include/linux/netdevice.h:2575:1: note: \
|
||||
declared here
|
||||
2575 | netif_napi_add(struct net_device *dev, struct napi_struct *napi,
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/iavf_main.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/iavf_main.c b/src/iavf_main.c
|
||||
index 8f8c459..e0862ad 100644
|
||||
--- a/src/iavf_main.c
|
||||
+++ b/src/iavf_main.c
|
||||
@@ -1731,7 +1731,7 @@ static int iavf_alloc_q_vectors(struct iavf_adapter *adapter)
|
||||
cpumask_copy(&q_vector->affinity_mask, cpu_possible_mask);
|
||||
#endif
|
||||
netif_napi_add(adapter->netdev, &q_vector->napi,
|
||||
- iavf_napi_poll, NAPI_POLL_WEIGHT);
|
||||
+ iavf_napi_poll);
|
||||
}
|
||||
|
||||
return 0;
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,51 +0,0 @@
|
||||
From 6beb8717db54d692389272cffbb437c24db5bf6a Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Sun, 17 Mar 2024 23:37:16 -0700
|
||||
Subject: [PATCH 8/8] iavf: Remove redundant pci_enable_pcie_error_reporting()
|
||||
|
||||
This commit accommodates commit 7ec4b34be423 ("PCI/AER: Unexport
|
||||
pci_enable_pcie_error_reporting()") merged in the v6.6 development cycle,
|
||||
by applying changes similar to the ones found in commit bc4fddc3b306
|
||||
("iavf: Remove redundant pci_enable_pcie_error_reporting()") to resolve the
|
||||
iavf driver compilation failures encountered with the v6.6 kernel, which are
|
||||
listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=bc4fddc3b306
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/iavf_main.c:5859:2: error: implicit declaration of function \
|
||||
pci_disable_pcie_error_reporting [-Werror=implicit-function-declaration]
|
||||
5859 | pci_disable_pcie_error_reporting(pdev);
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/iavf_main.c | 4 ----
|
||||
1 file changed, 4 deletions(-)
|
||||
|
||||
diff --git a/src/iavf_main.c b/src/iavf_main.c
|
||||
index e0862ad..8f7c2b8 100644
|
||||
--- a/src/iavf_main.c
|
||||
+++ b/src/iavf_main.c
|
||||
@@ -5487,8 +5487,6 @@ static int iavf_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
||||
goto err_pci_reg;
|
||||
}
|
||||
|
||||
- pci_enable_pcie_error_reporting(pdev);
|
||||
-
|
||||
pci_set_master(pdev);
|
||||
|
||||
netdev = alloc_etherdev_mq(sizeof(struct iavf_adapter),
|
||||
@@ -5856,8 +5854,6 @@ static void iavf_remove(struct pci_dev *pdev)
|
||||
|
||||
free_netdev(netdev);
|
||||
|
||||
- pci_disable_pcie_error_reporting(pdev);
|
||||
-
|
||||
pci_disable_device(pdev);
|
||||
}
|
||||
|
||||
--
|
||||
2.42.0
|
||||
|
@ -1,8 +1 @@
|
||||
0001-iavf_main-Use-irq_update_affinity_hint.patch
|
||||
0002-intel-iavf-pass-linux-common-header-to-check_aux_bus.patch
|
||||
0003-Fix-the-invalid-check-in-iavf_remove.patch
|
||||
0004-IAVF-Add-the-condition-of-undef-NEED_ETH_HW_ADDR_SET.patch
|
||||
0005-iavf-Remove-the-obsolte-u64_stats_fetch_-_irq-users-.patch
|
||||
0006-iavf-include-xdp.h-where-required.patch
|
||||
0007-iavf-drop-the-weight-argument-from-netif_napi_add.patch
|
||||
0008-iavf-Remove-redundant-pci_enable_pcie_error_reportin.patch
|
||||
0001-intel-iavf-pass-linux-common-header-to-check_aux_bus.patch
|
||||
|
@ -1,12 +1,11 @@
|
||||
---
|
||||
debver: 4.5.3.4
|
||||
debver: 4.11.1
|
||||
debname: iavf
|
||||
dl_path:
|
||||
name: iavf-4.5.3.4.tar.gz
|
||||
url: "https://sourceforge.net/projects/e1000/files/\
|
||||
unsupported/iavf%20unsupported/iavf-4.5.3.4.tar.gz/download"
|
||||
md5sum: eca2a30b7f402d615beba9335c233052
|
||||
sha256sum: e14996f097aa8e80333377b4bcf71e8da476ea4c238f39d5760789bc8c1f545b
|
||||
name: iavf-4.11.1.tar.gz
|
||||
url: "https://sourceforge.net/projects/e1000/files/iavf%20stable/\
|
||||
4.11.1/iavf-4.11.1.tar.gz"
|
||||
sha256sum: 925c7ca46e53b53c236a2ac8fff7cb84187e4ee5ffa78e66f71d9db8df49a76a
|
||||
revision:
|
||||
dist: $STX_DIST
|
||||
GITREVCOUNT:
|
||||
|
@ -1,3 +1,9 @@
|
||||
ice (1.14.9.2-1) unstable; urgency=medium
|
||||
|
||||
* Update ICE driver to 1.14.9.2.
|
||||
|
||||
-- Jiping Ma <jiping.ma2@windriver.com> Mon, 11 Jun 2024 11:24:23 +0800
|
||||
|
||||
ice (1.9.11-1) unstable; urgency=medium
|
||||
|
||||
* Update ICE driver to 1.9.11 to support the Intel Logan Beach NIC
|
||||
|
@ -1,72 +0,0 @@
|
||||
From 089ab05c3aeff62f189e19a6960c2d9e80e33b62 Mon Sep 17 00:00:00 2001
|
||||
From: "M. Vefa Bicakci" <vefa.bicakci@windriver.com>
|
||||
Date: Fri, 14 Jan 2022 17:50:39 -0500
|
||||
Subject: [PATCH 01/16] ice_main, ice_lib: Use irq_update_affinity_hint
|
||||
|
||||
This commit makes the ice device driver use the irq_update_affinity_hint
|
||||
function instead of the irq_set_affinity_hint function. This is done
|
||||
because the latter function sets the IRQ CPU affinities, whereas the
|
||||
former does not, and this allows the use of the default IRQ affinity CPU
|
||||
mask provided via the irqaffinity= kernel command line option.
|
||||
|
||||
Please note that this patch was not cherry-picked from an upstream
|
||||
commit. The changes have been inspired by the i40e and iavf device
|
||||
driver patches in the following patch series:
|
||||
https://lore.kernel.org/netdev/20210903152430.244937-1-nitesh@redhat.com/t/#u
|
||||
|
||||
The aforementioned patches have been mainlined as of this writing with
|
||||
the following merge commit by Linus Torvalds:
|
||||
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=147cc5838c0f5c76e908b816e924ca378e0d4735
|
||||
|
||||
And the i40e and iavf patches are accessible at:
|
||||
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d34c54d1739c2cdf2e4437b74e6da269147f4987
|
||||
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0f9744f4ed539f2e847d7ed41993b243e3ba5cff
|
||||
|
||||
Signed-off-by: M. Vefa Bicakci <vefa.bicakci@windriver.com>
|
||||
[jm: Adapted the patch for context changes.]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_lib.c | 2 +-
|
||||
src/ice_main.c | 6 +++---
|
||||
2 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/ice_lib.c b/src/ice_lib.c
|
||||
index e47d255..50a287c 100644
|
||||
--- a/src/ice_lib.c
|
||||
+++ b/src/ice_lib.c
|
||||
@@ -3033,7 +3033,7 @@ void ice_vsi_free_irq(struct ice_vsi *vsi)
|
||||
irq_set_affinity_notifier(irq_num, NULL);
|
||||
|
||||
/* clear the affinity_mask in the IRQ descriptor */
|
||||
- irq_set_affinity_hint(irq_num, NULL);
|
||||
+ irq_update_affinity_hint(irq_num, NULL);
|
||||
synchronize_irq(irq_num);
|
||||
devm_free_irq(ice_pf_to_dev(pf), irq_num, vsi->q_vectors[i]);
|
||||
}
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index 6aaddd0..8f143ae 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -3498,8 +3498,8 @@ static int ice_vsi_req_irq_msix(struct ice_vsi *vsi, char *basename)
|
||||
irq_set_affinity_notifier(irq_num, affinity_notify);
|
||||
}
|
||||
|
||||
- /* assign the mask for this irq */
|
||||
- irq_set_affinity_hint(irq_num, &q_vector->affinity_mask);
|
||||
+ /* assign the affinity hint for this irq */
|
||||
+ irq_update_affinity_hint(irq_num, &q_vector->affinity_mask);
|
||||
}
|
||||
|
||||
vsi->irqs_ready = true;
|
||||
@@ -3511,7 +3511,7 @@ free_q_irqs:
|
||||
irq_num = ice_get_irq_num(pf, base + vector);
|
||||
if (!IS_ENABLED(CONFIG_RFS_ACCEL))
|
||||
irq_set_affinity_notifier(irq_num, NULL);
|
||||
- irq_set_affinity_hint(irq_num, NULL);
|
||||
+ irq_update_affinity_hint(irq_num, NULL);
|
||||
devm_free_irq(dev, irq_num, &vsi->q_vectors[vector]);
|
||||
}
|
||||
return err;
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,7 +1,7 @@
|
||||
From 499da82984524d0840aae4f7847eaa01c733d35d Mon Sep 17 00:00:00 2001
|
||||
From 0db610ecf34e07fe4ccc1309418b601ed2a5ae05 Mon Sep 17 00:00:00 2001
|
||||
From: Li Zhou <li.zhou@windriver.com>
|
||||
Date: Thu, 7 Apr 2022 11:42:47 +0800
|
||||
Subject: [PATCH 02/16] intel-ice: pass linux common header to check_aux_bus
|
||||
Subject: [PATCH] intel-ice: pass linux common header to check_aux_bus
|
||||
|
||||
For debian, there are two header pkgs, e.g. linux-headers-5.10.0-6-amd64
|
||||
and linux-headers-5.10.0-6-common. linux-headers-5.10.0-6-amd64 is
|
||||
@ -14,14 +14,23 @@ Signed-off-by: Li Zhou <li.zhou@windriver.com>
|
||||
[jpm: Refresh patch for ice v1.9.11)]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/common.mk | 7 ++++++-
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
src/common.mk | 9 +++++++--
|
||||
1 file changed, 7 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/common.mk b/src/common.mk
|
||||
index 960c15e..2ecff1b 100644
|
||||
index beb9d3f..90d318f 100644
|
||||
--- a/src/common.mk
|
||||
+++ b/src/common.mk
|
||||
@@ -410,9 +410,14 @@ export INSTALL_MOD_DIR ?= updates/drivers/net/ethernet/intel/${DRIVER}
|
||||
@@ -320,7 +320,7 @@ minimum_kver_check = $(eval $(call _minimum_kver_check,${1},${2},${3}))
|
||||
# call script that populates defines automatically
|
||||
$(if $(shell \
|
||||
$(if $(findstring 1,${V}),,QUIET_COMPAT=1) \
|
||||
- KSRC=${KSRC} OUT=${src}/kcompat_generated_defs.h CONFIG_FILE=${CONFIG_FILE} \
|
||||
+ KSRC=${KSRC_COMMON} OUT=${src}/kcompat_generated_defs.h CONFIG_FILE=${CONFIG_FILE} \
|
||||
bash ${src}/kcompat-generator.sh && echo ok), , $(error kcompat-generator.sh failed))
|
||||
|
||||
################
|
||||
@@ -387,9 +387,14 @@ export INSTALL_MOD_DIR ?= updates/drivers/net/ethernet/intel/${DRIVER}
|
||||
# If the check_aux_bus script exists, then this driver depends on the
|
||||
# auxiliary module. Run the script to determine if we need to include
|
||||
# auxiliary files with this build.
|
@ -1,78 +0,0 @@
|
||||
From 969a9135af990c8ebc5da73fa0f4aaa3776c6d89 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 10 Apr 2023 01:22:57 -0700
|
||||
Subject: [PATCH 04/16] Disable irq_msix_misc before ptp release
|
||||
|
||||
The ptp resources are released before disable irq_msix_misc
|
||||
interrupt in ice_remove() function when the system reboot, but
|
||||
the interrupt handler ice_misc_intr is still using these
|
||||
resources, which cause the panic to happen.
|
||||
|
||||
The patch fixes this by putting irq_msix_misc() before
|
||||
ice_ptp_release().
|
||||
|
||||
[48357.039676] pci 0000:51:06.6: Removing from iommu group 175
|
||||
[48357.039750] pci 0000:51:06.7: Removing from iommu group 176
|
||||
[48359.332713] ice 0000:51:00.0: removed Clock from enp81s0f0
|
||||
[48359.492523] BUG: kernel NULL pointer dereference, address: 0000000000000004
|
||||
[48359.499484] #PF: supervisor write access in kernel mode
|
||||
[48359.504711] #PF: error_code(0x0002) - not-present page
|
||||
[48359.509850] PGD 213439067 P4D 0
|
||||
[48359.513084] Oops: 0002 [#1] PREEMPT SMP NOPTI
|
||||
[48359.517442] CPU: 0 PID: 0 Comm: swapper/0 Kdump: loaded \
|
||||
Tainted: G S O \
|
||||
5.10.0-6-amd64 #1 Debian 5.10.162-1.stx.64
|
||||
[48359.528821] Hardware name: ...
|
||||
[48359.536303] RIP: 0010:_raw_spin_lock_irqsave+0x19/0x40
|
||||
[48359.541441] Code: ...
|
||||
...
|
||||
[48359.641473] <IRQ>
|
||||
[48359.643494] kthread_queue_work+0x22/0x70
|
||||
[48359.647527] ice_misc_intr+0x237/0x2c0 [ice]
|
||||
[48359.651796] ? __handle_irq_event_percpu+0x3d/0x190
|
||||
[48359.656680] ? handle_irq_event+0x58/0xb0
|
||||
[48359.660700] ? handle_edge_irq+0x93/0x240
|
||||
[48359.664721] ? asm_call_irq_on_stack+0xf/0x20
|
||||
[48359.669076] </IRQ>
|
||||
[48359.671186] ? common_interrupt+0xb3/0x130
|
||||
[48359.675285] ? asm_common_interrupt+0x1e/0x40
|
||||
[48359.679645] ? cpuidle_enter_state+0xca/0x350
|
||||
[48359.684002] ? cpuidle_enter+0x29/0x40
|
||||
[48359.687753] ? do_idle+0x1ec/0x2a0
|
||||
[48359.691160] ? cpu_startup_entry+0x19/0x20
|
||||
[48359.695260] ? start_kernel+0x54c/0x571
|
||||
[48359.699099] ? secondary_startup_64_no_verify+0xc2/0xcb
|
||||
|
||||
Reproducer:
|
||||
1. Create container with sts-silicom application(ptp related appliction).
|
||||
2. Ensure sts-silicom pod is running status.
|
||||
3. Reboot -f
|
||||
|
||||
Signed-off-by: Jiping Ma <Jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_main.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index fca6668..40b01ae 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -6519,6 +6519,7 @@ static void ice_remove(struct pci_dev *pdev)
|
||||
#ifdef HAVE_NETDEV_UPPER_INFO
|
||||
ice_deinit_lag(pf);
|
||||
#endif /* HAVE_NETDEV_UPPER_INFO */
|
||||
+ ice_free_irq_msix_misc(pf);
|
||||
if (test_bit(ICE_FLAG_PTP_SUPPORTED, pf->flags))
|
||||
ice_ptp_release(pf);
|
||||
if (ice_is_feature_supported(pf, ICE_F_GNSS))
|
||||
@@ -6528,7 +6529,6 @@ static void ice_remove(struct pci_dev *pdev)
|
||||
ice_setup_mc_magic_wake(pf);
|
||||
ice_vsi_release_all(pf);
|
||||
ice_set_wake(pf);
|
||||
- ice_free_irq_msix_misc(pf);
|
||||
ice_for_each_vsi(pf, i) {
|
||||
if (!pf->vsi[i])
|
||||
continue;
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,34 +0,0 @@
|
||||
From 3ccc2feb4b362edeb4b6c992df18be1667e87975 Mon Sep 17 00:00:00 2001
|
||||
From: Peng Zhang <Peng.Zhang2@windriver.com>
|
||||
Date: Thu, 21 Sep 2023 06:11:00 +0800
|
||||
Subject: [PATCH 05/16] ICE: Add the condition of 'undef NEED_ETH_HW_ADDR_SET'
|
||||
to
|
||||
|
||||
avoid redefinition conflict
|
||||
|
||||
For function eth_hw_addr_set has already been defined in
|
||||
linux-headers-5.10.0-6-common, add the condition of
|
||||
'undef NEED_ETH_HW_ADDR_SET' to avoid redefinition conflict.
|
||||
|
||||
Signed-off-by: Peng Zhang <Peng.Zhang2@windriver.com>
|
||||
---
|
||||
src/kcompat_std_defs.h | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat_std_defs.h b/src/kcompat_std_defs.h
|
||||
index 59356b8..a48fe09 100644
|
||||
--- a/src/kcompat_std_defs.h
|
||||
+++ b/src/kcompat_std_defs.h
|
||||
@@ -255,6 +255,9 @@
|
||||
#define NEED_DEVLINK_ALLOC_SETS_DEV
|
||||
#define HAVE_DEVLINK_REGISTER_SETS_DEV
|
||||
#define NEED_ETH_HW_ADDR_SET
|
||||
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(5,11,0) && LINUX_VERSION_CODE >= KERNEL_VERSION(5,10,188))
|
||||
+#undef NEED_ETH_HW_ADDR_SET
|
||||
+#endif
|
||||
#else /* >= 5.15.0 */
|
||||
#define HAVE_ETHTOOL_COALESCE_EXTACK
|
||||
#define HAVE_NDO_ETH_IOCTL
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,58 +0,0 @@
|
||||
From 8800ef77fd08fcc7f5d0491517bb7f566a4395b4 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 00:06:12 -0700
|
||||
Subject: [PATCH 06/16] ice: Accommodate removal of u64_stats_fetch_*_irq()
|
||||
|
||||
This commit accommodates commit dec5efcffad4 ("u64_stat: Remove
|
||||
the obsolete fetch_irq() variants.") merged in the v6.3 development
|
||||
cycle, which causes the compilation errors listed below with the
|
||||
new v6.6 kernel.
|
||||
|
||||
Our changes are inspired from the ones in commit 068c38ad88cc ("net:
|
||||
Remove the obsolte u64_stats_fetch_*_irq() users (drivers)."), which
|
||||
removes the use of the API functions in question from the ice driver.
|
||||
We use C macros to alias the older API function names to the currently
|
||||
available API function names.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=dec5efcffad4
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=068c38ad88cc
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
/src/ice_main.c:8266:11: error: implicit declaration of function \
|
||||
u64_stats_fetch_begin_irq; did you mean u64_stats_fetch_begin \
|
||||
[-Werror=implicit-function-declaration]
|
||||
8266 | start = u64_stats_fetch_begin_irq(&ring->syncp);
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
| u64_stats_fetch_begin
|
||||
/src/ice_main.c:8269:11: error: implicit declaration of function \
|
||||
u64_stats_fetch_retry_irq; did you mean u64_stats_fetch_retry \
|
||||
[-Werror=implicit-function-declaration]
|
||||
8269 | } while (u64_stats_fetch_retry_irq(&ring->syncp, start));
|
||||
| ^~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
| u64_stats_fetch_retry
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/kcompat.h | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat.h b/src/kcompat.h
|
||||
index 469094f..239054b 100644
|
||||
--- a/src/kcompat.h
|
||||
+++ b/src/kcompat.h
|
||||
@@ -1480,6 +1480,10 @@ char *_kc_devm_kstrdup(struct device *dev, const char *s, gfp_t gfp);
|
||||
#define HAVE_NET_GET_RANDOM_ONCE
|
||||
#define HAVE_PTP_1588_CLOCK_PINS
|
||||
#define HAVE_NETDEV_PORT
|
||||
+#if ( LINUX_VERSION_CODE > KERNEL_VERSION(6,6,0) )
|
||||
+#define u64_stats_fetch_begin_irq u64_stats_fetch_begin
|
||||
+#define u64_stats_fetch_retry_irq u64_stats_fetch_retry
|
||||
+#endif
|
||||
#endif /* 3.15.0 */
|
||||
|
||||
/*****************************************************************************/
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,78 +0,0 @@
|
||||
From 386677b4a6a41a50741b290d30cf0cc257183609 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 00:12:48 -0700
|
||||
Subject: [PATCH 07/16] ice: drop the weight argument from netif_napi_add
|
||||
|
||||
This patch accommodates commit b48b89f9c189 ("net: drop the weight argument
|
||||
from netif_napi_add") merged in the v6.1 development cycle, by applying a
|
||||
similar change to the out-of-tree ice driver to resolve the compilation
|
||||
errors encountered with the v6.6 kernel, which are listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=b48b89f9c189
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
/src/ice_main.c:4375:3: error: too many arguments to function netif_napi_add
|
||||
4375 | netif_napi_add(vsi->netdev, &vsi->q_vectors[v_idx]->napi,
|
||||
| ^~~~~~~~~~~~~~
|
||||
In file included from /usr/src/linux-headers-6.1.0-1-common/include/linux/\
|
||||
etherdevice.h:21,
|
||||
from /<<PKGBUILDDIR>>/src/kcompat.h:16,
|
||||
from /<<PKGBUILDDIR>>/src/ice.h:7,
|
||||
from /<<PKGBUILDDIR>>/src/ice_main.c:8:
|
||||
/usr/src/linux-headers-6.1.0-1-common/include/linux/netdevice.h:2575:1: \
|
||||
note: declared here
|
||||
2575 | netif_napi_add(struct net_device *dev, struct napi_struct *napi,
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_base.c | 3 +--
|
||||
src/ice_eswitch.c | 3 +--
|
||||
src/ice_main.c | 2 +-
|
||||
3 files changed, 3 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/ice_base.c b/src/ice_base.c
|
||||
index b43752e..d9c9d42 100644
|
||||
--- a/src/ice_base.c
|
||||
+++ b/src/ice_base.c
|
||||
@@ -127,8 +127,7 @@ static int ice_vsi_alloc_q_vector(struct ice_vsi *vsi, u16 v_idx)
|
||||
* handler here (i.e. resume, reset/rebuild, etc.)
|
||||
*/
|
||||
if (vsi->netdev)
|
||||
- netif_napi_add(vsi->netdev, &q_vector->napi, ice_napi_poll,
|
||||
- NAPI_POLL_WEIGHT);
|
||||
+ netif_napi_add(vsi->netdev, &q_vector->napi, ice_napi_poll);
|
||||
|
||||
out:
|
||||
/* tie q_vector and VSI together */
|
||||
diff --git a/src/ice_eswitch.c b/src/ice_eswitch.c
|
||||
index 6e44820..3c8f65b 100644
|
||||
--- a/src/ice_eswitch.c
|
||||
+++ b/src/ice_eswitch.c
|
||||
@@ -330,8 +330,7 @@ static int ice_eswitch_setup_reprs(struct ice_pf *pf)
|
||||
if (max_vsi_num < vsi->vsi_num)
|
||||
max_vsi_num = vsi->vsi_num;
|
||||
|
||||
- netif_napi_add(vf->repr->netdev, &vf->repr->q_vector->napi, ice_napi_poll,
|
||||
- NAPI_POLL_WEIGHT);
|
||||
+ netif_napi_add(vf->repr->netdev, &vf->repr->q_vector->napi, ice_napi_poll);
|
||||
|
||||
netif_keep_dst(vf->repr->netdev);
|
||||
}
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index 40b01ae..96ac8c3 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -4373,7 +4373,7 @@ static void ice_napi_add(struct ice_vsi *vsi)
|
||||
|
||||
ice_for_each_q_vector(vsi, v_idx)
|
||||
netif_napi_add(vsi->netdev, &vsi->q_vectors[v_idx]->napi,
|
||||
- ice_napi_poll, NAPI_POLL_WEIGHT);
|
||||
+ ice_napi_poll);
|
||||
}
|
||||
|
||||
/**
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,66 +0,0 @@
|
||||
From 83e6106cac698c253c54fc6410b7005b13d64565 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 00:15:20 -0700
|
||||
Subject: [PATCH 08/16] ice: Remove redundant pci_enable_pcie_error_reporting()
|
||||
|
||||
This commit accommodates commit 7ec4b34be423 ("PCI/AER: Unexport
|
||||
pci_enable_pcie_error_reporting()") merged in the v6.6 development cycle,
|
||||
by applying changes similar to the ones found in commit ba153552c18d
|
||||
("ice: Remove redundant pci_enable_pcie_error_reporting()") to resolve the
|
||||
ice driver compilation failures encountered with the v6.6 kernel, which are
|
||||
listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=7ec4b34be423
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=ba153552c18d
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
/src/ice_main.c:6013:2: error: implicit declaration of function \
|
||||
pci_enable_pcie_error_reporting [-Werror=implicit-function-declaration]
|
||||
6013 | pci_enable_pcie_error_reporting(pdev);
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_main.c | 4 ----
|
||||
1 file changed, 4 deletions(-)
|
||||
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index 96ac8c3..24a77fd 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -1101,7 +1101,6 @@ static void ice_remove_recovery_mode(struct ice_pf *pf)
|
||||
}
|
||||
|
||||
ice_reset(&pf->hw, ICE_RESET_PFR);
|
||||
- pci_disable_pcie_error_reporting(pf->pdev);
|
||||
#ifndef HAVE_DEVLINK_NOTIFY_REGISTER
|
||||
ice_devlink_unregister(pf);
|
||||
#endif /* !HAVE_DEVLINK_NOTIFY_REGISTER */
|
||||
@@ -6010,7 +6009,6 @@ ice_probe(struct pci_dev *pdev, const struct pci_device_id __always_unused *ent)
|
||||
return err;
|
||||
}
|
||||
|
||||
- pci_enable_pcie_error_reporting(pdev);
|
||||
pci_set_master(pdev);
|
||||
|
||||
pf->pdev = pdev;
|
||||
@@ -6377,7 +6375,6 @@ err_rec_mode:
|
||||
#ifndef HAVE_DEVLINK_NOTIFY_REGISTER
|
||||
ice_devlink_unregister(pf);
|
||||
#endif /* !HAVE_DEVLINK_NOTIFY_REGISTER */
|
||||
- pci_disable_pcie_error_reporting(pdev);
|
||||
pci_disable_device(pdev);
|
||||
return err;
|
||||
}
|
||||
@@ -6554,7 +6551,6 @@ static void ice_remove(struct pci_dev *pdev)
|
||||
ice_reset(hw, ICE_RESET_PFR);
|
||||
pci_wait_for_pending_transaction(pdev);
|
||||
ice_clear_interrupt_scheme(pf);
|
||||
- pci_disable_pcie_error_reporting(pdev);
|
||||
pci_disable_device(pdev);
|
||||
}
|
||||
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,42 +0,0 @@
|
||||
From 944ae5bff0c0b6124c23e7493a130e98ec7bc12e Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 00:17:03 -0700
|
||||
Subject: [PATCH 09/16] ice: Include xdp.h where required
|
||||
|
||||
This commit accommodates commit 680ee0456a57 ("net: invert the netdevice.h
|
||||
vs xdp.h dependency") which removes the "#include <xdp.h>" C preprocessor
|
||||
directive from header file "netdevice.h". This commit was merged in the
|
||||
v6.6 development cycle and causes compilation failures with the v6.6 kernel,
|
||||
which are listed below.
|
||||
|
||||
We accommodate this commit by including the "xdp.h" header file as needed
|
||||
from "ice_txrx.h".
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=680ee0456a57
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
/src/ice_txrx.h:399:22: error: field xdp_rxq has incomplete type
|
||||
399 | struct xdp_rxq_info xdp_rxq;
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_txrx.h | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/ice_txrx.h b/src/ice_txrx.h
|
||||
index 4daa554..d00c754 100644
|
||||
--- a/src/ice_txrx.h
|
||||
+++ b/src/ice_txrx.h
|
||||
@@ -5,6 +5,7 @@
|
||||
#define _ICE_TXRX_H_
|
||||
|
||||
#include "ice_type.h"
|
||||
+#include <net/xdp.h>
|
||||
|
||||
#define ICE_DFLT_IRQ_WORK 256
|
||||
#define ICE_RXBUF_3072 3072
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,48 +0,0 @@
|
||||
From c4f81132dfaf28fb215db27ba476cc6f15ac6124 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 07:56:01 +0000
|
||||
Subject: [PATCH 10/16] ice: add extack support in fdb del handlers
|
||||
|
||||
Accommodate the changes made in commit ca4567f1e6f6 ("rtnetlink: add extack
|
||||
support in fdb del handlers"), which was merged in the v5.19 development
|
||||
cycle, and which introduces an additional argument to the .ndo_fdb_del
|
||||
callback function in the net_device_ops structure. This causes build
|
||||
errors to be encountered, which are listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?id=ca4567f1e6f6
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/ice_main.c:11936:17: error: initialization of int (*)(struct ndmsg *,\
|
||||
struct nlattr **, struct net_device *, const unsigned char *, u16, \
|
||||
struct netlink_ext_ack *) int (*)(struct ndmsg *, struct nlattr **, \
|
||||
struct net_device *, const unsigned char *, short unsigned int, \
|
||||
struct netlink_ext_ack *) from incompatible pointer type int (*)\
|
||||
(struct ndmsg *, struct nlattr **, struct net_device *, const \
|
||||
unsigned char *, u16) int (*)(struct ndmsg *, struct nlattr **,\
|
||||
struct net_device *, const unsigned char *, short unsigned int)\
|
||||
[-Werror=incompatible-pointer-types]
|
||||
11936 | .ndo_fdb_del = ice_fdb_del,
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_main.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index 24a77fd..3cbbe17 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -7302,7 +7302,7 @@ ice_fdb_add(struct ndmsg *ndm, struct nlattr __always_unused *tb[],
|
||||
static int
|
||||
ice_fdb_del(struct ndmsg *ndm, __always_unused struct nlattr *tb[],
|
||||
struct net_device *dev, const unsigned char *addr,
|
||||
- __always_unused u16 vid)
|
||||
+ __always_unused u16 vid, struct netlink_ext_ack *extack)
|
||||
#else
|
||||
static int
|
||||
ice_fdb_del(struct ndmsg *ndm, __always_unused struct nlattr *tb[],
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,129 +0,0 @@
|
||||
From bd7dcb9835078e542b13bd8858533e5fef431602 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Thu, 29 Feb 2024 09:25:30 +0000
|
||||
Subject: [PATCH 11/16] ice: Use SET_NETDEV_DEVLINK_PORT to set devlink_port
|
||||
|
||||
This commit applies a subset of the changes in commit ac73d4bf2cda
|
||||
("net: make drivers to use SET_NETDEV_DEVLINK_PORT to set devlink_port"),
|
||||
merged in the v6.2 development cycle, to resolve compilation errors
|
||||
encountered with the v6.6 kernel when building the out-of-tree ice driver.
|
||||
|
||||
In addition, we also swap the order of register_netdev and
|
||||
SET_NETDEV_DEVLINK_PORT in ice_register_netdev() to fix the following
|
||||
kernel warning:
|
||||
|
||||
WARNING: CPU: 0 PID: 966 at ice-1.9.11/src/ice_main.c:5740 \
|
||||
ice_probe+0x155b/0x16b0 [ice]"
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=ac73d4bf2cda
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_devlink.c | 14 ++------------
|
||||
src/ice_main.c | 20 ++++++++++----------
|
||||
src/ice_repr.c | 9 ++++-----
|
||||
3 files changed, 16 insertions(+), 27 deletions(-)
|
||||
|
||||
diff --git a/src/ice_devlink.c b/src/ice_devlink.c
|
||||
index 41b7046..4878626 100644
|
||||
--- a/src/ice_devlink.c
|
||||
+++ b/src/ice_devlink.c
|
||||
@@ -1191,12 +1191,7 @@ int ice_devlink_create_pf_port(struct ice_pf *pf)
|
||||
*/
|
||||
void ice_devlink_destroy_pf_port(struct ice_pf *pf)
|
||||
{
|
||||
- struct devlink_port *devlink_port;
|
||||
-
|
||||
- devlink_port = &pf->devlink_port;
|
||||
-
|
||||
- devlink_port_type_clear(devlink_port);
|
||||
- devlink_port_unregister(devlink_port);
|
||||
+ devlink_port_unregister(&pf->devlink_port);
|
||||
}
|
||||
|
||||
#ifdef HAVE_DEVLINK_PORT_ATTR_PCI_VF
|
||||
@@ -1254,12 +1249,7 @@ int ice_devlink_create_vf_port(struct ice_vf *vf)
|
||||
*/
|
||||
void ice_devlink_destroy_vf_port(struct ice_vf *vf)
|
||||
{
|
||||
- struct devlink_port *devlink_port;
|
||||
-
|
||||
- devlink_port = &vf->devlink_port;
|
||||
-
|
||||
- devlink_port_type_clear(devlink_port);
|
||||
- devlink_port_unregister(devlink_port);
|
||||
+ devlink_port_unregister(&vf->devlink_port);
|
||||
}
|
||||
#endif /* HAVE_DEVLINK_PORT_ATTR_PCI_VF */
|
||||
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index 3cbbe17..728eab2 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -5740,6 +5740,13 @@ static int ice_register_netdev(struct ice_pf *pf)
|
||||
if (!vsi || !vsi->netdev)
|
||||
return -EIO;
|
||||
|
||||
+#if IS_ENABLED(CONFIG_NET_DEVLINK)
|
||||
+ err = ice_devlink_create_pf_port(pf);
|
||||
+ if (err)
|
||||
+ goto err_devlink_create;
|
||||
+
|
||||
+ SET_NETDEV_DEVLINK_PORT(vsi->netdev, &pf->devlink_port);
|
||||
+#endif /* CONFIG_NET_DEVLINK */
|
||||
err = register_netdev(vsi->netdev);
|
||||
if (err)
|
||||
goto err_register_netdev;
|
||||
@@ -5747,21 +5754,14 @@ static int ice_register_netdev(struct ice_pf *pf)
|
||||
set_bit(ICE_VSI_NETDEV_REGISTERED, vsi->state);
|
||||
netif_carrier_off(vsi->netdev);
|
||||
netif_tx_stop_all_queues(vsi->netdev);
|
||||
-#if IS_ENABLED(CONFIG_NET_DEVLINK)
|
||||
- err = ice_devlink_create_pf_port(pf);
|
||||
- if (err)
|
||||
- goto err_devlink_create;
|
||||
-
|
||||
- devlink_port_type_eth_set(&pf->devlink_port, vsi->netdev);
|
||||
-#endif /* CONFIG_NET_DEVLINK */
|
||||
|
||||
return 0;
|
||||
+
|
||||
+err_register_netdev:
|
||||
#if IS_ENABLED(CONFIG_NET_DEVLINK)
|
||||
+ ice_devlink_destroy_pf_port(pf);
|
||||
err_devlink_create:
|
||||
- unregister_netdev(vsi->netdev);
|
||||
- clear_bit(ICE_VSI_NETDEV_REGISTERED, vsi->state);
|
||||
#endif /* CONFIG_NET_DEVLINK */
|
||||
-err_register_netdev:
|
||||
free_netdev(vsi->netdev);
|
||||
vsi->netdev = NULL;
|
||||
clear_bit(ICE_VSI_NETDEV_ALLOCD, vsi->state);
|
||||
diff --git a/src/ice_repr.c b/src/ice_repr.c
|
||||
index bc00dad..26e254e 100644
|
||||
--- a/src/ice_repr.c
|
||||
+++ b/src/ice_repr.c
|
||||
@@ -437,15 +437,14 @@ static int ice_repr_add(struct ice_vf *vf)
|
||||
#endif /* CONFIG_NET_DEVLINK */
|
||||
|
||||
SET_NETDEV_DEV(repr->netdev, ice_pf_to_dev(vf->pf));
|
||||
- err = ice_repr_reg_netdev(repr->netdev);
|
||||
- if (err)
|
||||
- goto err_netdev;
|
||||
-
|
||||
#if IS_ENABLED(CONFIG_NET_DEVLINK)
|
||||
#ifdef HAVE_DEVLINK_PORT_ATTR_PCI_VF
|
||||
- devlink_port_type_eth_set(&vf->devlink_port, repr->netdev);
|
||||
+ SET_NETDEV_DEVLINK_PORT(repr->netdev, &vf->devlink_port);
|
||||
#endif /* HAVE_DEVLINK_PORT_ATTR_PCI_VF */
|
||||
#endif /* CONFIG_NET_DEVLINK */
|
||||
+ err = ice_repr_reg_netdev(repr->netdev);
|
||||
+ if (err)
|
||||
+ goto err_netdev;
|
||||
|
||||
ice_virtchnl_set_repr_ops(vf);
|
||||
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,90 +0,0 @@
|
||||
From a648b9ab1f5b7fb04765977d724cc8fc12356d66 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Pirko <jiri@nvidia.com>
|
||||
Date: Wed, 2 Nov 2022 17:02:10 +0100
|
||||
Subject: [PATCH 12/16] ice: remove unused ndo_get_devlink_port
|
||||
|
||||
Remove ndo_get_devlink_port which is no longer used alongside with the
|
||||
implementations in drivers.
|
||||
|
||||
Signed-off-by: Jiri Pirko <jiri@nvidia.com>
|
||||
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
||||
(cherry picked from commit 77df1db80da384c565106321f5934967690da7dd)
|
||||
[jma: This commit was cherry-picked from
|
||||
https://git.yoctoproject.org/linux-yocto/commit/?h=77df1db80d]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_main.c | 21 ---------------------
|
||||
src/ice_repr.c | 12 ------------
|
||||
2 files changed, 33 deletions(-)
|
||||
|
||||
diff --git a/src/ice_main.c b/src/ice_main.c
|
||||
index 728eab2..5d7a814 100644
|
||||
--- a/src/ice_main.c
|
||||
+++ b/src/ice_main.c
|
||||
@@ -608,24 +608,6 @@ static int ice_clear_promisc(struct ice_vsi *vsi, u8 promisc_m)
|
||||
return 0;
|
||||
}
|
||||
|
||||
-#if IS_ENABLED(CONFIG_NET_DEVLINK)
|
||||
-#ifdef HAVE_NDO_GET_DEVLINK_PORT
|
||||
-/**
|
||||
- * ice_get_devlink_port - Get devlink port from netdev
|
||||
- * @netdev: the netdevice structure
|
||||
- */
|
||||
-static struct devlink_port *ice_get_devlink_port(struct net_device *netdev)
|
||||
-{
|
||||
- struct ice_pf *pf = ice_netdev_to_pf(netdev);
|
||||
-
|
||||
- if (!ice_is_switchdev_running(pf))
|
||||
- return NULL;
|
||||
-
|
||||
- return &pf->devlink_port;
|
||||
-}
|
||||
-#endif /* HAVE_NDO_GET_DEVLINK_PORT */
|
||||
-#endif /* CONFIG_NET_DEVLINK */
|
||||
-
|
||||
/**
|
||||
* ice_vsi_sync_fltr - Update the VSI filter list to the HW
|
||||
* @vsi: ptr to the VSI
|
||||
@@ -12008,8 +11990,5 @@ static const struct net_device_ops ice_netdev_ops = {
|
||||
#endif /* HAVE_RHEL7_NET_DEVICE_OPS_EXT */
|
||||
#endif /* HAVE_NDO_DFWD_OPS */
|
||||
#if IS_ENABLED(CONFIG_NET_DEVLINK)
|
||||
-#ifdef HAVE_NDO_GET_DEVLINK_PORT
|
||||
- .ndo_get_devlink_port = ice_get_devlink_port,
|
||||
-#endif /* HAVE_NDO_GET_DEVLINK_PORT */
|
||||
#endif /* CONFIG_NET_DEVLINK */
|
||||
};
|
||||
diff --git a/src/ice_repr.c b/src/ice_repr.c
|
||||
index 26e254e..655ae46 100644
|
||||
--- a/src/ice_repr.c
|
||||
+++ b/src/ice_repr.c
|
||||
@@ -153,15 +153,6 @@ static int ice_repr_stop(struct net_device *netdev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
-#if IS_ENABLED(CONFIG_NET_DEVLINK) && defined(HAVE_DEVLINK_PORT_ATTR_PCI_VF)
|
||||
-static struct devlink_port *
|
||||
-ice_repr_get_devlink_port(struct net_device *netdev)
|
||||
-{
|
||||
- struct ice_repr *repr = ice_netdev_to_repr(netdev);
|
||||
-
|
||||
- return &repr->vf->devlink_port;
|
||||
-}
|
||||
-#endif /* CONFIG_NET_DEVLINK && HAVE_DEVLINK_PORT_ATTR_PCI_VF*/
|
||||
#if defined(HAVE_NDO_OFFLOAD_STATS) || defined(HAVE_RHEL7_EXTENDED_OFFLOAD_STATS)
|
||||
/**
|
||||
* ice_repr_sp_stats64 - get slow path stats for port representor
|
||||
@@ -322,9 +313,6 @@ static const struct net_device_ops ice_repr_netdev_ops = {
|
||||
#else
|
||||
.ndo_change_mtu = ice_repr_change_mtu,
|
||||
#endif /* HAVE_RHEL7_EXTENDED_MIN_MAX_MTU */
|
||||
-#ifdef HAVE_DEVLINK_PORT_ATTR_PCI_VF
|
||||
- .ndo_get_devlink_port = ice_repr_get_devlink_port,
|
||||
-#endif /* HAVE_DEVLINK_PORT_ATTR_PCI_VF */
|
||||
#ifdef HAVE_TC_SETUP_CLSFLOWER
|
||||
#ifdef HAVE_RHEL7_NETDEV_OPS_EXT_NDO_SETUP_TC
|
||||
.extended.ndo_setup_tc_rh = ice_repr_setup_tc,
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,41 +0,0 @@
|
||||
From 924bff95512505a13b19a2d2865d2fe4df2444e1 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 08:19:25 +0000
|
||||
Subject: [PATCH 13/16] ice: remove unused netdev_unregistering()
|
||||
|
||||
Accommodate the changes made in commit f3fb589aeb88 ("net: remove
|
||||
unused netdev_unregistering()"), which was merged in the v6.4
|
||||
development cycle, and which removed the function
|
||||
netdev_unregistering(). This causes build errors to be encountered,
|
||||
which are listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?id=f3fb589aeb88
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/ice_lag.c:280:7: error: implicit declaration of function netdev_unregistering;\
|
||||
did you mean devl_unregister [-Werror=implicit-function-declaration]
|
||||
280 | netdev_unregistering(lag_work->lag->upper_netdev))
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_lag.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/ice_lag.c b/src/ice_lag.c
|
||||
index 3722763..717e625 100644
|
||||
--- a/src/ice_lag.c
|
||||
+++ b/src/ice_lag.c
|
||||
@@ -277,7 +277,7 @@ static void ice_lag_process_event(struct work_struct *work)
|
||||
case NETDEV_UNREGISTER:
|
||||
netdev = lag_work->info.bonding_info.info.dev;
|
||||
if (netdev == lag_work->lag->netdev && lag_work->lag->bonded &&
|
||||
- netdev_unregistering(lag_work->lag->upper_netdev))
|
||||
+ lag_work->lag->upper_netdev->reg_state == NETREG_UNREGISTERING)
|
||||
ice_lag_unlink(lag_work->lag);
|
||||
break;
|
||||
default:
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,45 +0,0 @@
|
||||
From f075637a03a7ca7143a8b3247237d6526b389dbf Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Mon, 18 Mar 2024 08:24:37 +0000
|
||||
Subject: [PATCH 14/16] ice: Modify ice_gnss_tty_write() to be compatible with
|
||||
6.6.7 kernel
|
||||
|
||||
This commit accommodates commit 95713967ba52 ("tty: make
|
||||
tty_operations::write()'s count size_t"), which was merged in the v6.6
|
||||
development cycle, and which use size_t for counts and ssize_t for
|
||||
retval. This causes build errors to be encountered, which are listed below.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?id=95713967ba52
|
||||
|
||||
Resolved compilation errors:
|
||||
|
||||
src/ice_gnss.c:430:11: error: initialization of ssize_t (*)(struct tty_struct *,\
|
||||
const u8 *, size_t) {aka long int (*)(struct tty_struct *, const unsigned char *,\
|
||||
long unsigne pointer type int (*)(struct tty_struct *, const unsigned char *, int)\
|
||||
[-Werror=incompatible-pointer-types]
|
||||
430 | .write = ice_gnss_tty_write,
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_gnss.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/ice_gnss.c b/src/ice_gnss.c
|
||||
index aa2c55b..161faa2 100644
|
||||
--- a/src/ice_gnss.c
|
||||
+++ b/src/ice_gnss.c
|
||||
@@ -328,8 +328,8 @@ exit:
|
||||
* If any errors happen during the write call, a negative error value should be
|
||||
* returned instead of the number of characters that were written.
|
||||
*/
|
||||
-static int
|
||||
-ice_gnss_tty_write(struct tty_struct *tty, const unsigned char *buf, int count)
|
||||
+static ssize_t
|
||||
+ice_gnss_tty_write(struct tty_struct *tty, const u8 *buf, size_t count)
|
||||
{
|
||||
struct gnss_write_buf *write_buf;
|
||||
struct gnss_serial *gnss;
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,51 +0,0 @@
|
||||
From 604857fd1f50aeaa756386eaa51b54172652ab6e Mon Sep 17 00:00:00 2001
|
||||
From: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
|
||||
Date: Tue, 29 Nov 2022 18:51:38 +0900
|
||||
Subject: [PATCH 15/16] devlink: let the core report the driver name instead of
|
||||
the drivers
|
||||
|
||||
The driver name is available in device_driver::name. Right now,
|
||||
drivers still have to report this piece of information themselves in
|
||||
their devlink_ops::info_get callback function.
|
||||
|
||||
In order to factorize code, make devlink_nl_info_fill() add the driver
|
||||
name attribute.
|
||||
|
||||
Now that the core sets the driver name attribute, drivers are not
|
||||
supposed to call devlink_info_driver_name_put() anymore. Remove
|
||||
devlink_info_driver_name_put() and clean-up all the drivers using this
|
||||
function in their callback.
|
||||
|
||||
Signed-off-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
|
||||
Tested-by: Ido Schimmel <idosch@nvidia.com> # mlxsw
|
||||
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
|
||||
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
|
||||
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
||||
(cherry picked from commit 226bf980550627c88549b112ac6c8fb40873afb4)
|
||||
[jma: This commit was cherry-picked from
|
||||
https://git.yoctoproject.org/linux-yocto/commit/?h=226bf980]
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/ice_devlink.c | 6 ------
|
||||
1 file changed, 6 deletions(-)
|
||||
|
||||
diff --git a/src/ice_devlink.c b/src/ice_devlink.c
|
||||
index 4878626..b166187 100644
|
||||
--- a/src/ice_devlink.c
|
||||
+++ b/src/ice_devlink.c
|
||||
@@ -357,12 +357,6 @@ static int ice_devlink_info_get(struct devlink *devlink,
|
||||
}
|
||||
}
|
||||
|
||||
- err = devlink_info_driver_name_put(req, KBUILD_MODNAME);
|
||||
- if (err) {
|
||||
- NL_SET_ERR_MSG_MOD(extack, "Unable to set driver name");
|
||||
- goto out_free_ctx;
|
||||
- }
|
||||
-
|
||||
ice_info_get_dsn(pf, ctx);
|
||||
|
||||
err = devlink_info_serial_number_put(req, ctx->buf);
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,53 +0,0 @@
|
||||
From ef4c0b2682415cd257c04c813d2eab8028eb1746 Mon Sep 17 00:00:00 2001
|
||||
From: Jiping Ma <jiping.ma2@windriver.com>
|
||||
Date: Fri, 1 Mar 2024 02:03:33 +0000
|
||||
Subject: [PATCH 16/16] devlink: remove devlink features
|
||||
|
||||
This commit accommodates commit fb8421a94c56 ("devlink: remove
|
||||
devlink features"), which removes devlink_set_features() function.
|
||||
This commit was merged in the v6.4 development cycle and causes
|
||||
compilation failures with the v6.6 kernel, which are listed below.
|
||||
|
||||
We accommodate this commit by undefine HAVE_DEVLINK_SET_FEATURES
|
||||
for the v6.6 kernel. It is also align with the function of
|
||||
ice_devlink_register() in the ice driver of the upstream code.
|
||||
|
||||
References:
|
||||
* https://git.yoctoproject.org/linux-yocto/commit/?h=fb8421a94c56
|
||||
|
||||
Devlink features were introduced to disallow devlink reload calls of
|
||||
userspace before the devlink was fully initialized. The reason for this
|
||||
workaround was the fact that devlink reload was originally called
|
||||
without devlink instance lock held.
|
||||
|
||||
However, with recent changes that converted devlink reload to be
|
||||
performed under devlink instance lock, this is redundant so remove
|
||||
devlink features entirely.
|
||||
|
||||
src/ice_devlink.c:1034:2: error: implicit declaration of function \
|
||||
devlink_set_features; did you mean netif_skb_features? \
|
||||
[-Werror=implicit-function-declaration]
|
||||
1034 | devlink_set_features(devlink, DEVLINK_F_RELOAD);
|
||||
|
||||
Signed-off-by: Jiping Ma <jiping.ma2@windriver.com>
|
||||
---
|
||||
src/kcompat_std_defs.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/src/kcompat_std_defs.h b/src/kcompat_std_defs.h
|
||||
index a48fe09..9b523ec 100644
|
||||
--- a/src/kcompat_std_defs.h
|
||||
+++ b/src/kcompat_std_defs.h
|
||||
@@ -268,7 +268,9 @@
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5,16,0))
|
||||
#else /* >= 5.16.0 */
|
||||
#undef HAVE_PASID_SUPPORT
|
||||
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(6,6,0))
|
||||
#define HAVE_DEVLINK_SET_FEATURES
|
||||
+#endif
|
||||
#define HAVE_DEVLINK_NOTIFY_REGISTER
|
||||
#undef HAVE_DEVLINK_RELOAD_ENABLE_DISABLE
|
||||
#undef HAVE_DEVLINK_PARAMS_PUBLISH
|
||||
--
|
||||
2.43.0
|
||||
|
@ -1,16 +1,2 @@
|
||||
0001-ice_main-ice_lib-Use-irq_update_affinity_hint.patch
|
||||
0002-intel-ice-pass-linux-common-header-to-check_aux_bus.patch
|
||||
0003-rename-the-ddp-file-to-avoid-conflict.patch
|
||||
0004-Disable-irq_msix_misc-before-ptp-release.patch
|
||||
0005-ICE-Add-the-condition-of-undef-NEED_ETH_HW_ADDR_SET-.patch
|
||||
0006-ice-Accommodate-removal-of-u64_stats_fetch_-_irq.patch
|
||||
0007-ice-drop-the-weight-argument-from-netif_napi_add.patch
|
||||
0008-ice-Remove-redundant-pci_enable_pcie_error_reporting.patch
|
||||
0009-ice-Include-xdp.h-where-required.patch
|
||||
0010-ice-add-extack-support-in-fdb-del-handlers.patch
|
||||
0011-ice-Use-SET_NETDEV_DEVLINK_PORT-to-set-devlink_port.patch
|
||||
0012-ice-remove-unused-ndo_get_devlink_port.patch
|
||||
0013-ice-remove-unused-netdev_unregistering.patch
|
||||
0014-ice-Modify-ice_gnss_tty_write-to-be-compatible-with-.patch
|
||||
0015-devlink-let-the-core-report-the-driver-name-instead-.patch
|
||||
0016-devlink-remove-devlink-features.patch
|
||||
0001-intel-ice-pass-linux-common-header-to-check_aux_bus.patch
|
||||
0002-rename-the-ddp-file-to-avoid-conflict.patch
|
||||
|
@ -1,12 +1,11 @@
|
||||
---
|
||||
debver: 1.9.11
|
||||
debver: 1.14.9.2
|
||||
debname: ice
|
||||
dl_path:
|
||||
name: ice-1.9.11.tar.gz
|
||||
url: "https://sourceforge.net/projects/e1000/files/ice%20stable/\
|
||||
1.9.11/ice-1.9.11.tar.gz"
|
||||
md5sum: 26916c6a807a8ad7b977071d31c9ae01
|
||||
sha256sum: 1c7640e81ba489321c6b29024517851f927291eb2e1c5c292ef5a74a6462f064
|
||||
name: ice-1.14.9.2.tar.gz
|
||||
url: "https://github.com/intel/ethernet-linux-ice/releases/download/\
|
||||
v1.14.9.2/ice-1.14.9.2.tar.gz"
|
||||
sha256sum: 128c88073eba885d154a374feae01b16fc669b036f8e9af2ca83d539120fd026
|
||||
dl_files:
|
||||
800-Series-DDP-Comms-Package-1.3.37.0.zip:
|
||||
topdir: null
|
||||
|
Loading…
Reference in New Issue
Block a user