netdev: Fall back to /proc/net/dev on kernels that don't support RTM_GETLINK.
authorBen Pfaff <blp@nicira.com>
Thu, 5 Mar 2009 23:09:00 +0000 (15:09 -0800)
committerBen Pfaff <blp@nicira.com>
Thu, 5 Mar 2009 23:09:00 +0000 (15:09 -0800)
commit382134166d901ebf8a50659da29f2f4bb4d29cb6
treed0ec5b0e90ce2a6593432282f68739901616cc31
parent7419085a13ea530c3450bcb7f60ae1a6ec5365c3
netdev: Fall back to /proc/net/dev on kernels that don't support RTM_GETLINK.

RTM_GETLINK is the best way to get network device statistics, but it was
only enabled in all kernels in 2.6.19.  So now test for support at startup
and fall back to reading /proc/net/dev if RTM_GETLINK does not work.
lib/netdev.c