Bug 9200 - mesa/progs/xdemos/glxpixmap error: GLXBadContext
Summary: mesa/progs/xdemos/glxpixmap error: GLXBadContext
Status: VERIFIED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i915 (show other bugs)
Version: git
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Eric Anholt
QA Contact:
URL:
Whiteboard:
Keywords:
: 9273 9482 11162 13214 13764 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-11-29 19:23 UTC by veelion (inactive account)
Modified: 2011-08-25 18:47 UTC (History)
9 users (show)

See Also:
i915 platform:
i915 features:


Attachments
xorg.log (46.13 KB, text/plain)
2006-11-29 19:23 UTC, veelion (inactive account)
Details
xorg.conf (2.63 KB, text/plain)
2006-11-29 19:24 UTC, veelion (inactive account)
Details
ldd glxinfo and ldd glxpixmap (2.15 KB, text/plain)
2006-12-12 13:06 UTC, Sérgio M. Basto
Details

Description veelion (inactive account) 2006-11-29 19:23:12 UTC
Platform: G965(ia32e)
kernel: 2.6.19-rc3
Mesa: CVS upstream
run mesa/progs/xdemos/glxpixmap will get the error,
run mesa/progs/xdemos/glxpixmap, will get the error,
-----
Direct rendering: No
X Error of failed request:  GLXBadContext
  Major opcode of failed request:  143 (GLX)
  Minor opcode of failed request:  5 (X_GLXMakeCurrent)
  Serial number of failed request:  30
  Current serial number in output stream:  30
-----
but the Direct rendering is Yes, which glxinfo told.
Comment 1 veelion (inactive account) 2006-11-29 19:23:51 UTC
Created attachment 7922 [details]
xorg.log
Comment 2 veelion (inactive account) 2006-11-29 19:24:09 UTC
Created attachment 7923 [details]
xorg.conf
Comment 3 Gordon Jin 2006-12-01 01:48:29 UTC
This error also happens on i915.
Comment 4 Sérgio M. Basto 2006-12-01 22:41:09 UTC
I have this problem too with my 
00:02.0 VGA compatible controller: Intel Corporation Mobile 915GM/GMS/910GML
Express Graphics Controller (rev 03)

On fedora core 6 
Comment 5 Michel Dänzer 2006-12-07 02:52:05 UTC
*** Bug 9273 has been marked as a duplicate of this bug. ***
Comment 6 Sérgio M. Basto 2006-12-12 13:06:16 UTC
Created attachment 8072 [details]
ldd glxinfo and ldd glxpixmap

update : still happens with libdrm-2.3.0 and Mesa-6.5.2 

glxinfo says direct rendering: Yes
and 
glxpixmap say Direct rendering: No
Comment 7 Michel Dänzer 2006-12-30 02:31:33 UTC
*** Bug 9482 has been marked as a duplicate of this bug. ***
Comment 8 Sérgio M. Basto 2007-01-17 07:08:57 UTC
I upgrade from xorg-x11-drv-i810-1.7.3 to xorg-x11-drv-i810-1.7.4 ,
glxpixmap still the same , but glxdemo and others glxdemos give me this message :
libGL warning: 3D driver claims to not support visual 0x5b
do_wait: drmWaitVBlank returned -1, IRQs don't seem to be working correctly.
Try running with LIBGL_THROTTLE_REFRESH and LIBL_SYNC_REFRESH unset.

I had test it with kernel-2.6.18-1.2869.fc6 and 
kernel-2.6.15-1.2054_FC5 which give exactly the same results. 
Comment 9 Michel Dänzer 2007-01-31 04:56:07 UTC
(In reply to comment #8)
> I upgrade from xorg-x11-drv-i810-1.7.3 to xorg-x11-drv-i810-1.7.4 ,

That's the only difference? A single line of code changed between these, which should only affect traditional dualhead configurations.

> glxpixmap still the same , 

Yes, rendering to GLXPixmaps just isn't supported yet.


> do_wait: drmWaitVBlank returned -1, IRQs don't seem to be working correctly.
> Try running with LIBGL_THROTTLE_REFRESH and LIBL_SYNC_REFRESH unset.

That's a different issue. If you can't resolve this, please file a new bug and attach the full xorg.conf and Xorg.0.log files.

> I had test it with kernel-2.6.18-1.2869.fc6 and 
> kernel-2.6.15-1.2054_FC5 which give exactly the same results. 

Can you try drm git?
Comment 10 Sérgio M. Basto 2007-02-01 14:42:58 UTC
with git drm: 
LIBGL_DEBUG=verbose glxinfo
name of display: :0.0
libGL: XF86DRIGetClientDriverName: 1.7.4 i915tex (screen 0)
libGL: OpenDriver: trying /usr/lib/dri/i915tex_dri.so
drmOpenDevice: node name is /dev/dri/card0
drmOpenDevice: open result is 4, (OK)
drmOpenByBusid: Searching for BusID pci:0000:00:02.0
drmOpenDevice: node name is /dev/dri/card0
drmOpenDevice: open result is 4, (OK)
drmOpenByBusid: drmOpenMinor returns 4
drmOpenByBusid: drmGetBusid reports pci:0000:00:02.0
Error -12
Failed to initialize batch pool - possible incorrect agpgart installed
libGL warning: 3D driver returned no fbconfigs.
libGL error: InitDriver failed
libGL error: reverting to (slow) indirect rendering
display: :0  screen: 0
direct rendering: No

Xorg.0.log says that DRI  is enable but gives this errors : 
cat /var/log/Xorg.0.log| grep "EE\|WW\|AIG"
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(II) Loading extension MIT-SCREEN-SAVER
(==) AIGLX enabled
(WW) I810: No matching Device section for instance (BusID PCI:0:2:1) found
(WW) I810(0): Bad V_BIOS checksum
(WW) I810(0): Bad V_BIOS checksum
(WW) I810(0): Bad V_BIOS checksum
(WW) I810(0): Extended BIOS function 0x5f05 failed.
(EE) AIGLX error: Calling driver entry point failed(EE) AIGLX: reverting to software rendering
Comment 11 Sérgio M. Basto 2007-02-05 20:50:55 UTC
(In reply to comment #10)

> drmOpenByBusid: drmOpenMinor returns 4
> drmOpenByBusid: drmGetBusid reports pci:0000:00:02.0
> Error -12
> Failed to initialize batch pool - possible incorrect agpgart installed
> libGL warning: 3D driver returned no fbconfigs.
> libGL error: InitDriver failed
> libGL error: reverting to (slow) indirect rendering

googling around goes here http://lists.freedesktop.org/archives/xorg/2007-January/020811.html
I try Option "Legacy3D" 
and after disable AIGLX 
Section "ServerFlags"
    Option  "AIGLX" "off"
EndSection

Section "Extensions"
    Option "Composite" "Disable"
EndSection

glxpixmap did work ! (without DRI but works )

and I could play or see cold_war demo in action 

I'd like try the advanced functionality of the i915tex 3D driver but could compile linux-agp-compat , How I do this ?

Conclusion , I think when drmOpenByBusid fail to open device should, fallback to Legacy3D, if it is possible. Because now, this scenario almost hang when I shut down X-windows.
Comment 12 Sérgio M. Basto 2007-02-13 18:02:42 UTC
I just had install new i915 drm with new linux-agp-compat, but things don't change much about this glxpixmap bug.
Seems to me be a bug on AIGLX because as I write on #11, if I turn off AIGLX, glxpixmap works.
Comment 13 Gordon Jin 2007-03-14 19:37:41 UTC
The bug priority was upgraded (P2->high) with the bugzilla configuration change.
I'm Changing the priority back to the normal one.
Sorry for the spam.
Comment 14 Eric Anholt 2007-09-21 14:21:20 UTC
*** Bug 11162 has been marked as a duplicate of this bug. ***
Comment 15 Gordon Jin 2007-11-13 00:45:23 UTC
*** Bug 13214 has been marked as a duplicate of this bug. ***
Comment 16 Gordon Jin 2008-01-07 22:01:09 UTC
*** Bug 13764 has been marked as a duplicate of this bug. ***
Comment 17 Michael Fu 2008-03-06 10:29:03 UTC
Eric, Is this get fixed in TTM?
Comment 18 Michael Fu 2008-06-23 19:55:13 UTC
gordon, could we re-test this on stable release and upstream? thanks.
Comment 19 Gordon Jin 2008-06-24 18:43:43 UTC
Eric says this will be fixed in DRI2.
Comment 20 Gordon Jin 2009-02-23 23:43:43 UTC
This has been fixed in DRI2 (setting UXA with the lastet driver).
Comment 21 Adam Jackson 2009-08-24 12:25:14 UTC
Mass version move, cvs -> git


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.