Re: ethernet driver - problem capturing own packet in promiscous mode
From: sudheer a <hidden>
Date: 2009-07-16 04:07:55
On Wed, Jul 15, 2009 at 5:52 PM, Cote, Sylvain [off-list ref]wrote:
> Hi allquoted
In ethernet driver i need to enable promiscous mode and have to capturethe packet that is sent by the same ethernet.quoted
The board is connected to a packet generator and could send/receivepackets whenever i need .quoted
In the board ethernet driver , I made sure that am sending onlybroadcast packets and promisc mode is enabled but the packets are not captured. If i am sending a packet to the board from packetgenerator it is receiving.quoted
Could any one please suggest me any clues.quoted
Having the promisc enabled:quoted
Packet sent by packetgenerator is received by board.quoted
Packet sent by board is received by packetgenerator, The same packetshould be captured by board as promiscuous is enabled. but not happening. The Ethernet interface that sent the packet will never receive the packet it sent even if you are in promiscuous mode. To be able to do that you should put your interface in loopback mode. In promiscuous mode, you will be able to receive any packets sent by other interfaces (broadcast, multicast and also unicast that is not directed to you interface MAC address). But not from your interface.
Thanks for your inputs Sylvain. I tried with loopback, it is working. But during the time the hardware is in lopback mode, it may miss some rx packets coming from outside or packet generator unfortunately and i dont want it to happen. Please let me know your views and suggestions. Thanks Sudheer