[dpdk-stable] [PATCH 18.11 2/4] kni: fix ethtool maybe-uninitialized warnings
Kevin Traynor
ktraynor at redhat.com
Tue Jun 16 15:51:35 CEST 2020
Similar to
commit 46136031f191 ("net/e1000: clean LTO warnings")
initialize the link variable to squash these maybe-uninitialized
false positive warnings in ethtool.
Signed-off-by: Kevin Traynor <ktraynor at redhat.com>
---
kernel/linux/kni/ethtool/igb/e1000_phy.c | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/kernel/linux/kni/ethtool/igb/e1000_phy.c b/kernel/linux/kni/ethtool/igb/e1000_phy.c
index b4d363ba28..1510211e3f 100644
--- a/kernel/linux/kni/ethtool/igb/e1000_phy.c
+++ b/kernel/linux/kni/ethtool/igb/e1000_phy.c
@@ -1587,5 +1587,5 @@ s32 e1000_setup_copper_link_generic(struct e1000_hw *hw)
{
s32 ret_val;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_setup_copper_link_generic");
@@ -1642,5 +1642,5 @@ s32 e1000_phy_force_speed_duplex_igp(struct e1000_hw *hw)
s32 ret_val;
u16 phy_data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_phy_force_speed_duplex_igp");
@@ -1708,5 +1708,5 @@ s32 e1000_phy_force_speed_duplex_m88(struct e1000_hw *hw)
s32 ret_val;
u16 phy_data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_phy_force_speed_duplex_m88");
@@ -1845,5 +1845,5 @@ s32 e1000_phy_force_speed_duplex_ife(struct e1000_hw *hw)
s32 ret_val;
u16 data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_phy_force_speed_duplex_ife");
@@ -2521,5 +2521,5 @@ s32 e1000_get_phy_info_m88(struct e1000_hw *hw)
s32 ret_val;
u16 phy_data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_get_phy_info_m88");
@@ -2596,5 +2596,5 @@ s32 e1000_get_phy_info_igp(struct e1000_hw *hw)
s32 ret_val;
u16 data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_get_phy_info_igp");
@@ -2658,5 +2658,5 @@ s32 e1000_get_phy_info_ife(struct e1000_hw *hw)
s32 ret_val;
u16 data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_get_phy_info_ife");
@@ -3047,5 +3047,5 @@ s32 e1000_phy_force_speed_duplex_82577(struct e1000_hw *hw)
s32 ret_val;
u16 phy_data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_phy_force_speed_duplex_82577");
@@ -3096,5 +3096,5 @@ s32 e1000_get_phy_info_82577(struct e1000_hw *hw)
s32 ret_val;
u16 data;
- bool link;
+ bool link = true;
DEBUGFUNC("e1000_get_phy_info_82577");
--
2.21.3
More information about the stable
mailing list