From: Hans de Goede <hdegoede@redhat.com>
To: Laszlo Ersek <lersek@redhat.com>, Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Emil Velikov <emil.l.velikov@gmail.com>,
dri-devel@lists.freedesktop.org,
"Thorsten Leemhuis (regressions address)"
<regressions@leemhuis.info>, Gerd Hoffmann <kraxel@redhat.com>,
Daniel Vetter <daniel.vetter@intel.com>,
David Airlie <airlied@redhat.com>,
Joachim Frieben <jfrieben@hotmail.com>,
Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Subject: Re: Regression: drm: Lobotomize set_busid nonsense for !pci drivers (a325725633c2)
Date: Fri, 30 Sep 2016 10:28:06 +0200 [thread overview]
Message-ID: <798c8b2d-1da9-51a3-8be7-b23d4cb26f3f@redhat.com> (raw)
In-Reply-To: <503b3377-5e61-75c7-1d33-a44c89028a79@redhat.com>
Hi,
On 30-09-16 05:09, Laszlo Ersek wrote:
> Hello Daniel,
>
> On 06/21/16 14:08, daniel.vetter at ffwll.ch (Daniel Vetter) wrote:
>> We already have a fallback in place to fill out the unique from
>> dev->unique, which is set to something reasonable in drm_dev_alloc.
>>
>> Which means we only need to have a special set_busid for pci devices,
>> to be able to care the backwards compat code for drm 1.1 around, which
>> libdrm still needs.
>>
>> While developing and testing this patch things blew up in really
>> interesting ways, and the code is rather confusing in naming things
>> between the kernel code, ioctl #defines and libdrm. For the next brave
>> dragon slayer, document all this madness properly in the userspace
>> interface section of gpu.tmpl.
>>
>> v2: Make drm_dev_set_unique static and update kerneldoc.
>>
>> v3: Entire rewrite, plus document what's going on for posterity in the
>> gpu docbook uapi section.
>>
>> v4: Drop accidental amdgpu hunk (Emil).
>>
>> v5: Drop accidental omapdrm vblank counter change (Emil).
>>
>> Cc: Gustavo Padovan <gustavo.padovan at collabora.co.uk>
>> Cc: Emil Velikov <emil.l.velikov at gmail.com>
>> Tested-by: Gustavo Padovan <gustavo.padovan at collabora.co.uk> (virt_gpu)
>> Reviewed-by: Emil Velikov <emil.l.velikov at gmail.com>
>> Signed-off-by: Daniel Vetter <daniel.vetter at intel.com>
>> ---
>> Documentation/DocBook/gpu.tmpl | 4 ++
>> drivers/gpu/drm/armada/armada_drv.c | 1 -
>> drivers/gpu/drm/drm_ioctl.c | 58 +++++++++++++++++++++++++
>> drivers/gpu/drm/drm_platform.c | 18 --------
>> drivers/gpu/drm/etnaviv/etnaviv_drv.c | 1 -
>> drivers/gpu/drm/exynos/exynos_drm_drv.c | 1 -
>> drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 1 -
>> drivers/gpu/drm/imx/imx-drm-core.c | 1 -
>> drivers/gpu/drm/msm/msm_drv.c | 1 -
>> drivers/gpu/drm/nouveau/nouveau_drm.c | 1 -
>> drivers/gpu/drm/omapdrm/omap_drv.c | 1 -
>> drivers/gpu/drm/shmobile/shmob_drm_drv.c | 1 -
>> drivers/gpu/drm/tilcdc/tilcdc_drv.c | 1 -
>> drivers/gpu/drm/virtio/virtgpu_drm_bus.c | 10 -----
>> drivers/gpu/drm/virtio/virtgpu_drv.c | 1 -
>> drivers/gpu/drm/virtio/virtgpu_drv.h | 1 -
>> include/drm/drmP.h | 1 -
>> 17 files changed, 62 insertions(+), 41 deletions(-)
>
> This patch (commit a325725633c2) regresses X.org on QEMU's virtio-vga
> device. Please see
>
> https://bugzilla.redhat.com/show_bug.cgi?id=1366842
>
> complete with a bisection log under
>
> drivers/gpu/drm/virtio/
>
> (comment 20).
>
> Copying Thorsten so he can include this report in his next v4.8-rc8
> regression report, if he chooses so. (Commit a325725633c2 is part of
> v4.8-rc1, but we only managed to identify it now.) The last such report
> I know of is archived e.g. at
> <http://www.mail-archive.com/linux-kernel@vger.kernel.org/msg1239220.html>.
>
> Reported-by: Joachim Frieben <jfrieben@hotmail.com>
First of all Joachim thanks for bisecting this. I was thinking about this
bug / issue, while doing my laps in the swimming pool.
I wanted to add a comment to the bug to tell you that this is likely
a Xorg xserver issue and not a kernel issue and that there is no need to
bisect, but it is too late for that now.
Xorg when running without a Xorg.conf searches for what it considers
a "primary" gpu / video-card, basically it attempts to bring up the
right card in setups where there are multiple cards and if it does not
find one exits with an error.
The xserver has a 2 step process for finding the primary card:
1) It searches for is a card which has a vga-bios mapped,
as we've already determined in the mentioned Red Hat bug that works for
the classic qemu emulated video-cards, but not for qemu's virtio-vga.
2) If that does not work Xorg will fallback to any video class device
on pci-bus 1.
This fallback actually has been broken in the Xorg xserver for quite a
while now and only 2 days ago a patch from Laszlo was merged to fix this.
Only for things to break again due to this kernel patch.
Since the whole step 2) thingie is very much tied to x86 machines
where pci-bus 0 used to be the main bus and pci-bus 1 the agp,
which is sorta an obsolete assumption now a days and since relying
on bus numbers / enumeration order is a bad idea in general I'm not
entirely sure if this counts as a regression.
I've discussed the problem of the xserver exiting with an error when
no primary device can be found with some people (ajax) at XDC last week
since there are other use-cases where the pci-bus 1 fallback does not
work.
As such I've been working on a xserver patch-set to make the xserver
try harder (pick the first available device) when both steps described
above fail to find one, which should make things work even with the
newest (broken / regressed) kernels.
Given this mail thread, I guess I'm working after all today (I had
planned a day off) and I'll try to wrap up this patch-set and reply
to this mail with the server patches attached for Joachim and/or
Laszlo to test.
Regards,
Hans
p.s.
It would be interesting to do a lspci on both a working and a
non-working kernel to see what exactly is going on here.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2016-09-30 8:28 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-21 8:54 [PATCH 01/11] drm: Move master pointer from drm_minor to drm_device Daniel Vetter
2016-06-21 8:54 ` [PATCH 02/11] drm: Clean up drm_crtc.h Daniel Vetter
2016-06-21 8:54 ` [PATCH 03/11] drm: Use dev->name as fallback for dev->unique Daniel Vetter
2016-06-21 8:54 ` [PATCH 04/11] drm/vgem: Stop calling drm_drv_set_unique Daniel Vetter
2016-06-21 8:54 ` [PATCH 05/11] drm: Don't call drm_dev_set_unique from platform drivers Daniel Vetter
2016-06-21 8:54 ` [PATCH 06/11] drm: Nuke SET_UNIQUE ioctl Daniel Vetter
2016-06-21 8:54 ` [PATCH 07/11] drm: Lobotomize set_busid nonsense for !pci drivers Daniel Vetter
2016-06-21 12:08 ` [PATCH] " Daniel Vetter
2016-09-30 3:09 ` Regression: drm: Lobotomize set_busid nonsense for !pci drivers (a325725633c2) Laszlo Ersek
2016-09-30 8:28 ` Hans de Goede [this message]
2016-09-30 10:03 ` Laszlo Ersek
2016-09-30 10:35 ` Hans de Goede
2016-09-30 14:51 ` Laszlo Ersek
2016-09-30 14:59 ` Hans de Goede
2016-09-30 15:33 ` Laszlo Ersek
2016-09-30 16:38 ` Hans de Goede
2016-09-30 17:26 ` Laszlo Ersek
2016-10-03 11:34 ` Emil Velikov
2016-10-03 12:14 ` Laszlo Ersek
2016-10-03 12:46 ` Emil Velikov
2016-10-03 13:03 ` Laszlo Ersek
2016-10-03 14:15 ` Laszlo Ersek
2016-10-03 14:27 ` Laszlo Ersek
2016-10-03 15:00 ` Emil Velikov
2016-10-03 15:19 ` Laszlo Ersek
2016-10-03 19:12 ` Daniel Vetter
2016-10-03 19:36 ` Laszlo Ersek
2016-10-03 20:34 ` Daniel Vetter
2016-10-03 20:44 ` Laszlo Ersek
2016-10-04 7:43 ` Gerd Hoffmann
2016-10-05 6:34 ` Gerd Hoffmann
2016-10-05 10:30 ` Daniel Vetter
2016-10-05 12:43 ` Gerd Hoffmann
2016-10-05 13:02 ` Daniel Vetter
2016-09-30 9:55 ` Emil Velikov
2016-09-30 10:37 ` Emil Velikov
2016-06-21 8:54 ` [PATCH 08/11] drm: Refactor drop/set master code a bit Daniel Vetter
2016-06-21 12:20 ` [PATCH] " Daniel Vetter
2016-06-21 8:54 ` [PATCH 09/11] drm: Extract drm_is_current_master Daniel Vetter
2016-06-21 8:54 ` [PATCH 10/11] drm: Clear up master tracking booleans Daniel Vetter
2016-06-21 8:54 ` [PATCH 11/11] drm: document drm_auth.c Daniel Vetter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=798c8b2d-1da9-51a3-8be7-b23d4cb26f3f@redhat.com \
--to=hdegoede@redhat.com \
--cc=airlied@redhat.com \
--cc=daniel.vetter@ffwll.ch \
--cc=daniel.vetter@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=emil.l.velikov@gmail.com \
--cc=gustavo.padovan@collabora.co.uk \
--cc=jfrieben@hotmail.com \
--cc=kraxel@redhat.com \
--cc=lersek@redhat.com \
--cc=regressions@leemhuis.info \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).