* [BUG] Cursor code broken
@ 2014-04-09 6:16 Knut Petersen
2014-04-09 13:37 ` Daniel Vetter
0 siblings, 1 reply; 5+ messages in thread
From: Knut Petersen @ 2014-04-09 6:16 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
Hi Chris!
The intel xorg driver cursor code is broken, at least on my system.
The last good commit is 3810cff42bca1badc5844002694a6f582c0f423.
Hardware: AOpen i915GMm-hfs with Pentium-M Dothan cpu
Software: openSuSE 13.1, kernel 3.14, xorg git master, kde
Expected behavior:
===============
If the mouse cursor hits a window border, it changes it appearance and stays at the same location. If the left mouse button
is depressed the window might be resized.
Current behavior:
=============
The mouse cursor hits a window border, it does not change its appearance and is relocated a few pixels instead. If the mouse
cursor is moved a bit further there is a second unexpected relocation to the opposite direction. This new behavior of the mouse cursor has been
implemented for both axes. Resizing is impossible as the mouse cursor cannot be put exactly on the window border.
After I realized that the intel driver is the cause of the problem, I bisected. During bisecting I realized that there are two cursor problems after 3810cff42, the one described above that is still present in current git HEAD and a problem with a totally distorted cursor image that already has been
solved. In the bisect log below "good" means "cursor handling completely ok", "bad" means "one or both of the cursor problems present".
git bisect start
# good: [220accd828c5a0054ae9e3b491a434f7a6c750e0] sna: Only enable cursor support if the hw cursor is supported
git bisect good 220accd828c5a0054ae9e3b491a434f7a6c750e0
# bad: [3310ee89c1f1a663de5f5b12b8125809a213996f] sna: Avoid discarding damage when applying WHOLE hint to pixmap migration
git bisect bad 3310ee89c1f1a663de5f5b12b8125809a213996f
# bad: [80792a3f490578735065d9f67ca6ebac00b5bb75] sna: Our cursors are always square.
git bisect bad 80792a3f490578735065d9f67ca6ebac00b5bb75
# good: [e3810cff42bca1badc5844002694a6f582c0f423] sna: Move cursor reload into crtc notify
git bisect good e3810cff42bca1badc5844002694a6f582c0f423
# bad: [e07f8e2e625fb34f9ad795ca8fffc9a9e88e25b2] sna: Fix 2-color to ARGB cursor conversion
git bisect bad e07f8e2e625fb34f9ad795ca8fffc9a9e88e25b2
# bad: [e8be2a438d7a413ba6c64005971ce814b0076fc7] sna: Clear the surrounding areas of small cursors
git bisect bad e8be2a438d7a413ba6c64005971ce814b0076fc7
# bad: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
git bisect bad 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
# first bad commit: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
# bad: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
git bisect bad 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
# first bad commit: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
# bad: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
git bisect bad 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
# first bad commit: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
cu,
Knut
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [BUG] Cursor code broken
2014-04-09 6:16 [BUG] Cursor code broken Knut Petersen
@ 2014-04-09 13:37 ` Daniel Vetter
2014-04-09 14:59 ` Chris Wilson
0 siblings, 1 reply; 5+ messages in thread
From: Daniel Vetter @ 2014-04-09 13:37 UTC (permalink / raw)
To: Knut Petersen; +Cc: intel-gfx
On Wed, Apr 09, 2014 at 08:16:30AM +0200, Knut Petersen wrote:
> Hi Chris!
>
> The intel xorg driver cursor code is broken, at least on my system.
> The last good commit is 3810cff42bca1badc5844002694a6f582c0f423.
Hm, you mean
commit 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Thu Mar 27 14:15:30 2014 +0000
sna: Support variable sized cursors
Iirc Chris already fixed this in latest git.
-Daniel
>
> Hardware: AOpen i915GMm-hfs with Pentium-M Dothan cpu
> Software: openSuSE 13.1, kernel 3.14, xorg git master, kde
>
> Expected behavior:
> ===============
>
> If the mouse cursor hits a window border, it changes it appearance and stays at the same location. If the left mouse button
> is depressed the window might be resized.
>
> Current behavior:
> =============
>
> The mouse cursor hits a window border, it does not change its appearance and is relocated a few pixels instead. If the mouse
> cursor is moved a bit further there is a second unexpected relocation to the opposite direction. This new behavior of the mouse cursor has been
> implemented for both axes. Resizing is impossible as the mouse cursor cannot be put exactly on the window border.
>
> After I realized that the intel driver is the cause of the problem,
> I bisected. During bisecting I realized that there are two cursor
> problems after 3810cff42, the one described above that is still
> present in current git HEAD and a problem with a totally distorted
> cursor image that already has been solved. In the bisect log below
> "good" means "cursor handling completely ok", "bad" means "one or
> both of the cursor problems present".
>
> git bisect start
> # good: [220accd828c5a0054ae9e3b491a434f7a6c750e0] sna: Only enable cursor support if the hw cursor is supported
> git bisect good 220accd828c5a0054ae9e3b491a434f7a6c750e0
> # bad: [3310ee89c1f1a663de5f5b12b8125809a213996f] sna: Avoid discarding damage when applying WHOLE hint to pixmap migration
> git bisect bad 3310ee89c1f1a663de5f5b12b8125809a213996f
> # bad: [80792a3f490578735065d9f67ca6ebac00b5bb75] sna: Our cursors are always square.
> git bisect bad 80792a3f490578735065d9f67ca6ebac00b5bb75
> # good: [e3810cff42bca1badc5844002694a6f582c0f423] sna: Move cursor reload into crtc notify
> git bisect good e3810cff42bca1badc5844002694a6f582c0f423
> # bad: [e07f8e2e625fb34f9ad795ca8fffc9a9e88e25b2] sna: Fix 2-color to ARGB cursor conversion
> git bisect bad e07f8e2e625fb34f9ad795ca8fffc9a9e88e25b2
> # bad: [e8be2a438d7a413ba6c64005971ce814b0076fc7] sna: Clear the surrounding areas of small cursors
> git bisect bad e8be2a438d7a413ba6c64005971ce814b0076fc7
> # bad: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
> git bisect bad 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
> # first bad commit: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
> # bad: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
> git bisect bad 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
> # first bad commit: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
> # bad: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
> git bisect bad 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
> # first bad commit: [25ca8f136cef9e1bdf06967bf8e78c87b54ffce2] sna: Support variable sized cursors
>
> cu,
> Knut
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [BUG] Cursor code broken
2014-04-09 13:37 ` Daniel Vetter
@ 2014-04-09 14:59 ` Chris Wilson
2014-04-09 15:19 ` Chris Wilson
0 siblings, 1 reply; 5+ messages in thread
From: Chris Wilson @ 2014-04-09 14:59 UTC (permalink / raw)
To: Daniel Vetter; +Cc: intel-gfx
On Wed, Apr 09, 2014 at 03:37:35PM +0200, Daniel Vetter wrote:
> On Wed, Apr 09, 2014 at 08:16:30AM +0200, Knut Petersen wrote:
> > Hi Chris!
> >
> > The intel xorg driver cursor code is broken, at least on my system.
> > The last good commit is 3810cff42bca1badc5844002694a6f582c0f423.
>
> Hm, you mean
>
> commit 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
> Author: Chris Wilson <chris@chris-wilson.co.uk>
> Date: Thu Mar 27 14:15:30 2014 +0000
>
> sna: Support variable sized cursors
>
> Iirc Chris already fixed this in latest git.
Ah, no. This is a phys cursor artifact. Special hardware, extra special
code.
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [BUG] Cursor code broken
2014-04-09 14:59 ` Chris Wilson
@ 2014-04-09 15:19 ` Chris Wilson
2014-04-09 17:02 ` Knut Petersen
0 siblings, 1 reply; 5+ messages in thread
From: Chris Wilson @ 2014-04-09 15:19 UTC (permalink / raw)
To: Daniel Vetter, Knut Petersen, intel-gfx
On Wed, Apr 09, 2014 at 03:59:29PM +0100, Chris Wilson wrote:
> On Wed, Apr 09, 2014 at 03:37:35PM +0200, Daniel Vetter wrote:
> > On Wed, Apr 09, 2014 at 08:16:30AM +0200, Knut Petersen wrote:
> > > Hi Chris!
> > >
> > > The intel xorg driver cursor code is broken, at least on my system.
> > > The last good commit is 3810cff42bca1badc5844002694a6f582c0f423.
> >
> > Hm, you mean
> >
> > commit 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
> > Author: Chris Wilson <chris@chris-wilson.co.uk>
> > Date: Thu Mar 27 14:15:30 2014 +0000
> >
> > sna: Support variable sized cursors
> >
> > Iirc Chris already fixed this in latest git.
>
> Ah, no. This is a phys cursor artifact. Special hardware, extra special
> code.
Should be fixed with
commit dba43d370b984e262f6fe5920b38b433f4bd392b
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Apr 9 16:11:26 2014 +0100
sna: Use pwrite to update physical cursors
Older hardware uses physical addresses for its cursor, which are
implemented by the kernel in an incoherent fashion. Maybe with stolen
support this would be different...
Fixes regression on [845g, 945g] from
commit 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Thu Mar 27 14:15:30 2014 +0000
sna: Support variable sized cursors
Reported-by: Knut Petersen <Knut_Petersen@t-online.de>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
It just so happens that the older hardware I tested on (845g and pnv)
doesn't use physical cursors!
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [BUG] Cursor code broken
2014-04-09 15:19 ` Chris Wilson
@ 2014-04-09 17:02 ` Knut Petersen
0 siblings, 0 replies; 5+ messages in thread
From: Knut Petersen @ 2014-04-09 17:02 UTC (permalink / raw)
To: Chris Wilson, Daniel Vetter, intel-gfx
On 09.04.2014 17:19, Chris Wilson wrote:
> On Wed, Apr 09, 2014 at 03:59:29PM +0100, Chris Wilson wrote:
>> On Wed, Apr 09, 2014 at 03:37:35PM +0200, Daniel Vetter wrote:
>>> On Wed, Apr 09, 2014 at 08:16:30AM +0200, Knut Petersen wrote:
>>>> Hi Chris!
>>>>
>>>> The intel xorg driver cursor code is broken, at least on my system.
>>>> The last good commit is 3810cff42bca1badc5844002694a6f582c0f423.
>>> Hm, you mean
>>>
>>> commit 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
>>> Author: Chris Wilson <chris@chris-wilson.co.uk>
>>> Date: Thu Mar 27 14:15:30 2014 +0000
>>>
>>> sna: Support variable sized cursors
>>>
>>> Iirc Chris already fixed this in latest git.
>> Ah, no. This is a phys cursor artifact. Special hardware, extra special
>> code.
> Should be fixed with
>
> commit dba43d370b984e262f6fe5920b38b433f4bd392b
> Author: Chris Wilson <chris@chris-wilson.co.uk>
> Date: Wed Apr 9 16:11:26 2014 +0100
Yes indeed. Thanks!
cu,
Knut
>
> sna: Use pwrite to update physical cursors
>
> Older hardware uses physical addresses for its cursor, which are
> implemented by the kernel in an incoherent fashion. Maybe with stolen
> support this would be different...
>
> Fixes regression on [845g, 945g] from
> commit 25ca8f136cef9e1bdf06967bf8e78c87b54ffce2
> Author: Chris Wilson <chris@chris-wilson.co.uk>
> Date: Thu Mar 27 14:15:30 2014 +0000
>
> sna: Support variable sized cursors
>
> Reported-by: Knut Petersen <Knut_Petersen@t-online.de>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
>
>
> It just so happens that the older hardware I tested on (845g and pnv)
> doesn't use physical cursors!
> -Chris
>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2014-04-09 17:11 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-09 6:16 [BUG] Cursor code broken Knut Petersen
2014-04-09 13:37 ` Daniel Vetter
2014-04-09 14:59 ` Chris Wilson
2014-04-09 15:19 ` Chris Wilson
2014-04-09 17:02 ` Knut Petersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox