summaryrefslogtreecommitdiff
path: root/src/arch/amd64/pci.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch/amd64/pci.c')
-rw-r--r--src/arch/amd64/pci.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/arch/amd64/pci.c b/src/arch/amd64/pci.c
index 0deac03..7b30f0e 100644
--- a/src/arch/amd64/pci.c
+++ b/src/arch/amd64/pci.c
@@ -102,12 +102,10 @@ static struct pci_table_entry *load_device(struct pci_device dev) {
entry->prog_if = (dword2 >> 8) & 0xFF;
entry->revision = dword2 & 0xFF;
- print_device(entry);
return entry;
}
void pci_init(void) {
- kprintf("PCI DEVICES\n");
pci_table_next = 0;
struct pci_device pcidev;
for(int bus = 0; bus < 256; bus++) {
@@ -134,6 +132,10 @@ void pci_init(void) {
}
}
}
+ kprintf("PCI DEVICES\n");
+ for (size_t i = 0; i < pci_table_next; i++) {
+ print_device(&pci_table[i]);
+ }
kprintf("\n");
}