ethernet device xmit function is not gettting called
Quoted 6 lines · On Mon, 28 Jun 2004 20:21:59 +0530 (IST) <[email protected]> wrote:
Hi,
I wrote a module to create dummy ethernet device, the intention is to
add it to a bridge and transmit modified packets. I get ethernet device created but its xmit function is not called when the bridge receives a packet.
The interface has to go through the Spanning Tree Protocol (STP) initialization process to get into the forwarding state which takes a while
(and it has to be marked up). Use 'brctl showstp br0' to see.
Quoted 5 lines
I feel I have missed some information to register netdevice.
To add to bridge I did the following:
brctl addbr br0
brctl addif bro eth0
Typo, I assume you mean br0
Quoted 2 lines
brctl addif br0 firsteth0
ifconfig etho 0.0.0.0
Another typo. eth0
Quoted 3 lines
ifconfig bro 172.16.2.100 up
When I try to add IP address to firsteth0, I get a kernel panic!!
Well since bridging is at the link, not network layer you shouldn't do that. If it panic's send the console log (backtrace) and it will get fixed.
Quoted 1 line
Can we give IP to dummy ethernet device?
No, bridging is at layer 2 not layer 3. See the FAQ at http://bridge.sourceforge.net
Quoted 3 lines
Please help, I am given little time to complete this :( I am attaching the code for the dummy ethernet device.
How is this different from the existing dummy device which works fine in a bridge?