[MPlayer-dev-eng] [PATCH] mga_vid memory detection error

Dagfinn Ilmari Mannsåker ilmari at ping.uio.no
Thu Feb 27 15:32:46 CET 2003


Christian Ohm <chr.ohm at gmx.net> writes:

> 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?
[snip]
>> 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.

I just wrote a patch for this, overriding the memory size on all the
models mentioned here. Output when loading on an affected board:

Matrox MGA G200/G400/G450/G550 YUV Video interface v2.01 (c) Aaron Holtzman & A'rpi
mga_vid: Found MGA G400/G450
mga_vid: MMIO at 0xce95c000 IRQ: 11 framebuffer: 0xE6000000
mga_vid: OPTION word: 0x50044120  mem: 0x10  SGRAM
mga_vid: Detected 16MB card reporting 32MB RAMSIZE, overriding
mga_vid: detected RAMSIZE is 16 MB
syncfb (mga): IRQ disabled in mga_vid.c

Patch attached.

-- 
ilmari

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: mga-mem-override.dif
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20030227/0254c729/attachment.asc>


More information about the MPlayer-dev-eng mailing list