I know I’ve been taking a bit of a break from PPC development – I have exams and other end-of-the-academic-year related stuff to take care of for the next two weeks, so expect a slowdown until I have all that taken care of. I did manage to start on a new project that encompasses rewriting several drivers, I started simple, rewriting the GxDMA.dll driver which is essentially a wrapper to some functions in DDI.dll. The dll has 3 exports, DmaDRAMtoVRAM, DmaVRAMtoDRAM and IsDMAReady. These are all found in the GxDMA class, located in the PrimGPE class – you can get an instance of the object by calling GetPrimaryGPE() in DDI. The class looks something like this:
class GxDMA
{
public:
GxDMA();
virtual DWORD DmaDRAMtoVRAM(DWORD dwLeft, DWORD dwTop, DWORD dwWidth, DWORD dwHeight);
virtual DWORD DmaVRAMtoDRAM(DWORD dwLeft, DWORD dwTop, DWORD dwWidth, DWORD dwHeight);
virtual BOOL IsDMAReady(DWORD dwSrcAddr);
};
I made some small optimizations, taking out a useless sanity check and returning true immediately for IsDMAReady (it seems that GxDMA::IsDMAReady() also just returns true). Source code to be available when I understand more of this stuff.
Download: nueDriverProject