https://bugs.freedesktop.org/show_bug.cgi?id=43448
Bug #: 43448 Summary: No native 3D acceleration with Radeon FirePro M7740 (m97 / rv740) -> llvm pipe Classification: Unclassified Product: Mesa Version: 7.11 Platform: x86-64 (AMD64) OS/Version: Linux (All) Status: NEW Severity: major Priority: medium Component: Drivers/DRI/R600 AssignedTo: dri-devel@lists.freedesktop.org ReportedBy: marcaureleii@yahoo.fr
Created attachment 54048 --> https://bugs.freedesktop.org/attachment.cgi?id=54048 dmesg
Dear,
I try to get native 3D acceleration with my graphic card. I have a Dell Precision M6500 with Radeon FirePro M7740. The chipset (rv740) is rather well supported but I can't obtain native 3D acceleration. I have Linux Fedora 16, libmesa 7.11.1.
I don't understand where is the problem...
I attach my dmesg and LIBGL_DEBUG=verbose glxinfo. This last one indicates : "libGL error: failed to create dri screen"
Please help me.
Thanks a lot
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #1 from marc-aurele marcaureleii@yahoo.fr 2011-12-01 19:26:28 PST --- Created attachment 54049 --> https://bugs.freedesktop.org/attachment.cgi?id=54049 libgl verbose glxinfo
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Alex Deucher agd5f@yahoo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #54048|application/octet-stream |text/plain mime type| | Attachment #54048|0 |1 is patch| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Alex Deucher agd5f@yahoo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #54049|application/octet-stream |text/plain mime type| | Attachment #54049|0 |1 is patch| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #2 from Alex Deucher agd5f@yahoo.com 2011-12-02 06:07:09 PST --- Looks like you attached the wrong glxinfo output. Please attach your xorg log as well.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #3 from marc-aurele marcaureleii@yahoo.fr 2011-12-02 07:15:26 PST --- Created attachment 54077 --> https://bugs.freedesktop.org/attachment.cgi?id=54077 libgl verbose glxinfo
Here is the correct output of LIBGL_DEBUG=verbose glxinfo
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #4 from marc-aurele marcaureleii@yahoo.fr 2011-12-02 07:20:40 PST --- Created attachment 54078 --> https://bugs.freedesktop.org/attachment.cgi?id=54078 xorg log
And here is my xorg log. Thanks for your interest and sorry for the bad glxinfo log.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Alex Deucher agd5f@yahoo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #54077|application/octet-stream |text/plain mime type| | Attachment #54077|0 |1 is patch| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Alex Deucher agd5f@yahoo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #54078|text/x-log |text/plain mime type| | Attachment #54078|0 |1 is patch| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Michel Dänzer michel@daenzer.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #54049|1 |0 is patch| | Attachment #54049|0 |1 is obsolete| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #5 from Michel Dänzer michel@daenzer.net 2011-12-06 07:46:32 PST --- Looks like /usr/lib64/dri/r600_dri.so's dri2CreateNewScreen() hook fails, but it's not clear why. Maybe you can try running glxinfo in gdb, setting a breakpoint at dri2CreateNewScreen and tracing where the failure is coming from.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #6 from Dave Airlie airlied@freedesktop.org 2011-12-06 08:12:01 PST --- check mesa is built with radeon drm support.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #7 from marc-aurele marcaureleii@yahoo.fr 2011-12-25 02:25:42 PST --- Dear,
I use default version of mesa (7.11.2) on Fedora 16, so I think it is build with radeon drm support, yes.
Tracing and debugging is not (yet) my skill level, but perhaps you can guide and help me. Here is what I get setting a breakpoint at dri2CreateNewScreen:
(gdb) run Starting program: /usr/bin/glxinfo [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". name of display: :0 libGL: OpenDriver: trying /usr/lib64/dri/r600_dri.so
Breakpoint 1, dri2CreateNewScreen (scrn=0, fd=8, extensions=0x614f30, driver_configs=0x7fffffffd980, data=0x6160b0) at ../common/dri_util.c:865 865 { (gdb)
What else should I do ?
Thanks a lot !
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #8 from Michel Dänzer michel@daenzer.net 2011-12-28 01:48:50 PST --- (In reply to comment #7)
What else should I do ?
First of all, run 'finish' and check that the return value of dri2CreateNewScreen is 0 as suspected.
If so, single-step through dri2CreateNewScreen and its callees with 'step' / 'next' to find out why it returns 0.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #9 from Stefan freedesktop@kanarski.de 2012-05-28 02:24:02 PDT --- Hello,
I think I have found a solution for this problem and another. I have the same notebook with that graphics card and had some problems with it in the past months whenever I tried the open source driver from Debian unstable. It worked about a year ago but then I bought a 27" monitor which was only usable with its native resolution of 2560x1440 with the fglrx driver (which had some other problems by the way). I regularly tried the open source driver when new versions show up in Debian but since some months the XServer crashed immediately after the start with a segfault. In newer versions it became more graceful with the following log messages:
(EE) RADEON(0): radeon_surface_best failed (EE) RADEON(0): radeon_setup_kernel_mem failed
After debugging like suggested in bug #48138 I found out that there is missing a case in r6_init_hw_info for setting num_banks. While there are cases for 0 and 1 the FirePro M7740 has a value of 2 at some bits of the tiling_config so it returns with -EINVAL from the default case. First I did not know on what to set num_banks in that case but tried something and the XServer started successfully with that change.
Then I saw in /var/log/Xorg.0.log that the 3D acceleration was not working like described in this bug report:
(EE) AIGLX error: Calling driver entry point failed (EE) AIGLX: reverting to software rendering
I tried to debug that too, following the above hints and ended up in r600_interpret_tiling in src/gallium/drivers/r600/r600_pipe.c in the MESA code and found exactly the same reason as above, a missing case 2. In the meantime I checked out the source of xserver-xorg-video-ati too and sensitized by the above findings made a grep over all three source trees (libdri, mesa, xserver-xorg-video-ati):
grep "num_banks.*=" -rsn . -B 2 -A 1
There I found another missing case 2 in r600_interpret_tiling in src/radeon_kms.c and somewhere else an existing case 2 with num_banks = 16. So I patched all found asymmetries regarding case 2 and the 3D acceleration began to work again.
I append all three patches I made. Maybe someone can check them and add them if they are reasonable so future versions can incorporate the fixes.
Best regards Stefan Kanarski
PS: Now my only problem is the resolution of 2560x1440 with my Fujitsu P27T-6. Via DVI I only get 1280x1440 (every second pixel column missing, looks like single-link although the cable should be dual-link) and via DisplayPort the monitor is toggling between power save and a black screen. But that's another story for another day or two. If someone has an idea where to start looking I am glad to hear.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #10 from Stefan freedesktop@kanarski.de 2012-05-28 02:26:56 PDT --- Created attachment 62157 --> https://bugs.freedesktop.org/attachment.cgi?id=62157 Patch for branch debian-unstable in http://git.debian.org/pkg-xorg/lib/libdrm.git
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #11 from Stefan freedesktop@kanarski.de 2012-05-28 02:28:32 PDT --- Created attachment 62158 --> https://bugs.freedesktop.org/attachment.cgi?id=62158 Patch for branch debian-unstable in http://git.debian.org/pkg-xorg/lib/mesa.git
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #12 from Stefan freedesktop@kanarski.de 2012-05-28 02:30:44 PDT --- Created attachment 62159 --> https://bugs.freedesktop.org/attachment.cgi?id=62159 Patch for branch debian-unstable in http://git.debian.org/pkg-xorg/driver/xserver-xorg-video-ati.git
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #13 from Alex Deucher agd5f@yahoo.com 2012-05-29 15:43:11 PDT --- Created attachment 62246 --> https://bugs.freedesktop.org/attachment.cgi?id=62246 possible fix
It's actually a kernel issue. The attached patch against Dave's drm-fixes branch should fix it.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #14 from Michel Dänzer michel@daenzer.net 2012-06-06 01:37:53 PDT --- Could libdrm_radeon also be made to deal gracefully with broken kernels?
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #15 from Alex Deucher agd5f@yahoo.com 2012-06-06 06:14:27 PDT --- Created attachment 62672 --> https://bugs.freedesktop.org/attachment.cgi?id=62672 libdrm fix
This patch should do the trick.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Alex Deucher agd5f@yahoo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #62672|0 |1 is obsolete| |
--- Comment #16 from Alex Deucher agd5f@yahoo.com 2012-06-06 06:26:50 PDT --- Created attachment 62674 --> https://bugs.freedesktop.org/attachment.cgi?id=62674 libdrm fix
slightly improved version.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #17 from Jack Dodds brmdamon@hushmail.com 2012-06-14 18:14:15 PDT --- I have a Hewlett Packard H8-1224 which has a Radeon HD7570 video card. Software is up to date Debian Wheezy, using the radeon X driver and the non-free firmware. The startup of X fails with the messages
[ 18.376] (EE) RADEON(0): radeon_surface_best failed [ 18.376] (EE) RADEON(0): radeon_setup_kernel_mem failed
It's been suggested that my problem is related to the bug documented here. To those more knowledgable than I - does this seem likely? I'll post the complete Xorg.log.
If the patches listed here are relevant, could someone explain - would ONE of the patches address the problem, or would they ALL need to be installed.
Thanks for your help!
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #18 from Jack Dodds brmdamon@hushmail.com 2012-06-14 18:19:29 PDT --- Created attachment 63053 --> https://bugs.freedesktop.org/attachment.cgi?id=63053 Xorg.log from HP H8-1224 with Radeon HD7570 and Debian Wheezy
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Michel Dänzer michel@daenzer.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED
--- Comment #19 from Michel Dänzer michel@daenzer.net 2012-06-15 03:10:35 PDT --- (In reply to comment #17)
It's been suggested that my problem is related to the bug documented here. To those more knowledgable than I - does this seem likely?
Yes.
If the patches listed here are relevant, could someone explain - would ONE of the patches address the problem, or would they ALL need to be installed.
Either alone should be sufficient.
The libdrm fix is in the 2.4.35 release and I think the kernel fix is in mainline as well, so resolving this report as fixed.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Michel Dänzer michel@daenzer.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #62157|0 |1 is obsolete| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Michel Dänzer michel@daenzer.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #62158|0 |1 is obsolete| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Michel Dänzer michel@daenzer.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #62159|0 |1 is obsolete| |
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #20 from Jack Dodds brmdamon@hushmail.com 2012-06-24 18:42:24 PDT --- Further to the above - I have tried all the patches listed above, in various combinations, and the problem still exists. The startup of X fails with the messages
radeon_surface_best failed radeon_setup_kernel_mem failed
Configuration (current Debian Wheezy):
Radeon 7570 card - PCI identifier 675D Kernel: 3.2.0-2-amd64 xserver-xorg-video-radeon: 6.14.4-5 libdrm-radeon1 & libdrm2: 2.4.33-1 /etc/X11/xorg.conf.d: Does not contain a Device section.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #21 from Michel Dänzer michel@daenzer.net 2012-06-25 02:30:51 PDT --- (In reply to comment #20)
Radeon 7570 card - PCI identifier 675D
That's a different card from the one this bug report is about.
libdrm-radeon1 & libdrm2: 2.4.33-1
Support for your card was only added in libdrm_radeon 2.4.34.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
--- Comment #22 from Jack Dodds brmdamon@hushmail.com 2012-06-25 03:51:46 PDT --- Thank you for the information. I found the PCI code 675D in various header files in xserver-xorg-video-ati-6.14.4 and mesa-8.0.2, leading me to believe that it was supported in Wheezy. But now I see it is not mentioned in the .h files in libdrm-2.4.33.
https://bugs.freedesktop.org/show_bug.cgi?id=43448
Florian Mickler florian@mickler.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |florian@mickler.org
--- Comment #23 from Florian Mickler florian@mickler.org 2012-07-01 03:39:34 PDT --- A patch referencing this bug report has been merged in Linux v3.5-rc1:
commit 29d654067a98c1cb8874c774e5fd799a038af8a6 Author: Alex Deucher alexander.deucher@amd.com Date: Thu May 31 18:53:36 2012 -0400
drm/radeon: fix bank information in tiling config
dri-devel@lists.freedesktop.org