if_start() and send queue question
Tofig Suleymanov
tofig at freebsd.az
Thu Feb 7 08:13:12 PST 2008
Hello list,
I will be grateful if someone could point me to the right direction
regarding the question below.
My device driver is getting incoming packets fine, but for some reason I
am not able to send a single packet. Here is the source code:
http://www.freebsd.az/if_ib.c
I've added several debug messages to the source and here is the output:
/
/(bringing interface up and assigning the ip/netmask combination)
/
ifconfig ib0 192.168.0.6 netmask 255.255.255.0 up
/(and here is what I get in /var/log/messages /; /it seems to be a
standard arp broadcast)
/
Feb 7 19:14:32 schizo kernel: ib_init entered
Feb 7 19:14:32 schizo kernel: ib_start entered
Feb 7 19:14:32 schizo kernel: ib_encap entered
Feb 7 19:14:32 schizo kernel: DHOST ff ff ff ff ff ff
Feb 7 19:14:32 schizo kernel: SHOST 0 c0 ee 22 3 14
Feb 7 19:14:32 schizo kernel: txeof entered
Feb 7 19:14:32 schizo kernel: txeof exiting
/(now I try pinging, but no joy . I've added extra debug messages inside
ping.c)
/schizo# ping 192.168.0.1
PING 192.168.0.1 (192.168.0.1): 56 data bytes
packets sent: -1
ping: sendto: Invalid argument
packets sent: -1
ping: sendto: Invalid argument
packets sent: -1
ping: sendto: Invalid argument
^C
--- 192.168.0.1 ping statistics ---
3 packets transmitted, 0 packets received, 100% packet loss
/
I have also tied to add debug messages to sys/net/if.c and
sys/net/netisr.c and it seems that the kernel doesn't even try to run my
ib_start() function.
Any comments are appreciated.
More information about the freebsd-net
mailing list