diff mbox series

[net-next,v2,13/14] igbvf: remove unused spinlock

Message ID 20241113185431.1289708-14-anthony.l.nguyen@intel.com (mailing list archive)
State Accepted
Commit 4d26b6eccdc273af02742771e4805755396477fe
Delegated to: Netdev Maintainers
Headers show
Series Intel Wired LAN Driver Updates 2024-11-05 (ice, ixgbe, igc. igb, igbvf, e1000) | expand

Checks

Context Check Description
netdev/series_format success Posting correctly formatted
netdev/tree_selection success Clearly marked for net-next
netdev/ynl success Generated files up to date; no warnings/errors; no diff in generated;
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: 3 this patch: 3
netdev/build_tools success No tools touched, skip
netdev/cc_maintainers success CCed 5 of 5 maintainers
netdev/build_clang success Errors and warnings before: 3 this patch: 3
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: 4 this patch: 4
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 27 lines checked
netdev/build_clang_rust success No Rust files in patch. Skipping build
netdev/kdoc success Errors and warnings before: 20 this patch: 20
netdev/source_inline success Was 0 now: 0
netdev/contest success net-next-2024-11-15--21-00 (tests: 789)

Commit Message

Tony Nguyen Nov. 13, 2024, 6:54 p.m. UTC
From: Wander Lairson Costa <wander@redhat.com>

tx_queue_lock and stats_lock are declared and initialized, but never
used. Remove them.

Signed-off-by: Wander Lairson Costa <wander@redhat.com>
Reviewed-by: Paul Menzel <pmenzel@molgen.mpg.de>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
---
 drivers/net/ethernet/intel/igbvf/igbvf.h  | 3 ---
 drivers/net/ethernet/intel/igbvf/netdev.c | 3 ---
 2 files changed, 6 deletions(-)

Comments

Paul Menzel Nov. 14, 2024, 7:57 a.m. UTC | #1
Dear Wander, dear Linux folks,


Thank you for your patch.


Am 13.11.24 um 19:54 schrieb Tony Nguyen:
> From: Wander Lairson Costa <wander@redhat.com>
> 
> tx_queue_lock and stats_lock are declared and initialized, but never
> used. Remove them.
> 
> Signed-off-by: Wander Lairson Costa <wander@redhat.com>
> Reviewed-by: Paul Menzel <pmenzel@molgen.mpg.de>
> Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>

Would a Fixes: tag be handy?


Kind regards,

Paul
Wander Lairson Costa Nov. 14, 2024, 11:36 a.m. UTC | #2
On Thu, Nov 14, 2024 at 5:04 AM Paul Menzel <pmenzel@molgen.mpg.de> wrote:
>
> Dear Wander, dear Linux folks,
>
>
> Thank you for your patch.
>
>
> Am 13.11.24 um 19:54 schrieb Tony Nguyen:
> > From: Wander Lairson Costa <wander@redhat.com>
> >
> > tx_queue_lock and stats_lock are declared and initialized, but never
> > used. Remove them.
> >
> > Signed-off-by: Wander Lairson Costa <wander@redhat.com>
> > Reviewed-by: Paul Menzel <pmenzel@molgen.mpg.de>
> > Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
>
> Would a Fixes: tag be handy?
>

Hrm, this is not fixing anything, actually. It is just a cleanup.

>
> Kind regards,
>
> Paul
>
diff mbox series

Patch

diff --git a/drivers/net/ethernet/intel/igbvf/igbvf.h b/drivers/net/ethernet/intel/igbvf/igbvf.h
index 6ad35a00a287..ca6e44245a7b 100644
--- a/drivers/net/ethernet/intel/igbvf/igbvf.h
+++ b/drivers/net/ethernet/intel/igbvf/igbvf.h
@@ -169,8 +169,6 @@  struct igbvf_adapter {
 	u16 link_speed;
 	u16 link_duplex;
 
-	spinlock_t tx_queue_lock; /* prevent concurrent tail updates */
-
 	/* track device up/down/testing state */
 	unsigned long state;
 
@@ -220,7 +218,6 @@  struct igbvf_adapter {
 	/* OS defined structs */
 	struct net_device *netdev;
 	struct pci_dev *pdev;
-	spinlock_t stats_lock; /* prevent concurrent stats updates */
 
 	/* structs defined in e1000_hw.h */
 	struct e1000_hw hw;
diff --git a/drivers/net/ethernet/intel/igbvf/netdev.c b/drivers/net/ethernet/intel/igbvf/netdev.c
index 925d7286a8ee..02044aa2181b 100644
--- a/drivers/net/ethernet/intel/igbvf/netdev.c
+++ b/drivers/net/ethernet/intel/igbvf/netdev.c
@@ -1656,12 +1656,9 @@  static int igbvf_sw_init(struct igbvf_adapter *adapter)
 	if (igbvf_alloc_queues(adapter))
 		return -ENOMEM;
 
-	spin_lock_init(&adapter->tx_queue_lock);
-
 	/* Explicitly disable IRQ since the NIC can be in any state. */
 	igbvf_irq_disable(adapter);
 
-	spin_lock_init(&adapter->stats_lock);
 	spin_lock_init(&adapter->hw.mbx_lock);
 
 	set_bit(__IGBVF_DOWN, &adapter->state);