Displaying 20 results from an estimated 32 matches for "br_handle_frame".
2007 Apr 18
1
[Bridge] Information needed about bridge c code
..., i need to know the original src and dst mac addresses
of the packet incoming to the bridge. As i work on a brouter (some
packets are bridged, some are routed based on ebtable rules), packets
that are routed have their mac addresses modified by the IP stack).
I put a software probe in br_input.c::br_handle_frame( ), but there,
the dst mac address is already replaced by the bridge local mac
address.
My question is: where must i put the probe to get the original src and
dst mac addresses? At the driver level? In the bridge, but where?
Thx in advance.
PS: please CC to louis.croisezATgmail.com, because i am...
2007 Nov 27
1
[PATCH][BRIDGE] Properly dereference the br_should_route_hook
...ned-off-by: Pavel Emelyanov <xemul@openvz.org>
---
diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c
index 3cedd4e..b42b192 100644
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
@@ -122,6 +122,7 @@ static inline int is_link_local(const unsigned char *dest)
struct sk_buff *br_handle_frame(struct net_bridge_port *p, struct sk_buff *skb)
{
const unsigned char *dest = eth_hdr(skb)->h_dest;
+ typeof(br_should_route_hook) rhook;
if (!is_valid_ether_addr(eth_hdr(skb)->h_source))
goto drop;
@@ -147,9 +148,9 @@ struct sk_buff *br_handle_frame(struct net_bridge_port *p, struc...
2014 Mar 30
2
what is the driver of vm's virtual ethernet?
hi,all
each port of bridge, has its packets process function called br_handle_frame.
i want to know before this function called who and how it get the packets?
if it is a real physical ethernet, it must be its driver, but for virtual ethernet , what is the driver?
thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfo...
2014 Mar 30
2
what is the driver of vm's virtual ethernet?
hi,all
each port of bridge, has its packets process function called br_handle_frame.
i want to know before this function called who and how it get the packets?
if it is a real physical ethernet, it must be its driver, but for virtual ethernet , what is the driver?
thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfo...
2014 Mar 30
2
what is the driver of vm's virtual ethernet?
hi,all
each port of bridge, has its packets process function called br_handle_frame.
i want to know before this function called who and how it get the packets?
if it is a real physical ethernet, it must be its driver, but for virtual ethernet , what is the driver?
thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfo...
2007 Apr 18
1
[Bridge] BPDU's not passing through bridge when STP is disabled
...change in the linux bridge implementation between
2.1.15 and 2.1.17. Specifically, I do not think BPDU's (generated from
another bridge) are passed across the bridge when STP is disabled. I
think this relates to the LLC handling of BPDU's directly invoking
br_bpdu_rcv.
In 2.6.15, the br_handle_frame function would pass a BPDU to the
br_handle_frame_finish function which would transmit it across the
bridge. But in 2.6.17, the br_bpdu_rcv function is invoked directly by
the LLC layer, which does nothing if stp is disabled.
Was this change intentional? The reason I ask is that I can introdu...
2007 Apr 18
1
[Bridge] Lost TCP packet
...tup:
PC1 (10.0.0.1) ===== BR1 --------- BR2 ===== PC2 (10.0.0.10)
After analysis, i determined that these packets were lost because one
of the two bridges was in BR_STATE_DISABLED state when the lost packet
arrived.
In fact, the packet is thrown by the bridge because, in
br_input.c::br_handle_frame(), state==BR_STATE_DISABLED which force
the code to jump to the err: tag at the end of this function.
The state is set to this value while an event is received inside
br_notify.c::br_device_event(), which do a br_stp_disable_port().
After putting some printk in br_notify.c, i remarked that this eve...
2011 Dec 22
8
[Bug 765] New: Netfilter crash on bridged/TAP device on 2.6.38 & 3.0 kernels
...erate+0x85/0xc0
[ 5445.400827] [<ffffffffa038ffd0>] ? br_handle_local_finish+0x50/0x50
[bridge]
[ 5445.408643] [<ffffffff81516686>] nf_hook_slow+0x76/0x130
[ 5445.416438] [<ffffffffa038ffd0>] ? br_hanlde_local_finish+0x50/0x50
[bridge]
[ 5445.424202] [<ffffffffa0390424>] br_handle_frame+0x1b4/0x260 [bridge]
[ 5445.431824] [<ffffffffa0390270>] ? br_hanlde_frame_finish+0x2a0/0x2a0
[bridge]
[ 5445.446876] [<ffffffff814e9b8d>] __netif_receive_skb+0x17d/0x540
[ 5445.454815] [<ffffffff814ea191>] process_backlog+0xb1/0x190
[ 5445.462790] [<ffffffff814eb2f4>] n...
2018 Jan 10
1
soft lockup after set multicast_router of bridge and it's port to 2
...200286c042
<d> ffff88202ae7c6e0 ffff882002b9ceb8 ffff88013bc03950 ffffffffa04f36d5
Call Trace:
<IRQ>
[<ffffffffa04f3930>] ? __br_forward+0x0/0xd0 [bridge]
[<ffffffffa04f36d5>] ? br_multicast_forward+0x15/0x20 [bridge]
[<ffffffffa04f4a34>] ? br_handle_frame_finish+0x144/0x2a0 [bridge]
[<ffffffffa04fa938>] ? br_nf_pre_routing_finish+0x238/0x350 [bridge]
[<ffffffffa04faedb>] ? br_nf_pre_routing+0x48b/0x7b0 [bridge]
[<ffffffff8143ba57>] ? __kfree_skb+0x47/0xa0
[<ffffffff814734f9>] ? nf_iterate+0x69/0xb0
[&...
2006 Feb 09
0
Repeated kernel "oops" / oom-killer with Ralph Passgang''s xen 3.0.0 Debian packages
...ard_finish+0xb8/0x140 [bridge]
[<c0144611>] kmem_getpages+0x31/0xa0
[<c9167d70>] br_forward_finish+0x0/0x70 [bridge]
[<c014537e>] cache_grow+0x9e/0x190
[<c01455bd>] cache_alloc_refill+0x14d/0x220
[<c9167d70>] br_forward_finish+0x0/0x70 [bridge]
[<c9168a30>] br_handle_frame_finish+0x0/0x130 [bridge]
[<c0145899>] kmem_cache_alloc+0x69/0x70
[<c916d132>] br_nf_pre_routing+0x1b2/0x480 [bridge]
[<c9168990>] br_pass_frame_up_finish+0x0/0x20 [bridge]
[<c029631e>] nf_hook_slow+0x6e/0x100
[<c0296018>] nf_iterate+0x78/0x90
[<c9168a30>]...
2006 Jun 26
5
[Bug 339] Kernel panic on bridged packet
...f_pre_routing_finish+0x0/0x2c0
[<c0359b4d>] br_nf_pre_routing_finish+0x0/0x2c0
[<c030d562>] nf_iterate+0x3f/0x6d
[<c0359b4d>] br_nf_pre_routing_finish+0x0/0x2c0
[<c030d5d7>] nf_hook_slow+0x47/0xba
[<c0359b4d>] br_nf_pre_routing_finish+0x0/0x2c0
[<c035685b>] br_handle_frame_finish+0x0/0xca
[<c035a446>] br_nf_pre_routing+0x35d/0x37a
[<c035685b>] br_handle_frame_finish+0x0/0xca
[<c035a454>] br_nf_pre_routing+0x36b/0x37a
[<c030d562>] nf_iterate+0x3f/0x6d
[<c035685b>] br_handle_frame_finish+0x0/0xca
[<c030d5d7>] nf_hook_slow+0x47/...
2023 May 19
2
[Bridge] [PATCH net-next 1/5] skbuff: bridge: Add layer 2 miss indication
...:
> On 18/05/2023 14:33, Ido Schimmel wrote:
> > diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c
> > index fc17b9fd93e6..d8ab5890cbe6 100644
> > --- a/net/bridge/br_input.c
> > +++ b/net/bridge/br_input.c
> > @@ -334,6 +334,7 @@ static rx_handler_result_t br_handle_frame(struct sk_buff **pskb)
> > return RX_HANDLER_CONSUMED;
> >
> > memset(skb->cb, 0, sizeof(struct br_input_skb_cb));
> > + skb->l2_miss = 0;
> >
> > p = br_port_get_rcu(skb->dev);
> > if (p->flags & BR_VLAN_TUNNEL)
>
> Over...
2007 Aug 23
3
[Bridge] bridge problem when one interface is in blocking mode
...the box try
to using wifi to send the packages which is in
blocking mode. This happens because the ath0 is
returned from the forwarding database. It's
implemented in __br_fdb_get(br, dest).
>From the etherreal, I noticed, that the STP package is
broadcast from the box 2. From the function
br_handle_frame(), if a stp package is received, it
will update the forwarding database. Since the STP
package is sent/received by both interfaces, the wifi
(blocking) received the package and update the
forwarding database too. So, __br_fdb_get() will
returns the wifi card sometimes. And then, the package
is lost...
2007 Apr 18
4
[Bridge] MTU Question
I have a bridge that has gigabit interfaces. The machine in question has the
fun job of being a Bridge, Firewall and SMB server. Both of the Gigabit
interfaces are connected to workstations directly via Xover cable (well
MDI-X to be exact). My question is, if I enable jumbo frames on the gigabit
interfaces will that make any difference in overall transfer rate of the
bridge? I was thinking it
2007 Apr 18
0
[Bridge] [PATCH] (4/6) bridge: prevent bad forwarding table updates
...ge, a small but possible security
risk.
Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
Index: bridge/net/bridge/br_input.c
===================================================================
--- bridge.orig/net/bridge/br_input.c
+++ bridge/net/bridge/br_input.c
@@ -54,6 +54,9 @@ int br_handle_frame_finish(struct sk_buf
struct net_bridge_fdb_entry *dst;
int passedup = 0;
+ /* insert into forwarding database after filtering to avoid spoofing */
+ br_fdb_update(p->br, p, eth_hdr(skb)->h_source);
+
if (br->dev->flags & IFF_PROMISC) {
struct sk_buff *skb2;
@@ -108,8 +1...
2007 Apr 18
1
[Bridge] [PATCH 2.4] bridge - eliminate br_ioctl_mutex
..._clear_ioctl_hook(void)
-{
- br_ioctl_hook = NULL;
-}
-
static void __exit br_deinit(void)
{
unregister_netdevice_notifier(&br_device_notifier);
- br_call_ioctl_atomic(__br_clear_ioctl_hook);
+
+ rtnl_lock();
+ br_ioctl_hook = NULL;
+ rtnl_unlock();
br_write_lock_bh(BR_NETPROTO_LOCK);
br_handle_frame_hook = NULL;
diff -Nru a/net/bridge/br_ioctl.c b/net/bridge/br_ioctl.c
--- a/net/bridge/br_ioctl.c 2004-06-21 07:46:49 -07:00
+++ b/net/bridge/br_ioctl.c 2004-06-21 07:46:49 -07:00
@@ -16,6 +16,7 @@
#include <linux/kernel.h>
#include <linux/if_bridge.h>
#include <linux/inetdevice....
2006 Jan 26
0
Profiling hotspots in my tc filter ruleset
...setup_pre_routing
1417 bridge.ko br_fdb_cleanup
1425 sky2.ko sky2_put_idx
1766 ipt_physdev.ko .text
2113 bridge.ko br_nf_pre_routing_finish
2133 bridge.ko br_nf_forward_ip
2314 bridge.ko br_handle_frame_finish
2454 bridge.ko br_dev_queue_push_xmit
2515 bridge.ko ip_sabotage_out
2718 sky2.ko sky2_rx_add
2858 sch_htb.ko htb_enqueue
3983 bridge.ko br_handle_frame
4796 bridge.ko br_nf_pre...
2007 Apr 18
0
[Bridge] Bridge kernel panic
..._pre_routing_finish+0x0/0x34e
[<c0302017>] nf_iterate+0x6f/0x87
[<c035d274>] br_nf_pre_routing_finish+0x0/0x34e
[<c035d274>] br_nf_pre_routing_finish+0x0/0x34e
[<c030209a>] nf_hook_slow+0x6b/0x102
[<c035d274>] br_nf_pre_routing_finish+0x0/0x34e
[<c035958e>] br_handle_frame_finish+0x0/0x109
[<c035db86>] br_nf_pre_routing+0x276/0x449
[<c035d274>] br_nf_pre_routing_finish+0x0/0x34e
[<c0302017>] nf_iterate+0x6f/0x87
[<c035958e>] br_handle_frame_finish+0x0/0x109
[<c035958e>] br_handle_frame_finish+0x0/0x109
[<c030209a>] nf_hook_sl...
2007 Apr 18
3
[Bridge] [2.6 patch] fix bridge <-> ATM compile error
...include "br_private.h"
-#if defined(CONFIG_ATM_LANE) || defined(CONFIG_ATM_LANE_MODULE)
+#if defined(CONFIG_ATM_LANE) || (defined(CONFIG_ATM_LANE_MODULE) && defined(MODULE))
#include "../atm/lec.h"
#endif
@@ -39,7 +39,7 @@
brioctl_set(br_ioctl_deviceless_stub);
br_handle_frame_hook = br_handle_frame;
-#if defined(CONFIG_ATM_LANE) || defined(CONFIG_ATM_LANE_MODULE)
+#if defined(CONFIG_ATM_LANE) || (defined(CONFIG_ATM_LANE_MODULE) && defined(MODULE))
br_fdb_get_hook = br_fdb_get;
br_fdb_put_hook = br_fdb_put;
#endif
@@ -60,7 +60,7 @@
synchronize_net();...
2013 Jun 25
2
[PATCHv2] vhost-net: fix use-after-free in vhost_net_flush
vhost_net_ubuf_put_and_wait has a confusing name:
it will actually also free it's argument.
Thus since commit 1280c27f8e29acf4af2da914e80ec27c3dbd5c01
"vhost-net: flush outstanding DMAs on memory change"
vhost_net_flush tries to use the argument after passing it
to vhost_net_ubuf_put_and_wait, this results
in use after free.
To fix, don't free the argument in