Skip to content
Snippets Groups Projects
Commit f586287e authored by Randy Dunlap's avatar Randy Dunlap Committed by David S. Miller
Browse files

bridge: fix IPV6=n build


Fix bridge netfilter code so that it uses CONFIG_IPV6 as needed:

net/built-in.o: In function `ebt_filter_ip6':
ebt_ip6.c:(.text+0x87c37): undefined reference to `ipv6_skip_exthdr'
net/built-in.o: In function `ebt_log_packet':
ebt_log.c:(.text+0x88dee): undefined reference to `ipv6_skip_exthdr'
make[1]: *** [.tmp_vmlinux1] Error 1

Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 92c0574f
No related branches found
No related tags found
No related merge requests found
...@@ -85,7 +85,7 @@ config BRIDGE_EBT_IP ...@@ -85,7 +85,7 @@ config BRIDGE_EBT_IP
config BRIDGE_EBT_IP6 config BRIDGE_EBT_IP6
tristate "ebt: IP6 filter support" tristate "ebt: IP6 filter support"
depends on BRIDGE_NF_EBTABLES depends on BRIDGE_NF_EBTABLES && IPV6
help help
This option adds the IP6 match, which allows basic IPV6 header field This option adds the IP6 match, which allows basic IPV6 header field
filtering. filtering.
......
...@@ -14,7 +14,7 @@ obj-$(CONFIG_BRIDGE_EBT_802_3) += ebt_802_3.o ...@@ -14,7 +14,7 @@ obj-$(CONFIG_BRIDGE_EBT_802_3) += ebt_802_3.o
obj-$(CONFIG_BRIDGE_EBT_AMONG) += ebt_among.o obj-$(CONFIG_BRIDGE_EBT_AMONG) += ebt_among.o
obj-$(CONFIG_BRIDGE_EBT_ARP) += ebt_arp.o obj-$(CONFIG_BRIDGE_EBT_ARP) += ebt_arp.o
obj-$(CONFIG_BRIDGE_EBT_IP) += ebt_ip.o obj-$(CONFIG_BRIDGE_EBT_IP) += ebt_ip.o
obj-$(CONFIG_BRIDGE_EBT_IP) += ebt_ip6.o obj-$(CONFIG_BRIDGE_EBT_IP6) += ebt_ip6.o
obj-$(CONFIG_BRIDGE_EBT_LIMIT) += ebt_limit.o obj-$(CONFIG_BRIDGE_EBT_LIMIT) += ebt_limit.o
obj-$(CONFIG_BRIDGE_EBT_MARK) += ebt_mark_m.o obj-$(CONFIG_BRIDGE_EBT_MARK) += ebt_mark_m.o
obj-$(CONFIG_BRIDGE_EBT_PKTTYPE) += ebt_pkttype.o obj-$(CONFIG_BRIDGE_EBT_PKTTYPE) += ebt_pkttype.o
......
...@@ -123,6 +123,7 @@ ebt_log_packet(unsigned int pf, unsigned int hooknum, ...@@ -123,6 +123,7 @@ ebt_log_packet(unsigned int pf, unsigned int hooknum,
goto out; goto out;
} }
#if defined(CONFIG_BRIDGE_EBT_IP6) || defined(CONFIG_BRIDGE_EBT_IP6_MODULE)
if ((bitmask & EBT_LOG_IP6) && eth_hdr(skb)->h_proto == if ((bitmask & EBT_LOG_IP6) && eth_hdr(skb)->h_proto ==
htons(ETH_P_IPV6)) { htons(ETH_P_IPV6)) {
const struct ipv6hdr *ih; const struct ipv6hdr *ih;
...@@ -146,6 +147,7 @@ ebt_log_packet(unsigned int pf, unsigned int hooknum, ...@@ -146,6 +147,7 @@ ebt_log_packet(unsigned int pf, unsigned int hooknum,
print_ports(skb, nexthdr, offset_ph); print_ports(skb, nexthdr, offset_ph);
goto out; goto out;
} }
#endif
if ((bitmask & EBT_LOG_ARP) && if ((bitmask & EBT_LOG_ARP) &&
((eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) || ((eth_hdr(skb)->h_proto == htons(ETH_P_ARP)) ||
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment