Skip to content
This repository has been archived by the owner on Oct 7, 2020. It is now read-only.

Fix patch with current Ubuntu 12.04.2 #6

Open
floe opened this issue Jul 4, 2013 · 2 comments
Open

Fix patch with current Ubuntu 12.04.2 #6

floe opened this issue Jul 4, 2013 · 2 comments

Comments

@floe
Copy link

floe commented Jul 4, 2013

With the xserver-xorg-video-intel package currently in Ubuntu LTS 12.04.2 (exact version is 2.17.0-1ubuntu4.4), virtual-crtc.patch causes a segfault in the intel driver. This is because one of the more recent Ubuntu patches interferes with the virtual CRTC in a bad way. Here's a patch for the patch to patch the patch (SCNR);

diff -u xserver-xorg-video-intel-2.17.0/debian/patches/101_copy-fb.patch xserver-xorg-video-intel-2.17.0-new/debian/patches/101_copy-fb.patch
--- xserver-xorg-video-intel-2.17.0/debian/patches/101_copy-fb.patch    2013-07-04 08:13:09.000000000 +0200
+++ xserver-xorg-video-intel-2.17.0-new/debian/patches/101_copy-fb.patch    2013-07-04 07:50:21.779985220 +0200
@@ -143,7 +143,7 @@
 +  fbcon_id = 0;
 +  for (i = 0; i < xf86_config->num_crtc; i++) {
 +      intel_crtc = xf86_config->crtc[i]->driver_private;
-+      if (intel_crtc->mode_crtc->buffer_id)
++      if (intel_crtc->mode_crtc && intel_crtc->mode_crtc->buffer_id)
 +          fbcon_id = intel_crtc->mode_crtc->buffer_id;
 +  }
 +  if (!fbcon_id)
@floe
Copy link
Author

floe commented Jul 9, 2013

Same here:

diff -ur xserver-xorg-video-intel-2.17.0-old/debian/patches/106-uxa-only-consider-attached-outputs-valid.patch xserver-xorg-video-intel-2.17.0/debian/patches/106-uxa-only-consider-attached-outputs-valid.patch
--- xserver-xorg-video-intel-2.17.0-old/debian/patches/106-uxa-only-consider-attached-outputs-valid.patch   2013-07-08 17:12:29.570271712 +0200
+++ xserver-xorg-video-intel-2.17.0/debian/patches/106-uxa-only-consider-attached-outputs-valid.patch   2013-07-08 17:09:20.946275582 +0200
@@ -31,7 +31,7 @@

 --- a/src/intel_display.c
 +++ b/src/intel_display.c
-@@ -1716,6 +1716,43 @@
+@@ -1716,6 +1716,45 @@
    return intel_crtc->pipe;
  }

@@ -61,6 +61,8 @@
 +               return FALSE;
 +
 +       /* And finally check with the kernel that the fb is bound */
++       if (intel_crtc->mode == NULL || intel_crtc->mode_crtc == NULL)
++               return FALSE;
 +       drm_crtc = drmModeGetCrtc(intel_crtc->mode->fd, crtc_id(intel_crtc));
 +       if (drm_crtc == NULL)
 +               return FALSE;

@squisher
Copy link

squisher commented Aug 7, 2013

Copy & paste for this is not entirely working since there are tabs involved (evil!)

For your convenience: https://gist.github.com/squisher/6179117

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants