Jiri Benc 2d79849903 lwtunnel: ip tunnel: fix multiple routes with different encap
Currently, two routes going through the same tunnel interface are considered
the same even when they are routed to a different host after encapsulation.
This causes all routes added after the first one to have incorrect
encapsulation parameters.

This is nicely visible by doing:

  # ip r a 192.168.1.2/32 dev vxlan0 tunnel dst 10.0.0.2
  # ip r a 192.168.1.3/32 dev vxlan0 tunnel dst 10.0.0.3
  # ip r
  [...]
  192.168.1.2/32 tunnel id 0 src 0.0.0.0 dst 10.0.0.2 [...]
  192.168.1.3/32 tunnel id 0 src 0.0.0.0 dst 10.0.0.2 [...]

Implement the missing comparison function.

Fixes: 3093fbe7ff4bc ("route: Per route IP tunnel metadata via lightweight tunnel")
Signed-off-by: Jiri Benc <jbenc@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-08-18 19:11:20 -07:00
..
2014-09-18 10:54:36 +02:00
2015-08-13 22:43:21 -07:00
2015-05-28 11:23:20 +08:00
2015-08-18 19:11:19 -07:00
2015-08-13 22:43:21 -07:00
2015-07-21 10:39:05 -07:00
2015-06-11 00:09:12 -07:00
2015-06-11 00:09:12 -07:00
2015-07-09 21:09:10 -07:00
2015-08-17 21:33:05 -07:00
2015-07-09 14:22:52 -07:00
2015-07-09 14:22:52 -07:00
2015-07-09 14:22:52 -07:00
2014-09-01 18:12:45 -07:00
2015-07-09 14:22:52 -07:00
2015-07-09 14:22:52 -07:00
2015-01-28 22:18:37 -08:00
2015-08-13 22:43:20 -07:00
2015-08-11 12:41:35 +02:00