diff mbox series

[RFC,2/2] intel/igb: Add a hint for threaded NAPI.

Message ID 20230524111259.1323415-3-bigeasy@linutronix.de (mailing list archive)
State RFC
Delegated to: Netdev Maintainers
Headers show
Series net: Add sysfs files for threaded NAPI. | expand

Checks

Context Check Description
netdev/series_format warning Target tree name not specified in the subject
netdev/tree_selection success Guessed tree name to be net-next, async
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 8 this patch: 8
netdev/cc_maintainers warning 4 maintainers not CCed: intel-wired-lan@lists.osuosl.org jesse.brandeburg@intel.com davem@davemloft.net anthony.l.nguyen@intel.com
netdev/build_clang success Errors and warnings before: 8 this patch: 8
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 8 this patch: 8
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 8 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Sebastian Andrzej Siewior May 24, 2023, 11:12 a.m. UTC
This works only with MSIX in this version. The +1 to v_idx is because
the first vector is used for a generic interrupt (igb_msix_other) and
the NAPI interrupts/ vectors follow after that one.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
---
 drivers/net/ethernet/intel/igb/igb_main.c | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
index 58872a4c25401..e7e662bf965ab 100644
--- a/drivers/net/ethernet/intel/igb/igb_main.c
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
@@ -1214,6 +1214,8 @@  static int igb_alloc_q_vector(struct igb_adapter *adapter,
 
 	/* initialize NAPI */
 	netif_napi_add(adapter->netdev, &q_vector->napi, igb_poll);
+	netif_napi_add_hints(&q_vector->napi, q_vector->name,
+			     adapter->msix_entries[v_idx + 1].vector);
 
 	/* tie q_vector and adapter together */
 	adapter->q_vector[v_idx] = q_vector;