forked from AbleOS/ableos
Device work
This commit is contained in:
parent
7d4b12a103
commit
f64f654610
|
@ -89,19 +89,17 @@ GetBARAddr := fn(addr: PCIAddress, index: int): u32 {
|
|||
}
|
||||
|
||||
setup_device := fn(svga_dev: ^SVGADevice): void {
|
||||
// TODO: Fix this
|
||||
// TODO: Fix this
|
||||
// refer to https://git.ablecorp.us/able/vmware-svga/src/commit/eea7ddcd0d34702f8f0a33c1933718706c6318c5/lib/refdriver/svga.c#L55
|
||||
|
||||
|
||||
svga_dev.pciAddr = PCIAddress.(0, 3, 0)
|
||||
/*
|
||||
pci_id := get_ids(svga_dev.pciAddr.bus, svga_dev.pciAddr.device, svga_dev.pciAddr.function)
|
||||
pci_dev := pci.check_device(0, 3)
|
||||
|
||||
if pci_id.vendor != PCI_VENDOR_ID_VMWARE | pci_id.device != PCI_DEVICE_ID_VMWARE_SVGA2 {
|
||||
if pci_dev.device_id.vendor != PCI_VENDOR_ID_VMWARE {
|
||||
log.error("SVGA device not found\0")
|
||||
return
|
||||
}
|
||||
*/
|
||||
//| pci_dev.device_id.device != PCI_DEVICE_ID_VMWARE_SVGA2 {
|
||||
|
||||
svga_dev.ioBase = config_read32(svga_dev.pciAddr.bus, svga_dev.pciAddr.device, svga_dev.pciAddr.function, 0x10) & 0xFFFFFFF0
|
||||
write_reg(svga_dev, reg.SVGA_REG_ENABLE, reg.SVGA_REG_ENABLE_ENABLE)
|
||||
|
|
|
@ -20,14 +20,14 @@ resolution = "1024x768x24"
|
|||
# [boot.limine.ableos.modules.tests]
|
||||
# path = "boot:///tests.hbf"
|
||||
|
||||
# [boot.limine.ableos.modules.0serial_driver]
|
||||
# [boot.limine.ableos.modules.serial_driver]
|
||||
# path = "boot:///serial_driver.hbf"
|
||||
|
||||
# [boot.limine.ableos.modules.diskio_driver]
|
||||
# path = "boot:///diskio_driver.hbf"
|
||||
|
||||
# [boot.limine.ableos.modules.render_example]
|
||||
# path = "boot:///render_example.hbf"
|
||||
[boot.limine.ableos.modules.render_example]
|
||||
path = "boot:///render_example.hbf"
|
||||
|
||||
# [boot.limine.ableos.modules.serial_driver_test]
|
||||
# path = "boot:///serial_driver_test.hbf"
|
||||
|
@ -41,11 +41,11 @@ resolution = "1024x768x24"
|
|||
# [boot.limine.ableos.modules.dt_buffer_test]
|
||||
# path = "boot:///dt_buffer_test.hbf"
|
||||
|
||||
[boot.limine.ableos.modules.svga_driver]
|
||||
path = "boot:///svga_driver.hbf"
|
||||
# [boot.limine.ableos.modules.svga_driver]
|
||||
# path = "boot:///svga_driver.hbf"
|
||||
|
||||
# [boot.limine.ableos.modules.ps2_driver]
|
||||
# path = "boot:///ps2_driver.hbf"
|
||||
[boot.limine.ableos.modules.ps2_driver]
|
||||
path = "boot:///ps2_driver.hbf"
|
||||
|
||||
# [boot.limine.ableos.modules.filesystem_fat32]
|
||||
# path = "boot:///filesystem_fat32.hbf"
|
||||
|
|
Loading…
Reference in a new issue