[PATCH net] rxrpc: Fix incorrect conditional on IPV6

Subsystems: networking [general], rxrpc sockets (af_rxrpc), the rest

STALE2885d

5 messages, 3 authors, 2018-10-13 · open the first message on its own page

[PATCH net] rxrpc: Fix incorrect conditional on IPV6

From: David Howells <dhowells@redhat.com>
Date: 2018-10-12 14:52:08

The udpv6_encap_enable() function is part of the ipv6 code, and if that is
configured as a loadable module and rxrpc is built in then a build failure
will occur because the conditional check is wrong:

  net/rxrpc/local_object.o: In function `rxrpc_lookup_local':
  local_object.c:(.text+0x2688): undefined reference to `udpv6_encap_enable'

Use the correct config symbol (CONFIG_AF_RXRPC_IPV6) in the conditional
check rather than CONFIG_IPV6 as that will do the right thing.

Fixes: 5271953cad31 ("rxrpc: Use the UDP encap_rcv hook")
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Arnd Bergmann <arnd@arndb.de>
---

 net/rxrpc/local_object.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/rxrpc/local_object.c b/net/rxrpc/local_object.c
index cad0691c2bb4..0906e51d3cfb 100644
--- a/net/rxrpc/local_object.c
+++ b/net/rxrpc/local_object.c
@@ -139,7 +139,7 @@ static int rxrpc_open_socket(struct rxrpc_local *local, struct net *net)
 	udp_sk(usk)->gro_complete = NULL;
 
 	udp_encap_enable();
-#if IS_ENABLED(CONFIG_IPV6)
+#if IS_ENABLED(CONFIG_AF_RXRPC_IPV6)
 	if (local->srx.transport.family == AF_INET6)
 		udpv6_encap_enable();
 #endif

Re: [PATCH net] rxrpc: Fix incorrect conditional on IPV6

From: Eric Dumazet <hidden>
Date: 2018-10-12 22:52:18


On 10/12/2018 07:52 AM, David Howells wrote:
The udpv6_encap_enable() function is part of the ipv6 code, and if that is
configured as a loadable module and rxrpc is built in then a build failure
will occur because the conditional check is wrong:

  net/rxrpc/local_object.o: In function `rxrpc_lookup_local':
  local_object.c:(.text+0x2688): undefined reference to `udpv6_encap_enable'

Use the correct config symbol (CONFIG_AF_RXRPC_IPV6) in the conditional
check rather than CONFIG_IPV6 as that will do the right thing.

Fixes: 5271953cad31 ("rxrpc: Use the UDP encap_rcv hook")
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Arnd Bergmann <arnd@arndb.de>
Nit : Correct attribution would require a Reported-by: tag

Re: [PATCH net] rxrpc: Fix incorrect conditional on IPV6

From: David Howells <dhowells@redhat.com>
Date: 2018-10-12 23:10:27

Eric Dumazet [off-list ref] wrote:
Nit : Correct attribution would require a Reported-by: tag
Point.  I'll repost it with a To: line also, I'm waiting to see if Arnd will
ack it.

David

Re: [PATCH net] rxrpc: Fix incorrect conditional on IPV6

From: David Miller <davem@davemloft.net>
Date: 2018-10-13 01:45:15

From: Eric Dumazet <redacted>
Date: Fri, 12 Oct 2018 08:19:20 -0700

On 10/12/2018 07:52 AM, David Howells wrote:
quoted
The udpv6_encap_enable() function is part of the ipv6 code, and if that is
configured as a loadable module and rxrpc is built in then a build failure
will occur because the conditional check is wrong:

  net/rxrpc/local_object.o: In function `rxrpc_lookup_local':
  local_object.c:(.text+0x2688): undefined reference to `udpv6_encap_enable'

Use the correct config symbol (CONFIG_AF_RXRPC_IPV6) in the conditional
check rather than CONFIG_IPV6 as that will do the right thing.

Fixes: 5271953cad31 ("rxrpc: Use the UDP encap_rcv hook")
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Arnd Bergmann <arnd@arndb.de>
Nit : Correct attribution would require a Reported-by: tag
Right.

Re: [PATCH net] rxrpc: Fix incorrect conditional on IPV6

From: David Howells <dhowells@redhat.com>
Date: 2018-10-13 03:50:06

David Miller [off-list ref] wrote:
quoted
Nit : Correct attribution would require a Reported-by: tag
Right.
And I've posted a new version with that and the reviewed-by from Arnd.

David
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help