net/mana: fix uninitialized scalar variable
PATCH 1/1 net/mana: fix uninitialized scalar variable
in case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitray value.
Coverity issue: 424690
--- drivers/net/mana/mana.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/mana/mana.c +1 -1
@@ -715,7 +715,7 @@ mana_dev_stats_reset(struct rte_eth_dev *dev __rte_unused)static int mana_get_ifname (const struct mana_priv *priv,char (*ifname)[IF_NAMESIZE ]) { -int ret; +int ret = -ENODEV ;DIR *dir;struct dirent *dent;
Signature · 1 line
2.43.0
PATCH v3 1/1 net/mana: fix uninitialized scalar variable
From: mmaatuq <[email protected]>
in case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitrary value.
Coverity issue: 424690
---
v3:
* add Fixes and Cc tags
v2:
* Fixed typo in word "arbitrary"
--- drivers/net/mana/mana.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/mana/mana.c +1 -1
@@ -715,7 +715,7 @@ mana_dev_stats_reset(struct rte_eth_dev *dev __rte_unused)static int mana_get_ifname (const struct mana_priv *priv,char (*ifname)[IF_NAMESIZE ]) { -int ret; +int ret = -ENODEV ;DIR *dir;struct dirent *dent;
--
2.43.0
Quoted 7 lines
Subject: [PATCH v3] net/mana: fix uninitialized scalar variable
[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
From: mmaatuq <[email protected]>
Quoted 8 lines
in case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitrary value.
Coverity issue: 424690
Fixes 84497839d9ca ("net/mana: support MTU update")Signed-off-by mmaatuq <[email protected]>
Thank you.
Quoted 11 lines · Mahmoud Maatuq
From: mmaatuq <[email protected]>
in case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitrary value.
Coverity issue: 424690
Fixes 84497839d9ca ("net/mana: support MTU update")Signed-off-by mmaatuq <[email protected]>
Hi Mahmoud,
According to Developer Certificate of Origin [1] that DPDK adopts [2], please use full name in the sign off.
[1]
http://developercertificate.org/
[2]
https://old.dpdk.org/dev#send
Quoted 25 lines
---
v3:
* add Fixes and Cc tags
v2:
* Fixed typo in word "arbitrary"--- drivers/net/mana/mana.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/net/mana/mana.c +1
-2@@ -715,7 +715,7 @@ mana_dev_stats_reset(struct rte_eth_dev *dev __rte_unused)static int mana_get_ifname (const struct mana_priv *priv,char (*ifname)[IF_NAMESIZE ]) { -int ret; +int ret = -ENODEV ;DIR *dir;struct dirent *dent; --2.43.0
PATCH v4 1/1 net/mana: fix uninitialized scalar variable
In reply to mmaatuqin case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitrary value.
Coverity issue: 424690
---
v4:
* used full name in the sign off
v3:
* add Fixes and Cc tags
v2:
* Fixed typo in word "arbitrary"
--- drivers/net/mana/mana.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/mana/mana.c +1 -1
@@ -715,7 +715,7 @@ mana_dev_stats_reset(struct rte_eth_dev *dev __rte_unused)static int mana_get_ifname (const struct mana_priv *priv,char (*ifname)[IF_NAMESIZE ]) { -int ret; +int ret = -ENODEV ;DIR *dir;struct dirent *dent;
--
2.43.0
Quoted 5 lines
Subject: [PATCH v4] net/mana: fix uninitialized scalar variable
[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Quoted 8 lines
in case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitrary value.
Coverity issue: 424690
Fixes 84497839d9ca ("net/mana: support MTU update")Signed-off-by Mahmoud Maatuq <[email protected]>
Quoted 25 lines
---
v4:
* used full name in the sign off
v3:
* add Fixes and Cc tags
v2:
* Fixed typo in word "arbitrary"--- drivers/net/mana/mana.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/net/mana/mana.c index renamed from drivers/net/mana/mana.c +0
-0
68c625258e..c37c4e3444100644drivers/net/mana/mana.c +0
-0@@ -715,7 +715,7 @@ mana_dev_stats_reset(struct rte_eth_dev *dev
__rte_unused) static intmana_get_ifname(const struct mana_priv *priv, char (*ifname)[IF_NAMESIZE]){drivers/net/mana/mana.c +1
-2-int ret; +int ret = -ENODEV ;DIR *dir;struct dirent *dent; --2.43.0
Ferruh Yigit
AppliedQuoted 8 lines · Long Li
Quoted 8 lines
Subject: [PATCH v4] net/mana: fix uninitialized scalar variable
[You don't often get email from [email protected]. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
in case we didn't enter or finished the loop without getting ifname we ret shouldn't have an arbitrary value.
Quoted 8 lines
Quoted 5 lines
Coverity issue: 424690
Fixes 84497839d9ca ("net/mana: support MTU update")Signed-off-by Mahmoud Maatuq <[email protected]>Reviewed-by Long Li <[email protected]>
Applied to dpdk-next-net/main, thanks.