Tracking down bug #12503, looking for comment on my theory

Alex Deucher alexdeucher at gmail.com
Sat Jan 19 08:53:08 PST 2008


On Jan 17, 2008 11:38 AM, Alex Villací­s Lasso <a_villacis at palosanto.com> wrote:
> Alex Villací­s Lasso escribió:
> > I post this so that the experts on the mailing list can tell me whether
> > my understanding of the problem is sane (or insane). All comments apply
> > to my home machine, which reserves 16M for video memory reports the
> > following on lspci -v:
> >
> > 01:00.0 VGA compatible controller: S3 Inc. VT8375 [ProSavage8 KM266/KL266]
> > (prog-if 00 [VGA])
> >         Subsystem: S3 Inc. VT8375 [ProSavage8 KM266/KL266]
> >         Flags: bus master, 66MHz, medium devsel, latency 32, IRQ 11
> >         Memory at dfe80000 (32-bit, non-prefetchable) [size=512K]
> >         Memory at d0000000 (32-bit, prefetchable) [size=128M]
> >         Expansion ROM at dfe70000 [disabled] [size=64K]
> >         Capabilities: [dc] Power Management version 2
> >         Capabilities: [80] AGP version 2.0
> >
> >
> >
> >
>
>
> > Looking at the code, there are several things that might be wrong with this:
> > 1) Previously, all the areas got mapped with xf86MapPciMem() and the
> > VIDMEM_MMIO flag, and the function sorted out the write-combining later.
> > The proof is that the message (==) SAVAGE(0): Write-combining range
> > (0xd0000000,0x8000000) eventually appeared. Now, all the areas
> > (including MMIO) are being mapped as VIDMEM_FRAMEBUFFER. This can't be
> > right... or is it?
> >
> > src/savage_driver.c line 3163
> > -------------------
> >     if (psav->MmioRegion.memory == NULL) {
> > #ifdef XSERVER_LIBPCIACCESS
> >         err = pci_device_map_range(psav->PciInfo, psav->MmioRegion.base,
> >                                    psav->MmioRegion.size,
> >                                    (PCI_DEV_MAP_FLAG_WRITABLE),
> >                                    & psav->MmioRegion.memory);
> > #else
> >         psav->MmioRegion.memory =
> >             xf86MapPciMem(pScrn->scrnIndex, VIDMEM_FRAMEBUFFER, /* <---
> > Should this be VIDMEM_MMIO instead? */
> >                           psav->PciTag, psav->MmioRegion.base,
> >                           psav->MmioRegion.size);
> >         err = (psav->MmioRegion.memory == NULL) ? errno : 0;
> > #endif
> > -------------------
> > In my opinion, this is the most likely cause of the hang, since videoram
> > detection, MCLK detection, and colormap all require register (MMIO)
> > access, and all of these are affected prior to the hang.
> >
> As I suspected, changing the highlighted VIDMEM_FRAMEBUFFER to
> VIDMEM_MMIO fixes the lockup and lets the X server start up normally.
> Patch attached, already attached to bug #12503. However, now
> acceleration is broken with the patch applied (but no lockups). If any
> of you have a Savage card, could you please test this patch? I would
> eventually like to have it merged into current git.

Yes this patch is correct.  now what happens with accel?  Can you
explain further?

Alex



More information about the xorg mailing list