Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1573252 > unrolled thread
| Started by | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| First post | 2017-02-03 17:40 +0100 |
| Last post | 2017-02-06 22:40 +0100 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH] [net-next] net/mlx5e: fix another maybe-uninitialized false-positive Arnd Bergmann <arnd@arndb.de> - 2017-02-03 17:40 +0100
Re: [PATCH] [net-next] net/mlx5e: fix another maybe-uninitialized false-positive Or Gerlitz <gerlitz.or@gmail.com> - 2017-02-05 11:50 +0100
Re: [PATCH] [net-next] net/mlx5e: fix another maybe-uninitialized false-positive David Miller <davem@davemloft.net> - 2017-02-06 22:40 +0100
| From | Arnd Bergmann <arnd@arndb.de> |
|---|---|
| Date | 2017-02-03 17:40 +0100 |
| Subject | [PATCH] [net-next] net/mlx5e: fix another maybe-uninitialized false-positive |
| Message-ID | <t6P3X-47k-9@gated-at.bofh.it> |
In commit abeffce ("net/mlx5e: Fix a -Wmaybe-uninitialized warning"), I fixed a
gcc warning for the ipv4 offload handling. Now we get the same warning for the
added ipv6 support:
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c:815:40: warning: 'out_dev' may be used uninitialized in this function [-Wmaybe-uninitialized]
We can apply the same workaround here as well.
Fixes: ce99f6b97fcd ("net/mlx5e: Support SRIOV TC encapsulation offloads for IPv6 tunnels")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c b/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c
index e3cf5f484153..d87a82682cb5 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c
@@ -731,8 +731,8 @@ static int mlx5e_route_lookup_ipv6(struct mlx5e_priv *priv,
int ret;
dst = ip6_route_output(dev_net(mirred_dev), NULL, fl6);
- if (dst->error) {
- ret = dst->error;
+ ret = dst->error;
+ if (ret) {
dst_release(dst);
return ret;
}
--
2.9.0
[toc] | [next] | [standalone]
| From | Or Gerlitz <gerlitz.or@gmail.com> |
|---|---|
| Date | 2017-02-05 11:50 +0100 |
| Message-ID | <t7syl-6ab-3@gated-at.bofh.it> |
| In reply to | #1573252 |
On Fri, Feb 3, 2017 at 6:37 PM, Arnd Bergmann <arnd@arndb.de> wrote:
> In commit abeffce ("net/mlx5e: Fix a -Wmaybe-uninitialized warning"), I fixed a
> gcc warning for the ipv4 offload handling. Now we get the same warning for the
> added ipv6 support:
>
> drivers/net/ethernet/mellanox/mlx5/core/en_tc.c:815:40: warning: 'out_dev' may be used uninitialized in this function [-Wmaybe-uninitialized]
>
> We can apply the same workaround here as well.
>
> Fixes: ce99f6b97fcd ("net/mlx5e: Support SRIOV TC encapsulation offloads for IPv6 tunnels")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
frustrating... I don't see the warning with gcc 5.3.1 [1], but still,
the patch is OKay
Acked-by: Or Gerlitz <ogerlitz@mellanox.com>
[1] I used #make KCFLAGS='-Wmaybe-uninitialized'
M=drivers/net/ethernet/mellanox/mlx5/core -j something
[toc] | [prev] | [next] | [standalone]
| From | David Miller <davem@davemloft.net> |
|---|---|
| Date | 2017-02-06 22:40 +0100 |
| Subject | Re: [PATCH] [net-next] net/mlx5e: fix another maybe-uninitialized false-positive |
| Message-ID | <t7ZaX-214-35@gated-at.bofh.it> |
| In reply to | #1573252 |
From: Arnd Bergmann <arnd@arndb.de>
Date: Fri, 3 Feb 2017 17:37:03 +0100
> In commit abeffce ("net/mlx5e: Fix a -Wmaybe-uninitialized warning"), I fixed a
> gcc warning for the ipv4 offload handling. Now we get the same warning for the
> added ipv6 support:
>
> drivers/net/ethernet/mellanox/mlx5/core/en_tc.c:815:40: warning: 'out_dev' may be used uninitialized in this function [-Wmaybe-uninitialized]
>
> We can apply the same workaround here as well.
>
> Fixes: ce99f6b97fcd ("net/mlx5e: Support SRIOV TC encapsulation offloads for IPv6 tunnels")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Applied.
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web