summaryrefslogtreecommitdiff
path: root/src/sna/sna_display.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2012-05-06 17:23:11 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2012-05-06 21:55:04 +0100
commit2c801c45dbad58d18f2673e17723825dda0c4e55 (patch)
tree0e03a80e169e2e524bd5c5751ab71551acb56bcd /src/sna/sna_display.c
parent74d2707de4a0f94d2143f1e9c60762e4167b1ea6 (diff)
sna: Replace timerfd with OsTimer
As timerfd is linux-specific, and OsTimer an OS-agnostic abraction, replace the former with the later. Arguably this has slightly better performance characteristics in select-bound loops. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna_display.c')
-rw-r--r--src/sna/sna_display.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sna/sna_display.c b/src/sna/sna_display.c
index 6287cd9d..65d1992f 100644
--- a/src/sna/sna_display.c
+++ b/src/sna/sna_display.c
@@ -643,8 +643,8 @@ static void update_flush_interval(struct sna *sna)
if (max_vrefresh == 0)
max_vrefresh = 40;
- sna->vblank_interval = 1000 * 1000 * 1000 / max_vrefresh; /* Hz -> ns */
- DBG(("max_vrefresh=%d, vblank_interval=%d ns\n",
+ sna->vblank_interval = 1000 / max_vrefresh; /* Hz -> ms */
+ DBG(("max_vrefresh=%d, vblank_interval=%d ms\n",
max_vrefresh, sna->vblank_interval));
}