From: Ronald G Minnich <[EMAIL PROTECTED]>: > On Tue, 12 Mar 2002, Christer Weinigel wrote: > > > different beast from the SC2200. The GX1 CPU core is mostly the same, > > so the code that has to do with GX_BASE, the 0x22/0x23 config > > registers the PCI functions and the RAM sizing should work with minor > > modifications. Any code using the SuperIO or the Config Base > > Registers will need to be modified. > > uh oh :-) > > what's a Config Base register ...
And to follow up again. The history of the Geode is rather interesting. Once upon a time Cyrix did an (almost-)PC-on-a-chip solution that was called the Cyrix MediaGX. It was a Pentium class processor with its own bus and a chipset called CS5520 or CS5530. The MediaGX processor contains the memory controller and half of the graphics support. It has a "Unified Memory Architecture", where part of memory is used as graphics memory. It also has some basic acceleration support for doing bitblts and color expansion. The companion chip contains the video clock generator and the D/A converters and the video data is transferred over a custom pixel bus from the MediaGX to the companion chip. Audio (AC97), IDE and USB also resides in the companion chip. The MediaGX/CS5530 combo also has something called VSA which means that it can trap accesses to legacy ports such as the keyboard, serial ports, printer, VGA and so on. Accessing one of those ports will cause a SMI interrupt and then those devices can then be emulated. That way one could for example have a custom keyboard connected via some GPIO pinns and emulate a PS/2 keyboard so well that even Linux won't see a differene, and it'll still work even in protected mode. This is also how the MediaGX becomes (sort of) VGA and Soundblaster compatible (with a few, eh, interesting bugs of course). To build a "real PC" using a MediaGX/CS5530 design, all that's needed is a SuperI/O to provide the RTC, the serial, parallel and keyboard ports. So it's really a PC-on-three-chips solution. To get sound an AC97 codec is needed. What happened then is that National Semiconductor bought the MediaGX and renamed it to Geode. They did some silicon improvements and reduced the power consumption and increased the clock frequency, I think that they also added MMX support, but that might have been done by Cyrix already. Now for the low-level stuff... The Geode CPU itself contains the north bridge and something called and X-bus that communicates with the companion chip. Most of the core CPU functions are controlled via the inb/outb 0x22/0x23 registers which are documented in the GX1 manual. Some other functions of the northbrigde are controlled via the PCI configuration registers found at bus 0, device 0, function 0. Most of the integrated functions of the CPU are controlled via something called GX_BASE, a MMIO region for the memory controller, graphics memory, graphics acceleration functions, video controller (the video clock is generated by the companion chip though), yet some odd things. The CS5530 manual is also available from the National WWW pages. It is mostly configured using the PCI function found at bus 0, device 12 and function 0-5 (PCI Bridge controller, IDE controller, Audio Controller, Video controller and X-Bus controller). So for example the video clock generator is a part of the video controller. The SuperIO is just an normal SuperIO and is configured the same way as any other SuperIO. Most designs I've seen have been using a NatSemi PC97317 or similar chip. For the SC1200, SC2200 and SC3200 National has integrated a Geode procesor, most of a CS5530A and SuperI/O on one chip. Besides that, all processors have a built in watchdog timer, a GPIO interface and something called a high speed timer. Then the different models have some specific features, for example, the SC1200 has a TV output and video input and is intended for set top box applications. They have also cleaned up some of the PC cruft from the MediaGX, so for example, it's much easier to connect a Disk on Chip or flash chip to the SCx200 chips compared to the MediaGX. To the programmer, most of the MediaGX functionality is still there, there is still a northbridge pci controller, the 0x22/0x23 CPU control, and GX_BASE are still there. The companion chip pci controller on device 12 also still there but has new PCI vendor and device IDs and are slightly different in places. Addidtionally there is something called the Configuration Block that is used for some chip specific configuration and to control the GPIO pins and the built in watchdog timer. You can figure most of this out by looking at the product sheets available on Nationals WWW pages and by reading the source of some drivers. If you want to know more about the SCx200 you have to sign an NDA with National and ask for the data books. I hope this gives a bit of an idea of how the different Geode processors are interrelated. With all that said, it ought to be rather easy to remove any SCx200 specific stuff from my code and use the GX1 and CS5530A data sheets to fill in the rest. The GX1/CS5530 is a bit nicer than the SCx200 too since it doesn't have as many shared pins, with the SC2200 it's theoretically possible to fry the TFT screen from software by using the wrong shared function, I don't think it's possible to do the same with a GX1/CS5530. I'll try to dig up a GX1/CS5530 based board to play with, so if you want me to try out anything, please just tell me. :-) /Christer (being boring, PSB) -- "Just how much can I get away with and still go to heaven?"
