From edaa959f6b5100361a6af2e5c68ca6abb94bf838 Mon Sep 17 00:00:00 2001 From: Jesse Gross Date: Wed, 16 Sep 2009 11:03:42 -0700 Subject: [PATCH] netdev-linux: Set missing cache validity bit. Whether a port is internal is cached to avoid requerying the kernel every time stats are requested. However, the cache vality bit was never being set so the cache wasn't used. This corrects that oversight. Thanks to Ben Pfaff for noticing. --- lib/netdev-linux.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c index 7fde7e0a..2faffa34 100644 --- a/lib/netdev-linux.c +++ b/lib/netdev-linux.c @@ -654,6 +654,8 @@ netdev_linux_get_stats(const struct netdev *netdev_, struct netdev_stats *stats) "openvswitch"); } } + + netdev->cache->valid |= VALID_IS_INTERNAL; } if (netdev->cache->is_internal) { -- 2.30.2