20 #include "modules/Module.h" 21 #include "pedigree/kernel/Log.h" 22 #include "pedigree/kernel/machine/Display.h" 23 #include "pedigree/kernel/machine/Machine.h" 24 #include "pedigree/kernel/processor/MemoryMappedIo.h" 25 #include "pedigree/kernel/processor/Processor.h" 26 #include "pedigree/kernel/processor/types.h" 27 #include "pedigree/kernel/utilities/List.h" 28 #include "pedigree/kernel/utilities/StaticString.h" 32 static bool bFound =
false;
34 void probeDevice(
Device *pDev)
39 for (
size_t i = 0; i < pDev->
addresses().count(); i++)
40 if (!StringCompare(pDev->
addresses()[i]->m_Name,
"bar0"))
44 for (
size_t i = 0; i < pDev->
addresses().count(); i++)
45 if (!StringCompare(pDev->
addresses()[i]->m_Name,
"bar1"))
51 uint32_t strapinfo = pRegs->
read32(NV32_NV10STRAPINFO);
53 "Strapinfo: " <<
Hex << strapinfo
54 <<
", ram: " << ((strapinfo & 0x3ff00000) >> 20));
59 for (
int x = 0; x < 512; x++)
60 for (
int y = 0; y < 512; y++)
61 pFb->
write16(0xF00F, (y * 1024 + x) * 2);
64 for (
int x = 0; x < 128; x++)
65 for (
int y = 256; y < 128 + 256; y++)
66 pFb->
write16(0xFFFF, (y * 1024 + x) * 2);
71 pRegs, pFb, NV40A, NV40 ,
76 pDma->screenToScreenBlit(0, 256, 400, 100, 100, 100);
78 pDma->fillRectangle(600, 600, 100, 100);
97 MODULE_INFO(
"nvidia", &entry, &exit,
"pci");
virtual Vector< Address * > & addresses()
Abstrace base class for hardware I/O capabilities.
static void searchByVendorId(uint16_t vendorId, void(*callback)(Device *), Device *root=0)
virtual void write16(uint16_t value, size_t offset=0)=0
virtual uint32_t read32(size_t offset=0)=0