Convert drivers using PCI to latest MAME PCI interface.
MAME currently has two PCI systems: the older “legacy PCI” system and its successor. A number of drivers are still using the legacy system. This situation has persisted for over half a decade now, and really needs to be addressed. If we’re missing new-style PCI device implementations for any components, they need to be created, and drivers need to be migrated. There is to be no further development on legacy PCI devices – it’s wasted effort.
Drivers using legacy PCI include:
- [ ] src/mame/pc/at.cpp (ficpio2 VT82C496G, probably others)
- [ ] src/mame/pc/atpci.cpp (i430hx, SiS 85C501, i430tx)
- [ ] src/mame/be/bebox.cpp (mpc105)
- [ ] src/mame/pc/calchase.cpp (via vpx clone)
- [x] src/mame/misc/comebaby.cpp (i440bx)
- [ ] src/mame/konami/cobra.cpp (mpc106)
- [x] src/mame/pc/fruitpc.cpp (ST STPCD0166BTC3 SoC)
- [ ] src/mame/misc/funkball.cpp (Cyrix CX5520)
- [x] ~~src/mame/drivers/gamecstl.cpp~~ moved to src/mame/pc/sis630.cpp
- [x] src/mame/misc/gammagic.cpp (i430hx, one of the M55Hi-Plus BIOSes with El Torito BIOS)
- [ ] src/mame/misc/magictg.cpp (Galileo GT-64010A-B-0)
- [ ] src/mame/atari/mediagx.cpp (P5GX-LG MediaGX)
- [x] src/mame/midway/midqslvr.cpp (i440bx)
- [ ] src/mame/sega/model3.cpp (mpc105/mpc106)
- [x] src/mame/pc/nforcepc.cpp
- [x] src/mame/funworld/photoply.cpp (SiS85C496 + SiS85C497)
- [ ] src/mame/midway/pinball2k.cpp (MediaGX + CX5520)
- [ ] src/mame/pc/queen.cpp (VIA Apollo VXPro)
- [x] src/mame/misc/savquest.cpp (i440bx)
- [x] src/mame/taito/taitowlf.cpp (i82439TX + i82371AB)
- [ ] src/mame/konami/viper.cpp (mpc8240)
- [x] src/mame/misc/voyager.cpp (VIA KT133a)
- [x] src/mame/misc/xtom3d.cpp (i440zx)
- [ ] src/mame/konami/gticlub.cpp (k033906 PCI bridge)
- [ ] src/mame/konami/hornet.cpp (k033906 PCI bridge)
- [ ] src/mame/konami/nwk-tr.cpp (k033906 PCI bridge)
- [ ] get rid of
bus/lpci
There are relatively few legacy PCI devices, mainly contained within the src/devices/bus/lpci directory.
This interface is incomplete for the purposes of at586, as there are devices required by at586 which need to be able to hook up custom registers in the configuration space. The new interface can't do this as far as I can tell.
Huh? The configuration memory map is virtual for that reason. Look at i82875p for instance, it adds a bunch of registers.
OG.
On Tue, Mar 1, 2016 at 4:51 AM, MoochMcGee [email protected] wrote:
This interface is incomplete for the purposes of at586, as there are devices required by at586 which need to be able to hook up custom registers in the configuration space. The new interface can't do this as far as I can tell.
— Reply to this email directly or view it on GitHub https://github.com/mamedev/mame/issues/391#issuecomment-190527535.
Got an hard time understanding what's "Legacy" PCI, nowadays, my best guess is anything prefixed by L (lpci) therefore any class in lpci.h should be marked with the [[deprecated("use non-legacy PCI device")] marker?
Break down OP message with tasks, marked drivers as resolved where #include "machine/lpci.h" is not found with current tree.
Errata: there are THREE PCI bus implementations, the proper one is actually in src/devices/machine/pci.cpp
Added model3.cpp: does its own PCI bus implementation, which for all purposes fits here.
Mind adding any drivers using the k033906.cpp PCI bridge device. The three drivers that use this are gticlub.cpp, nwk-tr.cpp and hornet.cpp.
Good call, added. Also I'll change directory entry over the new format later on.
Converted misc\comebaby.cpp to base PCI driver in PR #10830 , it wasn't doing anything useful to warrant using the legacy hookup. I'll deal with full conversion later since being i440bx.
ETA: same deal for pc\quakeat.cpp, a driver that doesn't even have a BIOS hooked up ...
Updated OP message with easy to track base chipsets for x86 based systems.
Updated OP with the (mostly) i440bx additions from PR#11037. As for the others:
- queen.cpp can be converted to stub PCI driver (as per voyager.cpp), unless anybody wants to tackle VIA architecture. That will be needed by calchase.cpp anyway;
- taitowlf.cpp can now be completely wiped off, since we have everything necessary to emulate a base P5TX-LA including the Winbond Super I/O and the onboard ATI Rage II. pf2012 parallel/game port loading is special but I guess we cross that bridge after we have a solid i82439TX and not the other way around.
konami/viper.cppshould be easy now, given its limited PCI use beyond Voodoo itself.funworld/photoply.cpptracked bysis85c496in https://github.com/mamedev/mame/blob/master/src/mame/pc/pcipc_sis.cppmisc/savquest.cpptracked bypciagpin https://github.com/mamedev/mame/blob/master/src/mame/pc/pcipc.cpp
Edited OP with remaining blanks (in particular PPC chipset targets).
https://github.com/mamedev/mame/commit/6e1f17f676b772944049d5bfebda82bf51b228d4 takes care of funworld/photoply.cpp