[MPlayer-dev-eng] mga_vid memory detection error

Christian Ohm chr.ohm at gmx.net
Mon Dec 2 21:28:38 CET 2002


On Monday,  2 December 2002 at  9:35, Sytse Wielinga wrote:
> On Fri, Oct 04, 2002 at 01:46:08AM +0200, Arpi wrote:
> > > Since "lspci -v" reports "16Mb", wouldn't it be a good idea to use the
> > > subsystem vendor/device id for the memory detection?
> > 
> > hmm
> > 
> > > 01:00.0 VGA compatible controller: Matrox Graphics, Inc. MGA G400 AGP (rev
> > > 04) (prog-if 00 [VGA])
> > > 	Subsystem: Matrox Graphics, Inc. Millennium G400 Dual Head 16Mb
> > > 	Flags: bus master, medium devsel, latency 32, IRQ 10
> > > 	Memory at d4000000 (32-bit, prefetchable) [size=32M]
> > in the first versions i uded this as memory size -------^^^ badly as you can
> > see, so i've changed it to use chip configuration register flags as the docs
> > said. also bad...
> > 
> > i wonder where is that 16Mb above comes from...
> 
> Like he said, the subsystem vendor/device id. My guess is that the
> 102b:0328 version of the G400 is buggy. I have the 102b:0338 version and
> it correctly says it has 16M of memory in the configuration register
> flags. Using the configuration registers still is the right thing to do,
> though, as future revisions will still be supported without adding
> support for the new pci id's; you should add a check for the 102b:0328
> pci subsystem device id and use 16M instead of 32M in that case.

if someone implements this: i have a 16mb g400 with the id 102b:19d8 where
mga_vid also detects 32mb, so this id should also get an extra check.

another idea would be a memory size option to the module to override the
detection.

bye,
christian ohm

-- 
Imagination is more important than knowledge.
		-- Albert Einstein



More information about the MPlayer-dev-eng mailing list