lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 25 Feb 2019 12:13:50 +0800
From:   Hangbin Liu <liuhangbin@...il.com>
To:     netdev@...r.kernel.org
Cc:     Stefano Brivio <sbrivio@...hat.com>,
        "David S . Miller" <davem@...emloft.net>,
        David Ahern <dsa@...ulusnetworks.com>,
        Hangbin Liu <liuhangbin@...il.com>
Subject: [PATCH net] geneve: use ipv6_mod_enabled to check if ipv6 is disabled

ipv6_mod_enabled() is more safe and gentle to check if ipv6 is disabled
at running time.

Fixes: c0a47e44c098 ("geneve: should not call rt6_lookup() when ipv6 was disabled")
Signed-off-by: Hangbin Liu <liuhangbin@...il.com>
---
 drivers/net/geneve.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/geneve.c b/drivers/net/geneve.c
index 3377ac66a347..42c5e43ece68 100644
--- a/drivers/net/geneve.c
+++ b/drivers/net/geneve.c
@@ -1514,7 +1514,7 @@ static void geneve_link_config(struct net_device *dev,
 	case AF_INET6: {
 		struct rt6_info *rt;
 
-		if (!__in6_dev_get(dev))
+		if (!ipv6_mod_enabled())
 			break;
 
 		rt = rt6_lookup(geneve->net, &info->key.u.ipv6.dst, NULL, 0,
-- 
2.19.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ