Hi,
On 25-03-15 05:21, Peter Hutterer wrote:
Required to make the driver receive keyboard events from the console.
X.Org Bug <http://bugs.freedesktop.org/show_bug.cgi?id=89653>
Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net>
Looks good:
Reviewed-by: Hans de Goede <hdego...@redhat.com>
Regards,
Hans
---
Mark was right, this seems to do the trick. I don't know why this is needed
now though when it wasn't in the past. When I tried bisecting this
yesterday I started before all the systemd-logind patches and it still had
the same behaviour. A 3.18rc4 kernel that I still had around
also required the patch. So something somewhere has broken this, I just
don't know what.
Either way, this fixes it, with no side-effects that I found so far.
I was contemplating of putting this in the server but it's really only the
keyboard driver that needs this.
src/lnx_kbd.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/src/lnx_kbd.c b/src/lnx_kbd.c
index 811a7d7..c221194 100644
--- a/src/lnx_kbd.c
+++ b/src/lnx_kbd.c
@@ -187,8 +187,17 @@ OpenKeyboard(InputInfoPtr pInfo)
s = xf86SetStrOption(pInfo->options, "Device", NULL);
if (s == NULL) {
+ int rc;
pInfo->fd = xf86Info.consoleFd;
pKbd->isConsole = TRUE;
+
+ rc = tcsetpgrp(pInfo->fd, getpgid(0));
+ if (rc < 0) {
+ xf86IDrvMsg(pInfo, X_ERROR,
+ "failed to set us as foreground pgrp (%s)\n",
+ strerror(errno));
+ }
+
} else {
pInfo->fd = open(s, O_RDONLY | O_NONBLOCK | O_EXCL);
if (pInfo->fd == -1) {
_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel