.daddr = iph->daddr,
.saddr = iph->saddr,
.flowi4_tos = RT_TOS(iph->tos),
- .flowi4_oif = rt->rt_oif,
- .flowi4_iif = rt->rt_iif,
+ .flowi4_oif = (rt_is_output_route(rt) ?
+ skb->dev->ifindex : 0),
+ .flowi4_iif = (rt_is_output_route(rt) ?
+ net->loopback_dev->ifindex :
+ skb->dev->ifindex),
.flowi4_mark = skb->mark,
};
struct mr_table *mrt;
rth->rt_type = RTN_MULTICAST;
rth->rt_route_iif = dev->ifindex;
rth->rt_iif = dev->ifindex;
- rth->rt_oif = 0;
rth->rt_pmtu = 0;
rth->rt_gateway = 0;
rth->fi = NULL;
rth->rt_type = res->type;
rth->rt_route_iif = in_dev->dev->ifindex;
rth->rt_iif = in_dev->dev->ifindex;
- rth->rt_oif = 0;
rth->rt_pmtu = 0;
rth->rt_gateway = 0;
rth->fi = NULL;
rth->rt_type = res.type;
rth->rt_route_iif = dev->ifindex;
rth->rt_iif = dev->ifindex;
- rth->rt_oif = 0;
rth->rt_pmtu = 0;
rth->rt_gateway = 0;
rth->fi = NULL;
rth->rt_type = type;
rth->rt_route_iif = 0;
rth->rt_iif = orig_oif ? : dev_out->ifindex;
- rth->rt_oif = orig_oif;
rth->rt_pmtu = 0;
rth->rt_gateway = 0;
rth->fi = NULL;
rt->rt_route_iif = ort->rt_route_iif;
rt->rt_iif = ort->rt_iif;
- rt->rt_oif = ort->rt_oif;
rt->rt_pmtu = ort->rt_pmtu;
rt->rt_genid = rt_genid(net);