qxl-wddm-dod: Set VSync indication period to 200ms
Default indication period (13-17ms) from the driver to OS increases total CPU consumption during presentation operations. Reducing indication frequency to 200 ms reduces cost of this feature. Till now we do not see any negative impact of this. Signed-off-by: Yuri Benditovich <yuri.benditovich@daynix.com> Acked-by: Frediano Ziglio <fziglio@redhat.com>
This commit is contained in:
parent
074cc3ef58
commit
9460db8760
@ -19,6 +19,7 @@
|
|||||||
(QXL_INTERRUPT_CURSOR) | \
|
(QXL_INTERRUPT_CURSOR) | \
|
||||||
(QXL_INTERRUPT_IO_CMD))
|
(QXL_INTERRUPT_IO_CMD))
|
||||||
|
|
||||||
|
#define VSYNC_PERIOD 200 // ms, use 0 for auto
|
||||||
#define VSYNC_RATE 75
|
#define VSYNC_RATE 75
|
||||||
|
|
||||||
BOOLEAN g_bSupportVSync;
|
BOOLEAN g_bSupportVSync;
|
||||||
@ -5006,8 +5007,9 @@ VOID QxlDod::EnableVsync(BOOLEAN bEnable)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
LARGE_INTEGER li;
|
LARGE_INTEGER li;
|
||||||
LONG period = 1000 / VSYNC_RATE;
|
LONG period = VSYNC_PERIOD;
|
||||||
DbgPrint(TRACE_LEVEL_WARNING, ("Enabled VSync(fired %d)\n", m_VsyncFiredCounter));
|
if (!period) period = 1000 / VSYNC_RATE;
|
||||||
|
DbgPrint(TRACE_LEVEL_WARNING, ("Enabled VSync %d ms(fired %d)\n", period, m_VsyncFiredCounter));
|
||||||
li.QuadPart = -10000000 / VSYNC_RATE;
|
li.QuadPart = -10000000 / VSYNC_RATE;
|
||||||
KeSetTimerEx(&m_VsyncTimer, li, period, &m_VsyncTimerDpc);
|
KeSetTimerEx(&m_VsyncTimer, li, period, &m_VsyncTimerDpc);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user