[arch-commits] Commit in xf86-video-ati/repos (6 files)
Laurent Carlier
lcarlier at archlinux.org
Thu Jul 17 22:54:09 UTC 2014
Date: Friday, July 18, 2014 @ 00:54:09
Author: lcarlier
Revision: 216971
archrelease: copy trunk to staging-i686, staging-x86_64
Added:
xf86-video-ati/repos/staging-i686/
xf86-video-ati/repos/staging-i686/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch
(from rev 216970, xf86-video-ati/trunk/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch)
xf86-video-ati/repos/staging-i686/PKGBUILD
(from rev 216970, xf86-video-ati/trunk/PKGBUILD)
xf86-video-ati/repos/staging-x86_64/
xf86-video-ati/repos/staging-x86_64/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch
(from rev 216970, xf86-video-ati/trunk/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch)
xf86-video-ati/repos/staging-x86_64/PKGBUILD
(from rev 216970, xf86-video-ati/trunk/PKGBUILD)
-------------------------------------------------------------------+
staging-i686/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch | 78 ++++++++++
staging-i686/PKGBUILD | 43 +++++
staging-x86_64/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch | 78 ++++++++++
staging-x86_64/PKGBUILD | 43 +++++
4 files changed, 242 insertions(+)
Copied: xf86-video-ati/repos/staging-i686/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch (from rev 216970, xf86-video-ati/trunk/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch)
===================================================================
--- staging-i686/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch (rev 0)
+++ staging-i686/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch 2014-07-17 22:54:09 UTC (rev 216971)
@@ -0,0 +1,78 @@
+From c4ae0e2cbcc0e2ebf9f13ee92d59b5120254a1dc Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <michel.daenzer at amd.com>
+Date: Mon, 30 Jun 2014 10:20:12 +0900
+Subject: [PATCH] Handle CRTC DPMS from output DPMS hooks
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This fixes at least two issues:
+
+The CRTC DPMS hook isn't called after a modeset, so the vertical blank
+interrupt emulation code considered the CRTC disabled after a modeset. As
+a side effect, page flipping was no longer used after a modeset.
+
+This change also makes sure the vertical blank interrupt emulation code
+runs before the hardware CRTC is disabled and after it's enabled from the
+output DPMS hook. The wrong order could cause gnome-shell to hang after
+a suspend/resume and/or DPMS off/on cycle.
+
+Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
+Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
+---
+ src/drmmode_display.c | 16 ++++++++++++++--
+ 1 file changed, 14 insertions(+), 2 deletions(-)
+
+diff --git a/src/drmmode_display.c b/src/drmmode_display.c
+index bd8e701..c366203 100644
+--- a/src/drmmode_display.c
++++ b/src/drmmode_display.c
+@@ -247,7 +247,7 @@ int drmmode_get_current_ust(int drm_fd, CARD64 *ust)
+ }
+
+ static void
+-drmmode_crtc_dpms(xf86CrtcPtr crtc, int mode)
++drmmode_do_crtc_dpms(xf86CrtcPtr crtc, int mode)
+ {
+ drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private;
+ ScrnInfoPtr scrn = crtc->scrn;
+@@ -308,6 +308,12 @@ drmmode_crtc_dpms(xf86CrtcPtr crtc, int mode)
+ drmmode_crtc->dpms_mode = mode;
+ }
+
++static void
++drmmode_crtc_dpms(xf86CrtcPtr crtc, int mode)
++{
++ /* Nothing to do. drmmode_do_crtc_dpms() is called as appropriate */
++}
++
+ static PixmapPtr
+ create_pixmap_for_fbcon(drmmode_ptr drmmode,
+ ScrnInfoPtr pScrn, int fbcon_id)
+@@ -973,9 +979,14 @@ drmmode_output_dpms(xf86OutputPtr output, int mode)
+ drmModeConnectorPtr koutput = drmmode_output->mode_output;
+ drmmode_ptr drmmode = drmmode_output->drmmode;
+
++ if (mode != DPMSModeOn && output->crtc)
++ drmmode_do_crtc_dpms(output->crtc, mode);
++
+ drmModeConnectorSetProperty(drmmode->fd, koutput->connector_id,
+ drmmode_output->dpms_enum_id, mode);
+- return;
++
++ if (mode == DPMSModeOn && output->crtc)
++ drmmode_do_crtc_dpms(output->crtc, mode);
+ }
+
+
+@@ -1833,6 +1844,7 @@ Bool drmmode_set_desired_modes(ScrnInfoPtr pScrn, drmmode_ptr drmmode)
+
+ /* Skip disabled CRTCs */
+ if (!crtc->enabled) {
++ drmmode_do_crtc_dpms(crtc, DPMSModeOff);
+ drmModeSetCrtc(drmmode->fd, drmmode_crtc->mode_crtc->crtc_id,
+ 0, 0, 0, NULL, 0, NULL);
+ continue;
+--
+2.0.1
+
Copied: xf86-video-ati/repos/staging-i686/PKGBUILD (from rev 216970, xf86-video-ati/trunk/PKGBUILD)
===================================================================
--- staging-i686/PKGBUILD (rev 0)
+++ staging-i686/PKGBUILD 2014-07-17 22:54:09 UTC (rev 216971)
@@ -0,0 +1,43 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+# Contributor: Alexander Baldeck <alexander at archlinux.org>
+
+pkgname=xf86-video-ati
+pkgver=7.4.0
+epoch=1
+pkgrel=3
+pkgdesc="X.org ati video driver"
+arch=('i686' 'x86_64')
+url="http://xorg.freedesktop.org/"
+license=('custom')
+depends=('libdrm>=2.4.41' 'systemd' 'ati-dri')
+makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=18')
+conflicts=('xorg-server<1.16.0' 'X-ABI-VIDEODRV_VERSION<18' 'X-ABI-VIDEODRV_VERSION>=19')
+groups=('xorg-drivers' 'xorg')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ 0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch)
+sha256sums=('96230ca9859a2a3e347b7f37597b7b344e80b83f378d3a8463ab1ceb69df76d9'
+ '50b3ff79874c16af449fca40e2c2b9fe3d0341216d47594ff616515174f1e84b')
+
+prepare() {
+ cd ${pkgname}-${pkgver}
+
+ # merged upstream
+ patch -Np1 -i ../0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch
+}
+
+build() {
+ cd ${pkgname}-${pkgver}
+
+ ./configure --prefix=/usr \
+ --enable-glamor
+ make
+}
+
+package() {
+ cd ${pkgname}-${pkgver}
+
+ make "DESTDIR=${pkgdir}" install
+ install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}
Copied: xf86-video-ati/repos/staging-x86_64/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch (from rev 216970, xf86-video-ati/trunk/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch)
===================================================================
--- staging-x86_64/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch (rev 0)
+++ staging-x86_64/0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch 2014-07-17 22:54:09 UTC (rev 216971)
@@ -0,0 +1,78 @@
+From c4ae0e2cbcc0e2ebf9f13ee92d59b5120254a1dc Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <michel.daenzer at amd.com>
+Date: Mon, 30 Jun 2014 10:20:12 +0900
+Subject: [PATCH] Handle CRTC DPMS from output DPMS hooks
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This fixes at least two issues:
+
+The CRTC DPMS hook isn't called after a modeset, so the vertical blank
+interrupt emulation code considered the CRTC disabled after a modeset. As
+a side effect, page flipping was no longer used after a modeset.
+
+This change also makes sure the vertical blank interrupt emulation code
+runs before the hardware CRTC is disabled and after it's enabled from the
+output DPMS hook. The wrong order could cause gnome-shell to hang after
+a suspend/resume and/or DPMS off/on cycle.
+
+Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
+Reviewed-by: Alex Deucher <alexander.deucher at amd.com>
+---
+ src/drmmode_display.c | 16 ++++++++++++++--
+ 1 file changed, 14 insertions(+), 2 deletions(-)
+
+diff --git a/src/drmmode_display.c b/src/drmmode_display.c
+index bd8e701..c366203 100644
+--- a/src/drmmode_display.c
++++ b/src/drmmode_display.c
+@@ -247,7 +247,7 @@ int drmmode_get_current_ust(int drm_fd, CARD64 *ust)
+ }
+
+ static void
+-drmmode_crtc_dpms(xf86CrtcPtr crtc, int mode)
++drmmode_do_crtc_dpms(xf86CrtcPtr crtc, int mode)
+ {
+ drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private;
+ ScrnInfoPtr scrn = crtc->scrn;
+@@ -308,6 +308,12 @@ drmmode_crtc_dpms(xf86CrtcPtr crtc, int mode)
+ drmmode_crtc->dpms_mode = mode;
+ }
+
++static void
++drmmode_crtc_dpms(xf86CrtcPtr crtc, int mode)
++{
++ /* Nothing to do. drmmode_do_crtc_dpms() is called as appropriate */
++}
++
+ static PixmapPtr
+ create_pixmap_for_fbcon(drmmode_ptr drmmode,
+ ScrnInfoPtr pScrn, int fbcon_id)
+@@ -973,9 +979,14 @@ drmmode_output_dpms(xf86OutputPtr output, int mode)
+ drmModeConnectorPtr koutput = drmmode_output->mode_output;
+ drmmode_ptr drmmode = drmmode_output->drmmode;
+
++ if (mode != DPMSModeOn && output->crtc)
++ drmmode_do_crtc_dpms(output->crtc, mode);
++
+ drmModeConnectorSetProperty(drmmode->fd, koutput->connector_id,
+ drmmode_output->dpms_enum_id, mode);
+- return;
++
++ if (mode == DPMSModeOn && output->crtc)
++ drmmode_do_crtc_dpms(output->crtc, mode);
+ }
+
+
+@@ -1833,6 +1844,7 @@ Bool drmmode_set_desired_modes(ScrnInfoPtr pScrn, drmmode_ptr drmmode)
+
+ /* Skip disabled CRTCs */
+ if (!crtc->enabled) {
++ drmmode_do_crtc_dpms(crtc, DPMSModeOff);
+ drmModeSetCrtc(drmmode->fd, drmmode_crtc->mode_crtc->crtc_id,
+ 0, 0, 0, NULL, 0, NULL);
+ continue;
+--
+2.0.1
+
Copied: xf86-video-ati/repos/staging-x86_64/PKGBUILD (from rev 216970, xf86-video-ati/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD (rev 0)
+++ staging-x86_64/PKGBUILD 2014-07-17 22:54:09 UTC (rev 216971)
@@ -0,0 +1,43 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+# Contributor: Alexander Baldeck <alexander at archlinux.org>
+
+pkgname=xf86-video-ati
+pkgver=7.4.0
+epoch=1
+pkgrel=3
+pkgdesc="X.org ati video driver"
+arch=('i686' 'x86_64')
+url="http://xorg.freedesktop.org/"
+license=('custom')
+depends=('libdrm>=2.4.41' 'systemd' 'ati-dri')
+makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=18')
+conflicts=('xorg-server<1.16.0' 'X-ABI-VIDEODRV_VERSION<18' 'X-ABI-VIDEODRV_VERSION>=19')
+groups=('xorg-drivers' 'xorg')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2
+ 0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch)
+sha256sums=('96230ca9859a2a3e347b7f37597b7b344e80b83f378d3a8463ab1ceb69df76d9'
+ '50b3ff79874c16af449fca40e2c2b9fe3d0341216d47594ff616515174f1e84b')
+
+prepare() {
+ cd ${pkgname}-${pkgver}
+
+ # merged upstream
+ patch -Np1 -i ../0001-Handle-CRTC-DPMS-from-output-DPMS-hooks.patch
+}
+
+build() {
+ cd ${pkgname}-${pkgver}
+
+ ./configure --prefix=/usr \
+ --enable-glamor
+ make
+}
+
+package() {
+ cd ${pkgname}-${pkgver}
+
+ make "DESTDIR=${pkgdir}" install
+ install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}
More information about the arch-commits
mailing list