From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <07e1c8ac664d33b92935754d57baf26a@collyer.net> To: 9fans@cse.psu.edu Subject: Re: [9fans] file server page faulting From: Geoff Collyer MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Date: Sat, 14 Sep 2002 19:22:18 -0700 Topicbox-Message-UUID: eb0af348-eaca-11e9-9e20-41e7f4b1d025 > 1. the S3 is sharing the memory; there is no allowance for this, and > when the buffer cache meets the frame buffer horrible things happen My main file server has the SiS 630E chipset in it, which includes a built-in VGA chipset that shares host memory. The motherboard manual says it's the SiS 300 AGP VGA. I added a trivial "pcihinv" command that just calls the otherwise-unused pcihinv function (/sys/src/fs/pc/pci.c:/^pcihinv). Here's what pcihinv had to say: bus dev type vid did intl memory [ ... ] 1 0/0 0300 1039 6300 11 0:f0000008 134217728 1:eb000000 131072 2:0000a801 128 Aperture size and shared memory size may be embedded there somewhere. According to vendor and device ids, this is an SiS 630 integrated AGP VGA at 0xa800. Who knows? The SiS 300 has a different device id (0x300) but some software (e.g., XFree86) treats the 300 and 630 (and 540) similarly. SiS's numbering seems to be intended to obfuscate. I'd been worried about the shared memory too and when I first set up the file server, had odd crashes shortly after boot, so I inserted a PCI VGA card into one of the whopping two (002) PCI slots, and told the BIOS to use it, not the built-in VGA. Eventually, the odd crashes turned out to be an uninitialised FPU, but even after fixing that, I was uneasy about the built-in VGA and so left the PCI VGA card in. However, I have gradually come to the conclusion that, at least for my VGA chipset, it's not a problem for these reasons: - the file server never enables VGA mode but runs the console in CGA mode, which doesn't need much memory anyway (it can only display 2,000 characters), - my BIOS reports that the system has 510MB of normal memory + 2MB of shared video memory (it has 512MB of RAM), now that I've cut the shared memory size down to 2MB in the BIOS (and the aperture down to 4MB), and - prints that I added report that memory bank1 runs up to 0x1fe00000 (534773760 = 510MB exactly), so I assume that the BIOS is claiming only 510MB of RAM or the memory sizing code detects that the memory at 510MB through 512MB behaves strangely and so excludes it. I then built an fs kernel with devwrite() stubbed out, removed the PCI VGA card, booted the no-writes fs kernel, read well over 512MB of distinct data, checked all the file systems (they are roughly 20GB or 40GB each), and everything was still behaving. The checks are significant only because they consume RAM. After running for a while longer, I then booted my normal fs kernel and things are still okay. last boot Thu Sep 12 02:18:44 2002 It's now been over two days, and it's still behaving.