Using systemd-logind Session.TakeControl() from Xorg, input needed
Laércio de Sousa
lbsousajr at gmail.com
Thu Dec 12 09:39:02 PST 2013
Please consider this small change in patch after Mark Kettenis' comment:
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
index 91ec4c8..0517c16 100644
--- a/hw/xfree86/common/xf86Init.c
+++ b/hw/xfree86/common/xf86Init.c
@@ -544,7 +544,8 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char
**argv)
if (NEED_IO_ENABLED(flags))
want_hw_access = TRUE;
- if (!(flags & HW_SKIP_CONSOLE))
+ /* Non-seat0 X servers should not open console */
+ if (!((flags & HW_SKIP_CONSOLE) || ServerIsNotSeat0()))
xorgHWOpenConsole = TRUE;
}
--
1.8.1.4
CANTATE DOMINO CANTICUM NOVUM
QUIA MIRABILIA FECIT
Laércio
2013/12/12 Laércio de Sousa <lbsousajr at gmail.com>
> Done:
>
> http://lists.x.org/archives/xorg-devel/2013-December/039567.html
>
> CANTATE DOMINO CANTICUM NOVUM
> QUIA MIRABILIA FECIT
>
> Laércio
>
>
> 2013/12/12 Hans de Goede <hdegoede at redhat.com>
>
>> Hi,
>>
>>
>> On 12/12/2013 02:31 PM, Laércio de Sousa wrote:
>>
>>> Hans,
>>>
>>> systemd currently ships a multi-seat-x wrapper (
>>> http://cgit.freedesktop.org/systemd/systemd/tree/src/
>>> login/multi-seat-x.c) for cases where X.Org doesn't work well with
>>> multiseat. In the beginning, it was much bigger, but now, as X.Org evolves,
>>> it now only does the following:
>>>
>>> * If "-seat" option value is "seat0", just exec real X server, with no
>>> additions
>>> * Otherwise:
>>> + Append "-sharevts" to real X server command line [*]
>>> + Append "-config" to real X server command line, with the following
>>> config file:
>>> Section "ServerFlags"
>>> Option "AutoAddDevices" "True" # pointless, since it's already
>>> true by default
>>> Option "AllowEmptyInput" "True" # this option doesn't exist
>>> anymore
>>> Option "DontVTSwitch" "True" [*]
>>> EndSection
>>> Section "InputClass"
>>> Identifier "Force Input Devices to Seat"
>>> Option "GrabDevice" "True" # not needed anymore, since
>>> http://cgit.freedesktop.org/xorg/xserver/commit/?id=
>>> c73c36b537f996574628e69681833ea37dec2b6e
>>> EndSection
>>>
>>> The points tagged with [*] above are needed because non-seat0 X servers
>>> still try to open VTs, although non-seat0 seats can't handle them. My patch
>>> proposed at http://lists.x.org/archives/xorg-devel/2013-December/
>>> 039353.html makes those points unneeded.
>>>
>>
>> Thanks for the explanation, I've one small nitpick on your patch,
>> if you can resend it with that fixed I'll add it to what is swiftly
>> growing
>> into my systemd integration tree :)
>>
>> --- a/hw/xfree86/common/xf86Init.c
>> +++ b/hw/xfree86/common/xf86Init.c
>> @@ -545,7 +545,8 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char
>> **argv)
>> want_hw_access = TRUE;
>>
>> if (!(flags & HW_SKIP_CONSOLE))
>> - xorgHWOpenConsole = TRUE;
>> + /* Non-seat0 X servers should not open console */
>> + xorgHWOpenConsole = !ServerIsNotSeat0();
>> }
>>
>> if (xorgHWOpenConsole)
>>
>> Can you please make the !ServerIsNotSeat0() part of the if condition,
>> rather then using it as the value to store ? Since this is just
>> another way of expressing SKIP_CONSOLE it seems more sensible to me
>> that way.
>>
>> Thanks & Regards,
>>
>> Hans
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg-devel/attachments/20131212/7cc9bbff/attachment.html>
More information about the xorg-devel
mailing list