i40evf: fix compiler warning of unused variable
Subsystems (2)
PATCH v2 1/1 i40evf: fix compiler warning of unused variable
From: Jesse Brandeburg <[email protected]>
Compiler complained of an unused variable, which the driver was just using to store the result of a rd32 which is used to clear a register unconditionally. Just drop the unused variable and re-use one.
---
v2: Fix title since Jesse used the same title for two difference patches
drivers/net/ethernet/intel/i40evf/i40evf_main.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/i40evf/i40evf_main.c +2 -4
@@ -305,12 +305,10 @@ static irqreturn_t i40evf_msix_aq(int irq, void *data)struct i40evf_adapter *adapter =netdev_priv (netdev);struct i40e_hw *hw = &adapter->hw;u32 val; -u32 ena_mask; -/* handle non-queue interrupts */ +/* handle non-queue interrupts, these reads clear the registers */ val =rd32 (hw,I40E_VFINT_ICR01 ); - ena_mask =rd32 (hw,I40E_VFINT_ICR0_ENA1 ); - + val =rd32 (hw,I40E_VFINT_ICR0_ENA1 ); val =rd32 (hw,I40E_VFINT_DYN_CTL01 ); val = val |I40E_VFINT_DYN_CTL01_CLEARPBA_MASK ;
Signature · 1 line
2.4.3
Bowers
PATCH v2 1/1 i40evf: fix compiler warning of unused variable
Quoted 14 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Jeff Kirsher
Sent: Sunday, October 04, 2015 1:10 AM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [PATCH v2] i40evf: fix compiler warning of unused variableFrom: Jesse Brandeburg <[email protected]>
Compiler complained of an unused variable, which the driver was just using to store the result of a rd32 which is used to clear a register unconditionally. Just drop the unused variable and re-use one.
Quoted 6 lines
Signed-off-by Jesse Brandeburg <[email protected]>---
v2: Fix title since Jesse used the same title for two difference patchesdrivers/net/ethernet/intel/i40evf/i40evf_main.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
Bowers
PATCH v2 1/1 i40evf: fix compiler warning of unused variable
In reply to Jeff KirsherQuoted 14 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Jeff Kirsher
Sent: Sunday, October 04, 2015 1:10 AM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [PATCH v2] i40evf: fix compiler warning of unused variableFrom: Jesse Brandeburg <[email protected]>
Compiler complained of an unused variable, which the driver was just using to store the result of a rd32 which is used to clear a register unconditionally. Just drop the unused variable and re-use one.
Quoted 6 lines
Signed-off-by Jesse Brandeburg <[email protected]>---
v2: Fix title since Jesse used the same title for two difference patchesdrivers/net/ethernet/intel/i40evf/i40evf_main.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
Patch code changes correctly applied, compiler does not issue unused variable warning at compile time.