All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
@ 2016-02-29 14:47 Hans de Goede
  2016-03-11 10:07 ` Timo Aaltonen
  0 siblings, 1 reply; 7+ messages in thread
From: Hans de Goede @ 2016-02-29 14:47 UTC (permalink / raw)
  To: intel-gfx; +Cc: Hans de Goede, Rob Clark, Adam Jackson

sna has no meaningfull accel for gen9+, this causes problems with i.e.
apps using XVideo since the sprite XVideo support does not work well
for many apps.

Therefor it is better to just let the xserver fall back to modesetting +
glamor. This is implemented by returning FALSE from the probe methods,
just like how nouveau handles falling back to modesetting for newer cards.

BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1305369
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 src/intel_module.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/src/intel_module.c b/src/intel_module.c
index 60835b9..5979cb9 100644
--- a/src/intel_module.c
+++ b/src/intel_module.c
@@ -571,6 +571,13 @@ intel_scrn_create(DriverPtr		driver,
 			return FALSE;
 	}
 
+	/*
+	 * We've no accel support for these, so let modesetting + glamor
+	 * handle them.
+	 */
+	if ((unsigned)((struct intel_device_info *)match_data)->gen >= 0110)
+		return FALSE;
+
 	scrn = xf86AllocateScreen(driver, flags);
 	if (scrn == NULL)
 		return FALSE;
-- 
2.7.2

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
  2016-02-29 14:47 [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+ Hans de Goede
@ 2016-03-11 10:07 ` Timo Aaltonen
  2016-03-13 19:36   ` Rob Clark
  2016-04-08 13:21   ` Hans de Goede
  0 siblings, 2 replies; 7+ messages in thread
From: Timo Aaltonen @ 2016-03-11 10:07 UTC (permalink / raw)
  To: Hans de Goede, intel-gfx; +Cc: Rob Clark, Adam Jackson

29.02.2016, 16:47, Hans de Goede kirjoitti:
> sna has no meaningfull accel for gen9+, this causes problems with i.e.
> apps using XVideo since the sprite XVideo support does not work well
> for many apps.
> 
> Therefor it is better to just let the xserver fall back to modesetting +
> glamor. This is implemented by returning FALSE from the probe methods,
> just like how nouveau handles falling back to modesetting for newer cards.
> 
> BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1305369
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

I've been trying to make this work, but there are cases where it fails bad:

# a config file with a Device section that loads 'intel' makes the
server fail
[    10.153] (EE) No devices detected.
[    10.153] (EE)
Fatal server error:
[    10.153] (EE) no screens found(EE)

ie. no fallback in that case

# with X run as root (wrapper or not), same thing different cause
[   145.943] (EE) modeset(0): drmSetMaster failed: Invalid argument
[   145.943] (EE)
Fatal server error:
[   145.943] (EE) AddScreen/ScreenInit failed for driver 0


but it does work with startx run by a user. Tests done on Debian with
1.18.1 and intel ddx git.

-- 
t
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
  2016-03-11 10:07 ` Timo Aaltonen
@ 2016-03-13 19:36   ` Rob Clark
  2016-03-14  7:39     ` Hans de Goede
  2016-04-08 13:21   ` Hans de Goede
  1 sibling, 1 reply; 7+ messages in thread
From: Rob Clark @ 2016-03-13 19:36 UTC (permalink / raw)
  To: Timo Aaltonen
  Cc: Hans de Goede, Intel Graphics Development, Rob Clark, Adam Jackson

On Fri, Mar 11, 2016 at 5:07 AM, Timo Aaltonen <tjaalton@ubuntu.com> wrote:
> 29.02.2016, 16:47, Hans de Goede kirjoitti:
>> sna has no meaningfull accel for gen9+, this causes problems with i.e.
>> apps using XVideo since the sprite XVideo support does not work well
>> for many apps.
>>
>> Therefor it is better to just let the xserver fall back to modesetting +
>> glamor. This is implemented by returning FALSE from the probe methods,
>> just like how nouveau handles falling back to modesetting for newer cards.
>>
>> BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1305369
>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>
> I've been trying to make this work, but there are cases where it fails bad:
>
> # a config file with a Device section that loads 'intel' makes the
> server fail
> [    10.153] (EE) No devices detected.
> [    10.153] (EE)
> Fatal server error:
> [    10.153] (EE) no screens found(EE)

I'd be awfully tempted to call that NOTABUG.. I mean, it would fail in
same way if you had a .conf that tried to force ati ddx on a system
without a radeon card..

BR,
-R

> ie. no fallback in that case
>
> # with X run as root (wrapper or not), same thing different cause
> [   145.943] (EE) modeset(0): drmSetMaster failed: Invalid argument
> [   145.943] (EE)
> Fatal server error:
> [   145.943] (EE) AddScreen/ScreenInit failed for driver 0
>
>
> but it does work with startx run by a user. Tests done on Debian with
> 1.18.1 and intel ddx git.
>
> --
> t
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
  2016-03-13 19:36   ` Rob Clark
@ 2016-03-14  7:39     ` Hans de Goede
  0 siblings, 0 replies; 7+ messages in thread
From: Hans de Goede @ 2016-03-14  7:39 UTC (permalink / raw)
  To: Rob Clark, Timo Aaltonen
  Cc: Intel Graphics Development, Rob Clark, Adam Jackson

Hi,

On 13-03-16 20:36, Rob Clark wrote:
> On Fri, Mar 11, 2016 at 5:07 AM, Timo Aaltonen <tjaalton@ubuntu.com> wrote:
>> 29.02.2016, 16:47, Hans de Goede kirjoitti:
>>> sna has no meaningfull accel for gen9+, this causes problems with i.e.
>>> apps using XVideo since the sprite XVideo support does not work well
>>> for many apps.
>>>
>>> Therefor it is better to just let the xserver fall back to modesetting +
>>> glamor. This is implemented by returning FALSE from the probe methods,
>>> just like how nouveau handles falling back to modesetting for newer cards.
>>>
>>> BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1305369
>>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>>
>> I've been trying to make this work, but there are cases where it fails bad:
>>
>> # a config file with a Device section that loads 'intel' makes the
>> server fail
>> [    10.153] (EE) No devices detected.
>> [    10.153] (EE)
>> Fatal server error:
>> [    10.153] (EE) no screens found(EE)
>
> I'd be awfully tempted to call that NOTABUG.. I mean, it would fail in
> same way if you had a .conf that tried to force ati ddx on a system
> without a radeon card..

Ack, as for the modesetting driver only working when using the systemd-logind
integration and not when running the old way, that needs someone to look into
it.

I've put this on my todo list, but I'm not sure when I'll get around to it.

Regards,

Hans
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
  2016-03-11 10:07 ` Timo Aaltonen
  2016-03-13 19:36   ` Rob Clark
@ 2016-04-08 13:21   ` Hans de Goede
  2016-04-22 13:17     ` Timo Aaltonen
  1 sibling, 1 reply; 7+ messages in thread
From: Hans de Goede @ 2016-04-08 13:21 UTC (permalink / raw)
  To: Timo Aaltonen, intel-gfx; +Cc: Rob Clark, Adam Jackson

Hi,

On 11-03-16 11:07, Timo Aaltonen wrote:
> 29.02.2016, 16:47, Hans de Goede kirjoitti:
>> sna has no meaningfull accel for gen9+, this causes problems with i.e.
>> apps using XVideo since the sprite XVideo support does not work well
>> for many apps.
>>
>> Therefor it is better to just let the xserver fall back to modesetting +
>> glamor. This is implemented by returning FALSE from the probe methods,
>> just like how nouveau handles falling back to modesetting for newer cards.
>>
>> BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1305369
>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>
> I've been trying to make this work, but there are cases where it fails bad:
>
> # a config file with a Device section that loads 'intel' makes the
> server fail
> [    10.153] (EE) No devices detected.
> [    10.153] (EE)
> Fatal server error:
> [    10.153] (EE) no screens found(EE)
>
> ie. no fallback in that case
>
> # with X run as root (wrapper or not), same thing different cause
> [   145.943] (EE) modeset(0): drmSetMaster failed: Invalid argument
> [   145.943] (EE)
> Fatal server error:
> [   145.943] (EE) AddScreen/ScreenInit failed for driver 0
>
>
> but it does work with startx run by a user. Tests done on Debian with
> 1.18.1 and intel ddx git.

This must be some Debian specific issue, I just tried this with Xorg-1.18.3
on Fedora, with a Xwrapper.config forcing X to always run as root and it works
fine (using startx).

In that case systemd-logind integration should still work though, so it may
be that the way you are starting Xorg causes the systemd-logind integration
to not work though, and that the fallback paths for opening the /dev/drm/card#
in the modesetting driver are broken. How exactly are you starting X ?

Can you provide full logs of a failed start ?

Regards,

Hans
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
  2016-04-08 13:21   ` Hans de Goede
@ 2016-04-22 13:17     ` Timo Aaltonen
  2016-04-22 18:05       ` Hans de Goede
  0 siblings, 1 reply; 7+ messages in thread
From: Timo Aaltonen @ 2016-04-22 13:17 UTC (permalink / raw)
  To: Hans de Goede, intel-gfx; +Cc: Rob Clark, Adam Jackson

08.04.2016, 16:21, Hans de Goede kirjoitti:
> Hi,

Hi, sorry for the delay..

> On 11-03-16 11:07, Timo Aaltonen wrote:
>>
>> I've been trying to make this work, but there are cases where it fails
>> bad:
>>
>> # a config file with a Device section that loads 'intel' makes the
>> server fail
>> [    10.153] (EE) No devices detected.
>> [    10.153] (EE)
>> Fatal server error:
>> [    10.153] (EE) no screens found(EE)
>>
>> ie. no fallback in that case
>>
>> # with X run as root (wrapper or not), same thing different cause
>> [   145.943] (EE) modeset(0): drmSetMaster failed: Invalid argument
>> [   145.943] (EE)
>> Fatal server error:
>> [   145.943] (EE) AddScreen/ScreenInit failed for driver 0
>>
>>
>> but it does work with startx run by a user. Tests done on Debian with
>> 1.18.1 and intel ddx git.
> 
> This must be some Debian specific issue, I just tried this with Xorg-1.18.3
> on Fedora, with a Xwrapper.config forcing X to always run as root and it
> works
> fine (using startx).

We have a similar wrapper in 'xserver-xorg-legacy' package, but even
installing that doesn't make xdm work, the xserver fails the same way.

startx _does_ work though

> In that case systemd-logind integration should still work though, so it may
> be that the way you are starting Xorg causes the systemd-logind integration
> to not work though, and that the fallback paths for opening the
> /dev/drm/card#
> in the modesetting driver are broken. How exactly are you starting X ?

Trying to use a DM other than gdm, in this case xdm. (iirc lightdm fails
too)

> Can you provide full logs of a failed start ?

Xorg.0.log
http://paste.debian.net/440250/

xdm.log
http://paste.debian.net/440252/
(ignore the first entries with a working driver)


-- 
t
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+
  2016-04-22 13:17     ` Timo Aaltonen
@ 2016-04-22 18:05       ` Hans de Goede
  0 siblings, 0 replies; 7+ messages in thread
From: Hans de Goede @ 2016-04-22 18:05 UTC (permalink / raw)
  To: Timo Aaltonen, intel-gfx; +Cc: Rob Clark, Adam Jackson

Hi,

On 22-04-16 15:17, Timo Aaltonen wrote:
> 08.04.2016, 16:21, Hans de Goede kirjoitti:
>> Hi,
>
> Hi, sorry for the delay..
>
>> On 11-03-16 11:07, Timo Aaltonen wrote:
>>>
>>> I've been trying to make this work, but there are cases where it fails
>>> bad:
>>>
>>> # a config file with a Device section that loads 'intel' makes the
>>> server fail
>>> [    10.153] (EE) No devices detected.
>>> [    10.153] (EE)
>>> Fatal server error:
>>> [    10.153] (EE) no screens found(EE)
>>>
>>> ie. no fallback in that case
>>>
>>> # with X run as root (wrapper or not), same thing different cause
>>> [   145.943] (EE) modeset(0): drmSetMaster failed: Invalid argument
>>> [   145.943] (EE)
>>> Fatal server error:
>>> [   145.943] (EE) AddScreen/ScreenInit failed for driver 0
>>>
>>>
>>> but it does work with startx run by a user. Tests done on Debian with
>>> 1.18.1 and intel ddx git.
>>
>> This must be some Debian specific issue, I just tried this with Xorg-1.18.3
>> on Fedora, with a Xwrapper.config forcing X to always run as root and it
>> works
>> fine (using startx).
>
> We have a similar wrapper in 'xserver-xorg-legacy' package, but even
> installing that doesn't make xdm work, the xserver fails the same way.
>
> startx _does_ work though
>
>> In that case systemd-logind integration should still work though, so it may
>> be that the way you are starting Xorg causes the systemd-logind integration
>> to not work though, and that the fallback paths for opening the
>> /dev/drm/card#
>> in the modesetting driver are broken. How exactly are you starting X ?
>
> Trying to use a DM other than gdm, in this case xdm. (iirc lightdm fails
> too)
>
>> Can you provide full logs of a failed start ?
>
> Xorg.0.log
> http://paste.debian.net/440250/

Ok, I've managed to reproduce this, this is caused by a pre-existing bug in
the intel driver. I've just send out a patch fixing this.

Regards,

Hans
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-04-22 18:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-29 14:47 [RFC/PATCH xf86-video-intel] sna: Let modestting + glamor handle gen9+ Hans de Goede
2016-03-11 10:07 ` Timo Aaltonen
2016-03-13 19:36   ` Rob Clark
2016-03-14  7:39     ` Hans de Goede
2016-04-08 13:21   ` Hans de Goede
2016-04-22 13:17     ` Timo Aaltonen
2016-04-22 18:05       ` Hans de Goede

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.