Re: [PATCH xserver] modesetting: resubmit dirty rects on EINVAL (v2)
On Tue, 2016-07-19 at 10:58 +0200, Michael Thayer wrote: > Thanks! What are the chances of this getting back-ported to 1.17 and > 1.18? That rather increases the chances that distributions will adopt > the fix and that I will not have to write a nasty work-around in my > kernel driver. Backported to 1.18.4. AFAIK nobody's working on a 1.17.5. - ajax ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH xserver] modesetting: resubmit dirty rects on EINVAL (v2)
On 18.07.2016 22:37, Adam Jackson wrote: On Mon, 2016-07-18 at 12:46 -0400, Adam Jackson wrote: This error code can mean we're submitting more rects at once than the driver can handle. If that happens, resubmit one at a time. v2: Make the rect submit loop more error-proof (Walter Harms) Signed-off-by: Adam JacksonReviewed-by: Michael Thayer Went ahead and merged this: remote: I: patch #99393 updated using rev 4b311d23e84356bd0e9e736aeed7448dd6382118. remote: I: 1 patch(es) updated to state Accepted. To ssh://git.freedesktop.org/git/xorg/xserver 8d3a368..4b311d2 master -> master Thanks! What are the chances of this getting back-ported to 1.17 and 1.18? That rather increases the chances that distributions will adopt the fix and that I will not have to write a nasty work-around in my kernel driver. - ajax -- Michael Thayer | VirtualBox engineer ORACLE Deutschland B.V. & Co. KG | Werkstr. 24 | D-71384 Weinstadt ORACLE Deutschland B.V. & Co. KG Hauptverwaltung: Riesstraße 25, D-80992 München Registergericht: Amtsgericht München, HRA 95603 Komplementärin: ORACLE Deutschland Verwaltung B.V. Hertogswetering 163/167, 3543 AS Utrecht, Niederlande Handelsregister der Handelskammer Midden-Nederland, Nr. 30143697 Geschäftsführer: Alexander van der Ven, Jan Schultheiss, Val Maher ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH xserver] modesetting: resubmit dirty rects on EINVAL (v2)
On Mon, 2016-07-18 at 12:46 -0400, Adam Jackson wrote: > This error code can mean we're submitting more rects at once than the > driver can handle. If that happens, resubmit one at a time. > > v2: Make the rect submit loop more error-proof (Walter Harms) > > Signed-off-by: Adam Jackson> Reviewed-by: Michael Thayer Went ahead and merged this: remote: I: patch #99393 updated using rev 4b311d23e84356bd0e9e736aeed7448dd6382118. remote: I: 1 patch(es) updated to state Accepted. To ssh://git.freedesktop.org/git/xorg/xserver 8d3a368..4b311d2 master -> master - ajax ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
[PATCH xserver] modesetting: resubmit dirty rects on EINVAL (v2)
This error code can mean we're submitting more rects at once than the driver can handle. If that happens, resubmit one at a time. v2: Make the rect submit loop more error-proof (Walter Harms) Signed-off-by: Adam JacksonReviewed-by: Michael Thayer --- hw/xfree86/drivers/modesetting/driver.c | 9 + 1 file changed, 9 insertions(+) diff --git a/hw/xfree86/drivers/modesetting/driver.c b/hw/xfree86/drivers/modesetting/driver.c index 262a899..2cf3cee 100644 --- a/hw/xfree86/drivers/modesetting/driver.c +++ b/hw/xfree86/drivers/modesetting/driver.c @@ -515,6 +515,15 @@ dispatch_dirty_region(ScrnInfoPtr scrn, /* TODO query connector property to see if this is needed */ ret = drmModeDirtyFB(ms->fd, fb_id, clip, num_cliprects); + +/* if we're swamping it with work, try one at a time */ +if (ret == -EINVAL) { +for (i = 0; i < num_cliprects; i++) { +if ((ret = drmModeDirtyFB(ms->fd, fb_id, [i], 1)) < 0) +break; +} +} + free(clip); DamageEmpty(damage); } -- 2.7.4 ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel