Date: Thu, 24 Oct 2013 22:58:47 +0200 From: =?ISO-8859-1?Q?Jan_Kokem=FCller?= <jan.kokemueller@gmail.com> To: freebsd-x11@freebsd.org Subject: Re: Slow window movement and refresh after suspend/resume Message-ID: <CAMog33o8L5Pp9NGzC4HVaZEbTAa7NPaYjxoM=aN=Aqo-gPrbNQ@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hi, > Looking at my Xorg log, this is all I can really see out of the ordinary > during the suspend/resume process: I have the same issue (i915kms, Intel g45). I have worked around it with a really ugly hack that simply retries sending the batch buffer while X resumes. Place the following into /usr/ports/x11-drivers/xf86-video-intel/files/patch-src__uxa__intel_batchbuffer.c and rebuild xf86-video-intel. --- ./src/uxa/intel_batchbuffer.c.orig 2013-07-28 15:53:23.000000000 +0200 +++ ./src/uxa/intel_batchbuffer.c 2013-09-10 12:47:45.563838120 +0200 @@ -219,6 +219,8 @@ intel_batch_do_flush(scrn); } +#include <unistd.h> + void intel_batch_submit(ScrnInfoPtr scrn) { intel_screen_private *intel = intel_get_screen_private(scrn); @@ -251,13 +253,21 @@ } ret = dri_bo_subdata(intel->batch_bo, 0, intel->batch_used*4, intel->batch_ptr); + int tries = 200; if (ret == 0) { + retry: ret = drm_intel_bo_mrb_exec(intel->batch_bo, intel->batch_used*4, NULL, 0, 0xffffffff, (HAS_BLT(intel) ? intel->current_batch: I915_EXEC_DEFAULT)); + if (ret && tries) { + xf86DrvMsg(scrn->scrnIndex, X_WARNING, "retrying batchbuffer submit\n"); + --tries; + usleep(50 * 1000); + goto retry; + } } if (ret != 0) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAMog33o8L5Pp9NGzC4HVaZEbTAa7NPaYjxoM=aN=Aqo-gPrbNQ>