aboutsummaryrefslogtreecommitdiff
path: root/ofproto/ofproto-dpif.c
diff options
context:
space:
mode:
authorAlex Wang <alexw@nicira.com>2013-09-04 15:49:19 -0700
committerEthan Jackson <ethan@nicira.com>2013-09-04 16:57:40 -0700
commit31ef9f5178dee18a40ce609aad406e925411eb06 (patch)
tree9a6934361442e8d97b0264244ec8f156e723b9db /ofproto/ofproto-dpif.c
parentc4f5d00bb76e01383ec3fbde31bc5c8f4e0a2b38 (diff)
timeval: Remove CACHE_TIME scheme.
This commit removes the CACHE_TIME scheme from timeval module. This is for eliminating the lock contention over the read/write lock of the cached time. To get the time, the thread now will directly do the system call 'clock_gettime()'. As a side effect, timer can only be warpped after timer is stopped by 'appctl time/stop' command. Signed-off-by: Alex Wang <alexw@nicira.com> Signed-off-by: Ethan Jackson <ethan@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
Diffstat (limited to 'ofproto/ofproto-dpif.c')
-rw-r--r--ofproto/ofproto-dpif.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ofproto/ofproto-dpif.c b/ofproto/ofproto-dpif.c
index c7d35736..b52d4eef 100644
--- a/ofproto/ofproto-dpif.c
+++ b/ofproto/ofproto-dpif.c
@@ -3878,7 +3878,7 @@ subfacet_max_idle(const struct dpif_backer *backer)
* pass made by update_stats(), because the former function never looks at
* uninstallable subfacets.
*/
- enum { BUCKET_WIDTH = ROUND_UP(100, TIME_UPDATE_INTERVAL) };
+ enum { BUCKET_WIDTH = 100 };
enum { N_BUCKETS = 5000 / BUCKET_WIDTH };
int buckets[N_BUCKETS] = { 0 };
int total, subtotal, bucket;