After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 572623 - X error in gnome_rr_screen_set_size
X error in gnome_rr_screen_set_size
Status: RESOLVED FIXED
Product: gnome-desktop
Classification: Core
Component: libgnome-desktop
2.25.x
Other Linux
: High critical
: ---
Assigned To: Desktop Maintainers
Desktop Maintainers
Depends on:
Blocks: randr-tracker
 
 
Reported: 2009-02-21 02:27 UTC by Jens Granseuer
Modified: 2009-07-31 16:11 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jens Granseuer 2009-02-21 02:27:57 UTC
I get this in g-s-d when trying to change the resolution (2.25.91):

  • #0 gdk_x_error
    at gdkmain-x11.c line 614
  • #1 xkl_process_error
    from /usr/lib/libxklavier.so.12
  • #2 _XError
    at XlibInt.c line 2905
  • #3 process_responses
    at xcb_io.c line 138
  • #4 _XReply
    at xcb_io.c line 370
  • #5 XSync
    at Sync.c line 48
  • #6 _XSyncFunction
    at Synchro.c line 37
  • #7 XRRSetScreenSize
    at XrrScreen.c line 245
  • #8 gnome_rr_screen_set_size
    at gnome-rr.c line 611
  • #9 crtc_assignment_apply
    at gnome-rr-config.c line 1669
  • #10 gnome_rr_config_apply
    at gnome-rr-config.c line 1166
  • #11 gnome_rr_config_apply_from_filename
    at gnome-rr-config.c line 1259
  • #12 try_to_apply_intended_configuration
    at gsd-xrandr-manager.c line 254
  • #13 gsd_xrandr_manager_apply_configuration
    at gsd-xrandr-manager.c line 280
  • #14 dbus_glib_marshal_gsd_xrandr_manager_BOOLEAN__POINTER
    at gsd-xrandr-manager-glue.h line 94
  • #15 ??
    from /usr/lib/libdbus-glib-1.so.2
  • #16 ??
    from /lib/libdbus-1.so.3
  • #17 dbus_connection_dispatch
    from /lib/libdbus-1.so.3
  • #18 ??
    from /usr/lib/libdbus-glib-1.so.2
  • #19 g_main_context_dispatch
    from /lib/libglib-2.0.so.0
  • #20 ??
    from /lib/libglib-2.0.so.0
  • #21 g_main_loop_run
    from /lib/libglib-2.0.so.0
  • #22 IA__gtk_main
    at gtkmain.c line 1200
  • #23 main
    at main.c line 489

The program 'gnome-settings-daemon' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadMatch (invalid parameter attributes)'.
  (Details: serial 29174 error_code 8 request_code 149 minor_code 7)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)

Using the nv driver (2.1.12).

Probably got a number of duplicates in g-s-d, too, but none of them currently has a stacktrace with --sync.
Comment 1 Jens Granseuer 2009-02-23 20:40:09 UTC
Another point of interest: Only seems to happen when going from large to small, not when increasing resolution (also when switching from small to large, then reverting in the confirmation dialog).
Comment 2 Vincent Untz 2009-03-03 16:37:50 UTC
Jens: would be interesting to know if trunk (or 2.25.92 which I'll release in a few minutes) still has this issue. One change got reverted there... But I'm not quite sure it'll help...
Comment 3 Jens Granseuer 2009-03-05 18:38:08 UTC
Yes, the problem's still there in .92.
Comment 4 Federico Mena Quintero 2009-03-06 01:31:04 UTC
Is your stack trace with --sync?
Comment 5 Jens Granseuer 2009-03-06 08:14:31 UTC
Of course.
Comment 6 Federico Mena Quintero 2009-03-06 17:26:35 UTC
I was looking at the X server to see what would return BadMatch from RRSetScreenSize...

Could you paste the output of "xrandr -q" *before* you try to change your resolution?  Then, see if it BadMatches again.
Comment 7 Jens Granseuer 2009-03-06 18:01:37 UTC
$ xrandr -q
Screen 0: minimum 320 x 175, current 1600 x 1200, maximum 1600 x 1200
default connected 1600x1200+0+0 0mm x 0mm
   1600x1200      75.0*    70.0     65.0     60.0  
   1400x1050      75.0     60.0  
   1280x1024      85.0     75.0     60.0  
   1280x960       85.0     60.0  
   1152x864      100.0     85.0     75.0  
   1024x768      100.0     85.0     75.0     70.0     60.0     87.0  
   960x720        60.0  
   928x696        60.0  
   896x672        60.0  
   832x624        75.0  
   800x600       100.0     85.0     75.0     72.0     70.0     65.0     60.0     56.0  
   700x525        75.0     60.0  
   640x512        85.0     75.0     60.0  
   640x480        75.0     60.0     85.0     73.0  
   720x400        70.0     85.0  
   640x400        85.0  
   576x432        75.0  
   640x350        85.0  
   512x384        85.0     75.0     70.0     60.0     87.0  
   416x312        75.0  
   400x300        85.0     75.0     72.0     60.0     56.0  
   320x240        85.0     75.0     73.0     60.0  
   360x200        85.0  
   320x200        85.0  
   320x175        85.0  

Still crashes.
Comment 8 Federico Mena Quintero 2009-03-06 18:06:06 UTC
Note to self:

xserver/randr/rrscreen.c:ProcRRSetScreenSize() - will BadMatch if a crtc has a bigger mode than the newly-requested size.  Will BadMatch if RRScreenSizeSet() returns false...

RRScreenSizeSet() - returns the result of pScrPriv->rrScreenSetSize, which is implemented in...

xserver/hw/xfree86/modes/xf86RandR12.c:xf86RandR12ScreenSetSize() - calls the driver's "resize" method; that's the only way it could return false.

For your nv driver, that would be...

xf86-video-nv/src/g80_driver.c:G80ResizeScreen() - always returns true.

So, the only way that ProcRRSetScreenSize() could BadMatch would be due to a too-big crtc.  However, both xrandr(1) and gnome-rr-config do this:

1. disable too-big crtcs
2. XRRSetScreenSize()
3. reconfigure crtcs with the new modes

So I don't really know what's going on in your machine :)
Comment 9 Federico Mena Quintero 2009-03-06 18:06:54 UTC
Hum, your "xrandr -q" says your output is called "default".  This only happens if your driver doesn't support RANDR 1.2.

What does "xrandr --version" say?
Comment 10 Jens Granseuer 2009-03-06 19:01:22 UTC
$ xrandr --version
Server reports RandR version 1.2

> xf86-video-nv/src/g80_driver.c:G80ResizeScreen() - always returns true.

I don't have a G80, so this is the wrong function to look at.
Comment 11 Federico Mena Quintero 2009-03-06 19:17:16 UTC
Argh, sorry, this reports the protocol version, not the driver version.

In general we can't rely on drivers that don't support RANDR 1.2.  We already have a driver_is_1_0() function that we don't use yet; I'm thinking of making g-s-d not do anything if it finds itself faced with an old driver.

Would it be too much to ask that you build your X server with debug info and step through ProcRRSetScreenSize(), to see where it returns BadMatch for you?
Comment 12 Jens Granseuer 2009-03-06 20:23:06 UTC
I have X server debugging symbols, but I don't know how to debug into it since attaching gdb obviously makes X not respond anymore which in turn makes me unable to get to gdb. I don't have remote debugging capabilities.
Comment 13 Vincent Untz 2009-07-28 16:12:57 UTC
Jens: is this still valid? Or are you finally able to change your resolution?
Comment 14 Jens Granseuer 2009-07-31 16:11:56 UTC
Seems to work ok in 2.27.