-1

I am trying to implement a custom network device driver on linux kernel version 4.0 and 3.16.

and it is working well on link. however, I found out the device has some problem about the forwarding recently.

  (device 1)                 (gateway)            (device 2)

[ custom netdevice ] - [ custom netdevice' + eth0' ] - [ eth0 ]

I performed a ping test. the followings are results.

1st ping test(from device 2 to device 1)

The ping request message arrives at the device 1. The ping response message arrives at the gateway.

but the response message does not arrive at the device 2.

2nd ping test(from device 1 to device 2)

The ping request message arrives at the gateway.

but the ping request message does not arrive at the device 1.

the device driver is implemented without arp tables. eth0' netdevice seemed to receive the packets. eth0' netdevice's RX counter increases, while TX counter does not increase.

I saw the packets were delivered to IP layer well at the gateways. I used the command "sysctl -w net.ipv6.conf.all.forwarding=1" for the gateway. and utilzed radvd daemon to do stateless auto-configuration. the firewall at the gateway was disabled as using the command "ufw disable". this problem occured only in case of using my custom network driver, this symptom seemed to be not the problem regarding eth1 netdevice. Please Help me

  • a) are you using only ipv6? if yes, then try it with ipv4 as well. b) try pinging from the gateway, and to the gateway as well (both addresses of the gw from both devices). c) if your device is not using arp, then how is it supposed to the handle neighbor discovery? is it a point-to-point device? or are you entering neighbor addresses manually into the arp table? – Laszlo Valko Sep 25 '15 at 2:18
  • a) only ipv6 b) rest parts are working well ( for example, to gateway or to the devices if the path is on-link) . c) using radvd daemon. it is p2p device that does not go via intermediate devices such as an access point . Did this point cause to the problem??. d) I did try to assign next hop address using command "route -A inet6 add gw [next hop] dev [net device']". however, it was of no use. – RDDSAD Sep 25 '15 at 5:27
0

This problem is solved. Sorry to ask the ambiguous question. The custom driver sends IP packets using mac broadcasting. I changed this part to mac unicast, and finally the problem is solved.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.