drm_device_keep_trying.patch breaks with virtio-gpu

Bug #1492175 reported by Michael Thayer
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
xserver-xorg (Ubuntu)
Incomplete
Medium
Unassigned

Bug Description

I pointed this out to Maarten half a year ago, and he seemed concerned but didn't actually do anything. Your "drm_device_keep_trying.patch" X server patch crashes the X server with Dave Airlie's virtio GPU device and driver, and probably with any driver on a non-USB bus attached to PCI. The updated patch attached at least fixes the crash, and in the case of virtio it is probably actually correct when the device is on a PCI bus. Perhaps just converting the USB bit to apply to all unknown buses would be the right thing? By the way, note the changed format string too.

Tags: patch
Revision history for this message
Michael Thayer (michael-thayer) wrote :

By the way, this applies to at least Wily and Vivid, probably several more releases. The bug happens if the device is present, even if it is not used because no driver is present.

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Modified version of drm_device_keep_trying.patch with does not crash with virtio-gpu" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Changed in xserver-xorg (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Robert Ancell (robert-ancell) wrote :

Hi Michael,

I'm trying to understand this patch, one of your changes is to not require the /drm/card* suffix on the syspath. Do you know why this was there before? Does it matter it's not checked for now?

The replacement of "end - 13" with skipping the prefix seems much safer. You could also drop the "end" variable as it's no longer used. I would also be nicer to replace the 19 magic number with a strlen ("/devices/pci/0000:00") although this is also unsafe and could run you off the end of the array. I'm happy to make these changes if you don't want to.

Revision history for this message
Robert Ancell (robert-ancell) wrote :

This patch was proposed upstream in https://bugs.freedesktop.org/show_bug.cgi?id=77889 (via bug 982889). This is a note to update the proposed patch when we update our version.

Revision history for this message
Robert Ancell (robert-ancell) wrote :

Actually - could you paste the /sys entry when using this driver so I can see how it crashes? Thanks.

Changed in xserver-xorg (Ubuntu):
status: Triaged → Incomplete
Revision history for this message
Sebastien Bacher (seb128) wrote :

seems like Robert needs more information on that before it's ready for upload, unsubscribing sponsors until those are provided at least

Revision history for this message
Michael Thayer (michael-thayer) wrote :

Sorry, got distracted from this since I didn't have enough spare time to get the Qemu set-up with the device running just now. Fortunately I still have my original e-mail to Maarten with the device path in it:

/sys/devices/pci0000:00/0000:00:03.0/virtio1/drm/card0

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.