netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] bridge: Fix redefined references
@ 2014-09-30  2:16 Tom Herbert
  2014-09-30  5:01 ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Tom Herbert @ 2014-09-30  2:16 UTC (permalink / raw)
  To: davem, pablo, netdev

Commit 34666d467cbf1e2e3 ("netfilter: bridge: move br_netfilter out of
the core") cause compiler errors when CONFIG_BRIDGE_NETFILTER is not
defined.

net/bridge/br_nf_core.c:77:1: error: expected identifier or '(' before '{' token
net/bridge/br_nf_core.c:88:115: error: redefinition of 'br_nf_core_init'
In file included from net/bridge/br_nf_core.c:23:0:
net/bridge/br_private.h:762:59: note: previous definition of 'br_nf_core_init' was here
net/bridge/br_nf_core.c:93:6: error: redefinition of 'br_nf_core_fini'
In file included from net/bridge/br_nf_core.c:23:0:
net/bridge/br_private.h:763:60: note: previous definition of 'br_nf_core_fini' was here

Add #if IS_ENABLED(CONFIG_BRIDGE_NETFILTER) around definitions of
the redefined functions.

Signed-off-by: Tom Herbert <therbert@google.com>
---
 net/bridge/br_nf_core.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/bridge/br_nf_core.c b/net/bridge/br_nf_core.c
index 387cb3b..ac4bea1 100644
--- a/net/bridge/br_nf_core.c
+++ b/net/bridge/br_nf_core.c
@@ -73,6 +73,7 @@ static const u32 br_dst_default_metrics[RTAX_MAX] = {
 	[RTAX_MTU - 1] = 1500,
 };
 
+#if IS_ENABLED(CONFIG_BRIDGE_NETFILTER)
 void br_netfilter_rtable_init(struct net_bridge *br)
 {
 	struct rtable *rt = &br->fake_rtable;
@@ -94,3 +95,4 @@ void br_nf_core_fini(void)
 {
 	dst_entries_destroy(&fake_dst_ops);
 }
+#endif
-- 
2.1.0.rc2.206.gedb03e5

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] bridge: Fix redefined references
  2014-09-30  2:16 [PATCH] bridge: Fix redefined references Tom Herbert
@ 2014-09-30  5:01 ` David Miller
  2014-09-30  9:05   ` Pablo Neira Ayuso
  0 siblings, 1 reply; 3+ messages in thread
From: David Miller @ 2014-09-30  5:01 UTC (permalink / raw)
  To: therbert; +Cc: pablo, netdev

From: Tom Herbert <therbert@google.com>
Date: Mon, 29 Sep 2014 19:16:44 -0700

> Commit 34666d467cbf1e2e3 ("netfilter: bridge: move br_netfilter out of
> the core") cause compiler errors when CONFIG_BRIDGE_NETFILTER is not
> defined.
> 
> net/bridge/br_nf_core.c:77:1: error: expected identifier or '(' before '{' token
> net/bridge/br_nf_core.c:88:115: error: redefinition of 'br_nf_core_init'
> In file included from net/bridge/br_nf_core.c:23:0:
> net/bridge/br_private.h:762:59: note: previous definition of 'br_nf_core_init' was here
> net/bridge/br_nf_core.c:93:6: error: redefinition of 'br_nf_core_fini'
> In file included from net/bridge/br_nf_core.c:23:0:
> net/bridge/br_private.h:763:60: note: previous definition of 'br_nf_core_fini' was here
> 
> Add #if IS_ENABLED(CONFIG_BRIDGE_NETFILTER) around definitions of
> the redefined functions.
> 
> Signed-off-by: Tom Herbert <therbert@google.com>

Pablo please either ACK this or provide an alternative fix ASAP.

This bridging build breakage is impacting a lot of people.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] bridge: Fix redefined references
  2014-09-30  5:01 ` David Miller
@ 2014-09-30  9:05   ` Pablo Neira Ayuso
  0 siblings, 0 replies; 3+ messages in thread
From: Pablo Neira Ayuso @ 2014-09-30  9:05 UTC (permalink / raw)
  To: David Miller; +Cc: therbert, netdev

On Tue, Sep 30, 2014 at 01:01:43AM -0400, David Miller wrote:
> From: Tom Herbert <therbert@google.com>
> Date: Mon, 29 Sep 2014 19:16:44 -0700
> 
> > Commit 34666d467cbf1e2e3 ("netfilter: bridge: move br_netfilter out of
> > the core") cause compiler errors when CONFIG_BRIDGE_NETFILTER is not
> > defined.
> > 
> > net/bridge/br_nf_core.c:77:1: error: expected identifier or '(' before '{' token
> > net/bridge/br_nf_core.c:88:115: error: redefinition of 'br_nf_core_init'
> > In file included from net/bridge/br_nf_core.c:23:0:
> > net/bridge/br_private.h:762:59: note: previous definition of 'br_nf_core_init' was here
> > net/bridge/br_nf_core.c:93:6: error: redefinition of 'br_nf_core_fini'
> > In file included from net/bridge/br_nf_core.c:23:0:
> > net/bridge/br_private.h:763:60: note: previous definition of 'br_nf_core_fini' was here
> > 
> > Add #if IS_ENABLED(CONFIG_BRIDGE_NETFILTER) around definitions of
> > the redefined functions.
> > 
> > Signed-off-by: Tom Herbert <therbert@google.com>
> 
> Pablo please either ACK this or provide an alternative fix ASAP.
> 
> This bridging build breakage is impacting a lot of people.

Sorry for the trouble this is causing.

I just sent a patch from Florian to resolve the compilataion breakage
when CONFIG_BRIDGE_NETFILTER=n.

Thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-09-30  9:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-30  2:16 [PATCH] bridge: Fix redefined references Tom Herbert
2014-09-30  5:01 ` David Miller
2014-09-30  9:05   ` Pablo Neira Ayuso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).