Sakura-IT / SonnetAmiga

Reimplementation of WarpOS supporting Sonnet Crescendo 7200 and other PowerPC PCI cards (mirror of CVS development repository).
MIT License
39 stars 3 forks source link

Use openpci.library so it works on more hardware (enhancement) #45

Closed jcagigal closed 4 years ago

jcagigal commented 6 years ago

Use openpci.library so it works on more hardware (enhancement)

DvdBoon commented 6 years ago

Openpci has not been updated in years and has less drivers available. Not sure mediator is even supported anymore. I would also need to be able to test myself on supported pci bridges as beta testers are few and far in between.

Op ma 10 sep. 2018 15:49 schreef jcagigal notifications@github.com:

Use openpci.library so it works on more hardware (enhancement)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/Sakura-IT/SonnetAmiga/issues/45, or mute the thread https://github.com/notifications/unsubscribe-auth/AKdWEJWPUUwiiC8jS6gPx9GOl0F7ndB4ks5uZm3rgaJpZM4WhcHd .

jcagigal commented 6 years ago

Andreas "Ratte" Pfeiffer, Titan and Tobias "MastaTabs" Seiler updated/used it in the recent years, it supports Amithlon/Mediator1200/Mediator4000/Amithlon/Prometheus(firestorm or the dma enabled spanish flavour)/G-Rex/MorphOS/OS4 with a single binary and works in parallel with native PCI implementation so existing drivers can be used. Some years ago Ratte showed a Radeon driver working on GRex, Mediator4000, Prometheus, Amithlon...

rkujawa commented 6 years ago

As far as I understand, openpci.library in most cases is just a wrapper against native library supporting a particular bridge. This may also be a problem, because it abstracts too much - we need quite low level access to the bridge (so in case of Mediator we'd never be able to switch from Elbox's pci.library to openpci.library). SonnetAmiga is not your typical run-of-the-mill driver.

Btw. There's a GitHub repo with open sourced code of OpenPCI: https://github.com/jeperk/OpenPCI

jcagigal commented 6 years ago

Yes, OpenPCI is usually just a wrapper to "native" pci library. There are OpenPCI USB (ArakAttack), Audio(SBLive) and Ethernet 100 drivers (RTL8139), all of them use DMA. This project is obviously much more complex than a typical driver with DMA access like those but perhaps you could elaborate what low level functions would you need so Titan/Ratte can expand OpenPCI functionality in order to support that.

DvdBoon commented 5 years ago

Seeing @MastaTabs commented in another issue, maybe he can shed his light on this? I thought OpenPCI was dead and does not support Mediator (anymore).

DvdBoon commented 5 years ago

@jcagigal Had a good look at openpci and it is missing PCI memory allocation/freeing functions. With that I mean allocate I/O memory or 'normal' memory' (which info goes into the BARs) and not the PCI DMA memory allocation/freeing functions. pci.library has those.

transi01 commented 5 years ago

How about supporting prometheus.library? Source is available and license for free. Couldn't it be a good idea to support it then? BTW: I have tried Killer 2100 in a PCI to PCIe adapter and with prominfo the killer is visible as PPC processor while starting Prmscan!

DvdBoon commented 5 years ago

@transi01 Which PCI to PCIe adapter did you use?

I looked at pci.library and it supports multiple busses, but still not sure if it supports PCI configuration type 1. Next to that, the prometheus does not come with 3.3V. That being said, I am waiting on new Firestorm/prometheus cards (now that they are open source) that would fit in my A3000. And not too expensive.

DvdBoon commented 5 years ago

Regarding PCI configuration type 1 of the mediator. I see the findpcidevice function supporting bus/device/func. (<<8, <<3, 0) and this has been introduced in V6 of the pci,library (MKII?). Maybe pciinfo was not updated to use this? I need to test it but I don't like buying all the stuff for nothing.

Also, the K1/M1 seems to be very picky in what slot it is. I am not sure If I want to support these kind of cards at all. Lot of complaining from ppl.

transi01 commented 5 years ago

I am using "PCI to PCI Express adapter from Startech.com which is using a "PI7C9X PCI Express-to-PCI Reversible Bridge" chip on it.

I'm using the Prometheus Board which HESE is using for his remake of the AA3000+ Board ant it supports 3,3V also. Additionaly the now free PCB and logic files from E3B does also support 3,3V as a card like original prometheus but now using XILINX instead of old ALTERA CPLD's. I'm now going to build such a board which then can be put in every ZORRO III Slot of an amiga. If it might help, I can support you with a board if you are interested.

Well even if the K1/M1 are not the best, they are definitely the best for the buck and much better at the moment is the Killer 2100 cause it has 128MB on board instead of only 64 like the M1 / K1.

The Killer 2100 cost at the moment about 15 bucks so it's very interesting to be supported.

As far as I know is that the mediator itself is the problem in not supporting cards in any slot.....

// Thomas

DvdBoon commented 5 years ago

@transi01 I am definitely interested in such a board. It could be even on loan so I can return it after I am done with it, or then buy it from you.

transi01 commented 5 years ago

@DvdBoon Yes, we can do it eather way. But now PCB's are ordered and it will take a while to assemple them and test them when ready. How can we stay in touch?

// Thomas

DvdBoon commented 5 years ago

@transi01 These are zorro 3 cards right? You can reach me on dennisvdboon@gmail.com.

An initial test on my system regarding PCI configuration type 1 seems to indicate that the mediator is not supporting it. Trying to get info from any other bus then 0 still returns info from bus 0.

I am waiting on some feedback from someone with an actual pcie bridge card in his mediator.

tkurbad commented 4 years ago

@DvdBoon die you have the opportunity to test with a real PCIE bridge already? I could try with the combination @transi01 mentioned in my Mediator A3/4000T in an A4000T once my Mediator is reassembled and working again. Probably at the end of next week.

DvdBoon commented 4 years ago

@tkurbad Elbox has confirmed that the current mediator drivers do not support bridges. I am waiting for any of the FireStorms to emerge. In the meantime I am doing a C version of the library for easier maintenance and updating.

tkurbad commented 4 years ago

Ah, I'm about to build hese's AA3000+ and Firebird (aka Firestorm), too. If this would work with the 2100 in the new library someday, I'd be VERY happy! However, although I've got all the parts to build the AA3000+, time is an issue with this big project. So I guess some Firestorm could be ready before I am. If not, I am of course willing to test whatever has to be tested once the AA is operational.

DvdBoon commented 4 years ago

They are having trouble with the Xilinx chips it seems regarding the Firestorm.

tkurbad commented 4 years ago

Well, hese's variant still uses the Altera FPGAs.

DvdBoon commented 4 years ago

This will not be done as part of the current assembly version of the library. Refer to https://github.com/Sakura-IT/PowerPCAmiga