ip6_dst_dev for IPv4
Subsystems (2)
Hi,
I'm implemeting per-interface SNMP-style network statistics for IPv4, just like what already exists in the current kernel for IPv6 (/proc/net/dev_snmp6).
For output packets one needs to determine the output interface, and the v6 statistics uses the ip6_dst_idev() function (ip6_fib.h). I can't seem to find a corresponding function for IPv4. Is there?
Would someting like:
struct in_device* out_dev = in_dev_get(skb_dst(skb)->dev); work?
Best regards,
Mattias