[avivo] Error reading EDID

Nicolas Trangez eikke at eikke.com
Mon Jul 16 09:11:47 PDT 2007


On Mon, 2007-07-16 at 06:34 -0700, Dan Nicholson wrote:
> On 7/16/07, Nicolas Trangez <eikke at eikke.com> wrote:
> > >  Also you will need
> > > to use
> > > some command line options to make using gdb usable start the Xserver
> > > with these
> > > two  options:
> > >
> > >     -keeptty -dumbSched
> > >
> > > -keeptty allows you to ^C to get into gdb at anytime
> > > -dumpSched stops the smart scheduler interrupting each time you step
> > Might be interesting, thanks.
> 
> http://xorg.freedesktop.org/wiki/Development/Documentation/ServerDebugging
Thanks for all the help. I finally decided to go somewhere I got another
machine around, and got into GDB. Here's the notes I made, I hope these
are useful:

at avivo_output_lfo_get_modes
Breakpoint 10, avivo_output_lfp_get_modes (output=0x82934d0)
    at avivo_output.c:268
268         struct avivo_info *avivo = avivo_get_info(output->scrn);
(gdb) print *output
$17 = {scrn = 0x8281430, crtc = 0x0, possible_crtcs = 1, possible_clones
= 3,
  interlaceAllowed = 0, doubleScanAllowed = 0, probed_modes = 0x0,
  options = 0x8293530, conf_monitor = 0x0, initial_x = 0, initial_y = 0,
  initial_rotation = 0, status = XF86OutputStatusUnknown, MonInfo = 0x0,
  subpixel_order = 0, mm_width = 0, mm_height = 0, name = 0x8293528
"LFP",
  funcs = 0xb7bd3140, driver_private = 0x8282d08, use_screen_monitor =
0,
  randr_output = 0x0}

after avivo_get_info:
(gdb) print *avivo
$18 = {entity = 0x8281ea0, device = 0x8277550,
  chipset = CHIP_FAMILY_RV530_M56, pci_info = 0x827d848, pci_tag =
65536,
  vbios = 0x8283288 "U�~�o\002", rom_header = 522, master_data = 45314,
  is_atom_bios = 1, bpp = 4, fb_use_shadow = 1, fb_shadow = 0x0,
  create_screen_resources = 0, ctrl_addr = 4261347328, fb_addr =
3221225472,
  ctrl_size = 65536, fb_size = 268435456, ctrl_base = 0xb7b80000,
  fb_base = 0xa7b80000, saved_state = {mc_memory_map = 0,
vga_memory_base = 0,
    vga_fb_start = 0, vga_mystery0 = 0, vga_mystery1 = 0,
    pll1_post_div_cntl = 0, pll1_post_div = 0, pll1_post_div_mystery =
0,
    pll1_post_mul = 0, pll1_divider_cntl = 0, pll1_divider = 0,
    pll1_mystery0 = 0, pll1_mystery1 = 0, pll2_post_div_cntl = 0,
    pll2_post_div = 0, pll2_post_div_mystery = 0, pll2_post_mul = 0,
    pll2_divider_cntl = 0, pll2_divider = 0, pll2_mystery0 = 0,
    pll2_mystery1 = 0, crtc_pll_source = 0, crtc1_h_total = 0,
    crtc1_h_blank = 0, crtc1_h_sync_wid = 0, crtc1_h_sync_pol = 0,
    crtc1_v_total = 0, crtc1_v_blank = 0, crtc1_v_sync_wid = 0,
    crtc1_v_sync_pol = 0, crtc1_cntl = 0, crtc1_mode = 0,
    crtc1_60c0_mystery = 0, crtc1_scan_enable = 0, crtc1_fb_format = 0,
    crtc1_fb_location = 0, crtc1_fb_end = 0, crtc1_pitch = 0,
    crtc1_x_length = 0, crtc1_y_length = 0, crtc1_fb_height = 0,
    crtc1_offset_start = 0, crtc1_offset_end = 0, crtc1_expn_size = 0,
    crtc1_expn_cntl = 0, crtc1_6594 = 0, crtc1_659c = 0, crtc1_65a4 = 0,
    crtc1_65a8 = 0, crtc1_65ac = 0, crtc1_65b0 = 0, crtc1_65b8 = 0,
    crtc1_65bc = 0, crtc1_65c0 = 0, crtc1_65c8 = 0, crtc2_h_total = 0,
    crtc2_h_blank = 0, crtc2_h_sync_wid = 0, crtc2_h_sync_pol = 0,
    crtc2_v_total = 0, crtc2_v_blank = 0, crtc2_v_sync_wid = 0,
    crtc2_v_sync_pol = 0, crtc2_cntl = 0, crtc2_mode = 0,
    crtc2_scan_enable = 0, crtc2_fb_format = 0, crtc2_fb_location = 0,
    crtc2_fb_end = 0, crtc2_pitch = 0, crtc2_x_length = 0,
crtc2_y_length = 0,
    dac1_cntl = 0, dac1_mystery1 = 0, dac1_mystery2 = 0, tmds1_cntl = 0,
    tmds1_mystery1 = 0, tmds1_mystery2 = 0, tmds1_clock_cntl = 0,
    tmds1_mystery3 = 0, dac2_cntl = 0, dac2_mystery1 = 0, dac2_mystery2
= 0,
    tmds2_cntl = 0, tmds2_mystery1 = 0, tmds2_mystery2 = 0,
    tmds2_clock_cntl = 0, tmds2_mystery3 = 0, cursor1_cntl = 0,
    cursor1_location = 0, cursor1_size = 0, cursor1_position = 0},
  close_screen = 0, options = 0x8282d38, lfp_fixed_mode = 0x0,
  cursor_offset = 0, cursor_format = 0, cursor_fg = 0, cursor_bg = 0,
  cursor_width = 0, cursor_height = 0, cursor_x = 0, cursor_y = 0}


259         edid_mon = xf86OutputGetEDID(output, avivo_output->i2c);
(gdb) print avivo_output->i2c
$20 = (I2CBusPtr) 0x8293478
(gdb) print *avivo_output->i2c
$21 = {BusName = 0x8282d20 "LFP connector 1", scrnIndex = 0,
  I2CUDelay = 0x8126e4c <I2CUDelay>,
  I2CPutBits = 0xb7bcf078 <avivo_i2c_put_bits>,
  I2CGetBits = 0xb7bceffc <avivo_i2c_get_bits>,
  I2CStart = 0x8126f64 <I2CStart>, I2CAddress = 0x81274ab <I2CAddress>,
  I2CStop = 0x8127009 <I2CStop>, I2CPutByte = 0x81271f7 <I2CPutByte>,
  I2CGetByte = 0x8127388 <I2CGetByte>, DriverPrivate = {ptr = 0x7e30,
    val = 32304, uval = 32304, fptr = 0x7e30}, HoldTime = 5, BitTimeout
= 5,
  ByteTimeout = 5, AcknTimeout = 5, StartTimeout = 5, RiseFallTime = 2,
  FirstDev = 0x0, NextBus = 0x8282c40, I2CWriteRead = 0x81275d1
<I2CWriteRead>}
(gdb) next
Error reading EDID block
Error reading EDID block
Error reading EDID block
Error reading EDID block
No EDID block returned

260         xf86OutputSetEDID(output, edid_mon);
(gdb) print edid_mon
$22 = (xf86MonPtr) 0x0
(gdb) next
261         modes = xf86OutputGetEDIDModes(output);
(gdb) next
262         return modes;
(gdb) print modes
$23 = (DisplayModePtr) 0x0

avivo_output_lfp_get_modes (output=0x82934d0) at avivo_output.c:272
272         xf86DeleteMode(&avivo->lfp_fixed_mode,
avivo->lfp_fixed_mode);
(gdb) print modes
$24 = (DisplayModePtr) 0x0
(gdb) print avivo->lfp_fixed_mode
$25 = (DisplayModePtr) 0x0
(gdb) next
273         avivo->lfp_fixed_mode = xf86DuplicateMode(modes);

(gdb) step
xf86DuplicateMode (pMode=0x0) at xf86Modes.c:193
193         pNew = xnfalloc(sizeof(DisplayModeRec));
(gdb)
XNFalloc (amount=156) at utils.c:1364
1364        if ((long)amount <= 0)
(gdb)
1369        amount = (amount + (sizeof(long) - 1)) & ~(sizeof(long) -
1);
(gdb)
1370        ptr = (pointer)malloc(amount);
(gdb)
1371        if (!ptr)
(gdb)
1375        return ((unsigned long *)ptr);
(gdb)
1376    }
(gdb)
xf86DuplicateMode (pMode=0x0) at xf86Modes.c:194
194         *pNew = *pMode;
(gdb)

Program received signal SIGSEGV, Segmentation fault.
0xb7d46b0c in memcpy () from /lib/libc.so.6


Looks like something goes wrong in xf86OutputGetEDID, I should step in
there too I guess.

Attached you can find an output of the small script as shown on the page
Dan linked to.

Thanks,

Nicolas
> 
> --
> Dan
-------------- next part --------------
(gdb) Reading symbols from /home/nicolas/Projects/jhbuild/root/bin/Xorg...done.
Using host libthread_db library "/lib/libthread_db.so.1".
(gdb) (gdb) Signal        Stop	Print	Pass to program	Description
SIGUSR1       No	Yes	Yes		User defined signal 1
(gdb) Signal        Stop	Print	Pass to program	Description
SIGUSR2       No	Yes	Yes		User defined signal 2
(gdb) Signal        Stop	Print	Pass to program	Description
SIGPIPE       No	Yes	Yes		Broken pipe
(gdb) Starting program: /home/nicolas/Projects/jhbuild/root/bin/Xorg -config /root/xorg.conf.new :2
InitConnectionLimits: MaxClients = 256
_XSERVTransSocketOpenCOTSServer: Unable to open socket for inet6
_XSERVTransOpen: transport open failed for inet6/sky:2
_XSERVTransMakeAllCOTSServerListeners: failed to open listener for inet6

X Window System Version 7.2.0
Release Date: 21 December 2005
X Protocol Version 11, Revision 0, Release 7.2
Build Operating System: Linux 2.6.22 i686 
Current Operating System: Linux sky 2.6.22 #1 SMP PREEMPT Fri Jul 13 18:25:03 CEST 2007 i686
Build Date: 16 July 2007  04:08:09PM
 
	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
Module Loader present
Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.2.log", Time: Mon Jul 16 16:45:56 2007
Converted `%A' to `/root/xorg.conf.new'
(++) Using config file: "/root/xorg.conf.new"
Found 1 screens in the layout section X.org ConfiguredFound 0 inactive devices in the layout section X.org ConfiguredFound 2 input devices in the layout section X.org Configuredxf86ReadBIOS: BIOS at 0x000f8000 has signature 0x7440
ACPI: OSPMOpen called
ACPI: Opening device
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules//libpcidata.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/extensions//libdbe.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/extensions//libdri.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/extensions//libextmod.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/extensions//libglx.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/extensions//librecord.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/extensions//libxtrap.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/fonts//libfreetype.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/fonts//libtype1.so)
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules/drivers//avivo_drv.so)
(EE) Failed to load module "mouse" (module does not exist, 0)
(EE) Failed to load module "kbd" (module does not exist, 0)
pciBusAccessDisable: bus=6
pciBusAccessDisable: bus=4
pciBusAccessDisable: bus=3
pciBusAccessDisable: bus=2
pciBusAccessDisable: bus=1
pciIo_MemAccessDisable: 0x10000
avivo instances found: 1
avivo instances found: 1
avivo: card at 1:0:0 is claimed by a Device section
xf86AllocateScreen - xf86Screens[0]->pScreen = (nil)
b-b conflict w: a0000 affff
b-b conflict w: b0000 b7fff
b-b conflict w: b8000 bffff
b-b conflict w: 3b0 3bb
b-b conflict w: 3c0 3df
Enable access 0
pciSetBusAccess: route VGA to bus 1
pciBusAccessEnable: bus=1
pciIo_MemAccessEnable: 0x10000
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules//libfb.so)
(II) Module "ramdac" already built-in
LoaderOpen(/home/nicolas/Projects/jhbuild/root/lib/xorg/modules//libvgahw.so)
base: fdff0000, realBase: fdff0000, alignOff: 0 
base: b7ba0000 aligned base: b7ba0000
base: c0000000, realBase: c0000000, alignOff: 0 
base: a7ba0000 aligned base: a7ba0000
WC_BASE: 0xc0000000 WC_END: 0xcfffffff
Sections to follow: 0
xf86RegisterRootWindowProperty(0, 69, 19, 8, 128, 0x8294598)
new property filled
creating xf86RegisteredPropertiesTable[] size 1
xf86RegisteredPropertiesTable 0x8294640
xf86RegisteredPropertiesTable[0] (nil)
xf86RegisterRootWindowProperty succeeded
Error reading EDID block
Error reading EDID block
Error reading EDID block
Error reading EDID block
No EDID block returned

Program received signal SIGSEGV, Segmentation fault.
0xb7d66b0c in memcpy () from /lib/libc.so.6
(gdb) Undefined command: "module".  Try "help".
(gdb) #0  0xb7d66b0c in memcpy () from /lib/libc.so.6
#1  0x08119d67 in xf86DuplicateMode (pMode=0x0) at xf86Modes.c:194
#2  0xb7bef820 in avivo_output_lfp_get_modes (output=0x82934d0)
    at avivo_output.c:273
#3  0x081154e1 in xf86ProbeOutputModes (scrn=0x8281430, maxX=2048, maxY=2048)
    at xf86Crtc.c:1288
#4  0x08115db3 in xf86InitialConfiguration (scrn=0x8281430, canGrow=0)
    at xf86Crtc.c:1557
#5  0xb7bf06b6 in avivo_preinit (screen_info=0x8281430, flags=0) at avivo.c:452
#6  0x080b5b28 in InitOutput (pScreenInfo=0x8270040, argc=4, argv=0xbfd92be4)
    at xf86Init.c:574
#7  0x0806def2 in main (argc=4, argv=0xbfd92be4, envp=0xbfd92bf8) at main.c:369
(gdb) Continuing.

Backtrace:
0: /home/nicolas/Projects/jhbuild/root/bin/Xorg [0x80dd802]
1: /home/nicolas/Projects/jhbuild/root/bin/Xorg(xf86SigHandler+0xa3) [0x80dd7ae]
2: [0xb7fb5420]
3: /home/nicolas/Projects/jhbuild/root/lib/xorg/modules/drivers//avivo_drv.so(avivo_output_lfp_get_modes+0x59) [0xb7bef820]
4: /home/nicolas/Projects/jhbuild/root/bin/Xorg(xf86ProbeOutputModes+0x1fd) [0x81154e1]
5: /home/nicolas/Projects/jhbuild/root/bin/Xorg(xf86InitialConfiguration+0x112) [0x8115db3]
6: /home/nicolas/Projects/jhbuild/root/lib/xorg/modules/drivers//avivo_drv.so [0xb7bf06b6]
7: /home/nicolas/Projects/jhbuild/root/bin/Xorg(InitOutput+0x865) [0x80b5b28]
8: /home/nicolas/Projects/jhbuild/root/bin/Xorg(main+0x3e2) [0x806def2]
9: /lib/libc.so.6(__libc_start_main+0xdc) [0xb7d11824]
10: /home/nicolas/Projects/jhbuild/root/bin/Xorg(FontFileCompleteXLFD+0xb1) [0x806da51]

Fatal server error:
Caught signal 11.  Server aborting

pciIo_MemAccessDisable: 0x10000
pciIo_MemAccessDisable: 0x10000
pciIo_MemAccessDisable: 0x10000
pciBusAccessDisable: bus=6
pciBusAccessDisable: bus=4
pciBusAccessDisable: bus=3
pciBusAccessDisable: bus=2
pciBusAccessDisable: bus=1
ACPI: Closing device

Program received signal SIGABRT, Aborted.
0xb7fb5410 in __kernel_vsyscall ()
(gdb) 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg/attachments/20070716/13af80c4/attachment.pgp>


More information about the xorg mailing list