Skip to content

Commit 2f46e07

Browse files
Florian Westphalummakynes
authored andcommitted
netfilter: ebtables: make broute table work again
broute table init hook sets up the "br_should_route_hook" pointer, which then gets called from br_input. commit a386f99 (bridge: add proper RCU annotation to should_route_hook) introduced a typedef, and then changed this to: br_should_route_hook_t *rhook; [..] rhook = rcu_dereference(br_should_route_hook); if (*rhook(skb)) problem is that "br_should_route_hook" contains the address of the function, so calling *rhook() results in kernel panic. Signed-off-by: Florian Westphal <[email protected]> Acked-by: Eric Dumazet <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>
1 parent 13ee6ac commit 2f46e07

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/linux/if_bridge.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ struct __fdb_entry {
103103

104104
extern void brioctl_set(int (*ioctl_hook)(struct net *, unsigned int, void __user *));
105105

106-
typedef int (*br_should_route_hook_t)(struct sk_buff *skb);
106+
typedef int br_should_route_hook_t(struct sk_buff *skb);
107107
extern br_should_route_hook_t __rcu *br_should_route_hook;
108108

109109
#endif

0 commit comments

Comments
 (0)