From owner-freebsd-x11@freebsd.org Thu Mar 23 07:21:36 2017 Return-Path: Delivered-To: freebsd-x11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B8E6BD196FB for ; Thu, 23 Mar 2017 07:21:36 +0000 (UTC) (envelope-from jan.kokemueller@gmail.com) Received: from mail-wm0-x231.google.com (mail-wm0-x231.google.com [IPv6:2a00:1450:400c:c09::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5ED07FE9 for ; Thu, 23 Mar 2017 07:21:36 +0000 (UTC) (envelope-from jan.kokemueller@gmail.com) Received: by mail-wm0-x231.google.com with SMTP id n11so54699868wma.0 for ; Thu, 23 Mar 2017 00:21:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=to:references:subject:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=T5njDSKSm7cPX1RWTqVW/HPBlQ4xeObKsFLLJ0opnTI=; b=gpLrGuPpvuc3exHZBOQp49R27oAbjIyebgm6lQRdEqv7WFxVYUCTfXe/wk6LQC8WUx If/Rs6bULu743Rp1f156CBB3w8uPRVPt7giE8m8+Ch8aQCGcjfnRmMS6SBoepfqUOUn9 d71tM6ktohtl1VYcJen1OTcUqjcJRx1BOJQ1AFBka8YR6SkqFRKiL9ARlrrzUdK9NsJF bPxQosqC2ggelM5WKX9wYe4ozMMmTNq0ekQsBYddkD8OKgQmO9pQfsxnx+hWkT+QNfEr k1ralzgUHuBUYc+MG5lZdLHMc2WGkvK6YzTrFjFm/Ts3BqOsZOpYrYAWVoxm4Z8FhBdU pdkA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:references:subject:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=T5njDSKSm7cPX1RWTqVW/HPBlQ4xeObKsFLLJ0opnTI=; b=A0FU4TE+qdBgZdvK5lyh1IYm9kUZTGgxS9Y0M2NNzgRiUNyvG17NiKou3+BD4EyUpB lBmxJZxLO91NDcojPk6zJN6wicI8WlDxiQjP/t21vd9sdY8HaKJVhgoN9v3MlFt4uEsN ifhH4DWzngbol/UAiEtfkE8OEgLk0qrzG65dpflD3HABCE/3T3lSMc624/57ohRi1oTY IUcjyKcjA/AQtArvgxPLd6Oqj49U9mL/0WNnKCtOzw7OQS+Po8RjraV/Iu83rhFw5VhF FG3v1z4dv0EBJRT+RrK2W1aVPZDCQO0iS4thuyGKhSL26KE7WLeMrtKXlCRvvCYKKrY9 ZSeQ== X-Gm-Message-State: AFeK/H3w+7Yq2A4m4ZWj5jTBy0RjjjIyoKC2RNB5MfYJhgmDOudVcjwP+0B63DFqKu+YSg== X-Received: by 10.28.208.72 with SMTP id h69mr11636492wmg.100.1490253694349; Thu, 23 Mar 2017 00:21:34 -0700 (PDT) Received: from ?IPv6:2003:71:4f26:ef00:468:bf4e:71e:4926? (p200300714F26EF000468BF4E071E4926.dip0.t-ipconnect.de. [2003:71:4f26:ef00:468:bf4e:71e:4926]) by smtp.googlemail.com with ESMTPSA id 53sm4649239wrt.52.2017.03.23.00.21.33 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 23 Mar 2017 00:21:33 -0700 (PDT) To: freebsd-x11@freebsd.org References: <1774569.2utjLAkrOb@workstation.reztek> Subject: Re: CFT: update Xorg to 1.19.3 From: =?UTF-8?Q?Jan_Kokem=c3=bcller?= Message-ID: <0d34061f-a941-6bce-1a14-2221561271b5@gmail.com> Date: Thu, 23 Mar 2017 08:21:32 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <1774569.2utjLAkrOb@workstation.reztek> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-x11@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: X11 on FreeBSD -- maintaining and support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Mar 2017 07:21:36 -0000 Thanks, Xorg 1.19.3 from your patch works great for me. I've had trouble applying the patch, though. There were conflicts in the devd backend. I used "patch < Xorg_1_19_3.patch" to apply the patch. I've been running the libdevd-udev backend for now. I'm running the 'modesetting' video driver on Intel Sandybridge graphics and it works without tearing when using compton. It seems a good alternative to the xf86-video-intel driver. Evdev devices are picked up correctly by the libdevd-udev backend. But there is a small bug uncovered by using evdev devices exclusively: Without evdev, xf86-input-keyboard is used for keyboard input. This driver was responsible for setting the console to raw mode with "ioctl(fd, KDSKBMODE, K_RAW);". One easy way to check if raw mode is enabled is trying to press Alt+F1 to switch to another TTY. This should not work in raw mode (Strg+Alt+F1 is needed). Setting the mode to K_RAW in the Server as done on Linux seems more correct. I don't fully understand this ioctl yet, though. There is some discussion here: http://unix.stackexchange.com/questions/173712/best-practice-for-hiding-virtual-console-while-rendering-video-to-framebuffer/178807#178807 I'm using this quickly thrown together patch to set the terminal to K_RAW mode: diff -ru work/xorg-server-1.19.3/hw/xfree86/os-support/bsd/bsd_init.c work2/xorg-server-1.19.3/hw/xfree86/os-support/bsd/bsd_init.c --- work/xorg-server-1.19.3/hw/xfree86/os-support/bsd/bsd_init.c 2017-03-23 08:05:01.085410000 +0100 +++ work2/xorg-server-1.19.3/hw/xfree86/os-support/bsd/bsd_init.c 2017-03-18 13:51:35.411504000 +0100 @@ -443,6 +443,11 @@ fd = -1; } } + + if (fd >= 0) { + ioctl(fd, KDSKBMODE, K_RAW); + } + return fd; } @@ -596,6 +601,7 @@ #if defined (SYSCONS_SUPPORT) || defined (PCVT_SUPPORT) case SYSCONS: case PCVT: + ioctl(xf86Info.consoleFd, KDSKBMODE, K_XLATE); ioctl(xf86Info.consoleFd, KDSETMODE, KD_TEXT); /* Back to text mode */ if (ioctl(xf86Info.consoleFd, VT_GETMODE, &VT) != -1) { VT.mode = VT_AUTO;