summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcin Slusarz <marcin.slusarz@gmail.com>2013-01-21 00:15:38 +0100
committerBen Skeggs <bskeggs@redhat.com>2013-01-23 07:26:44 +1000
commit912d418fdfd2e99eef1e5c631c76dda1d82cf451 (patch)
tree5d4c96bb37ee198940626d021bf1f1f87187e70e
parent8f934fad5d4934936b3265f272ca81e73c60d7dc (diff)
downloadxorg-driver-xf86-video-nouveau-912d418fdfd2e99eef1e5c631c76dda1d82cf451.tar.gz
nouveau: put cursor BO in GART
Keeping it in VRAM wastes CPU time, because cursor_set ioctl reads handed BO back to RAM, just to write it to actual cursor BO. Here (nv92/core i7), this patch decreases overall cpu usage of drmmode_load_cursor_argb from 4.6ms to ~90us and lets nv50_crtc_cursor_set disappear from perf traces. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
-rw-r--r--src/drmmode_display.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index 429e9cc..06f7a24 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -567,7 +567,7 @@ drmmode_crtc_init(ScrnInfoPtr pScrn, drmmode_ptr drmmode, int num)
drmmode->mode_res->crtcs[num]);
drmmode_crtc->drmmode = drmmode;
- ret = nouveau_bo_new(pNv->dev, NOUVEAU_BO_VRAM | NOUVEAU_BO_MAP, 0,
+ ret = nouveau_bo_new(pNv->dev, NOUVEAU_BO_GART | NOUVEAU_BO_MAP, 0,
64*64*4, NULL, &drmmode_crtc->cursor);
assert(ret == 0);