aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/pci
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/pci')
-rw-r--r--src/kernel/pci/pci.c12
-rw-r--r--src/kernel/pci/pci.h4
2 files changed, 8 insertions, 8 deletions
diff --git a/src/kernel/pci/pci.c b/src/kernel/pci/pci.c
index 435752d..abccb00 100644
--- a/src/kernel/pci/pci.c
+++ b/src/kernel/pci/pci.c
@@ -3,7 +3,7 @@
#include <kernel/io/io.h>
#include <kernel/lib/lib.h>
-void pci_write_field(uint32_t device, int field, int size, uint32_t value)
+void pci_write_field(uint32_t device, int field, uint32_t value)
{
outl(PCI_ADDRESS_PORT, pci_get_addr(device, field));
outl(PCI_VALUE_PORT, value);
@@ -107,7 +107,7 @@ void pci_remap()
}
uint32_t out = 0;
memcpy(&out, &pci_remaps, 4);
- pci_write_field(pci_isa, 0x60, 4, out);
+ pci_write_field(pci_isa, 0x60, out);
}
}
@@ -123,17 +123,17 @@ int pci_get_interrupt(uint32_t device)
if (pci_remaps[pirq] >= 0x80) {
if (int_line == 0xFF) {
int_line = 10;
- pci_write_field(device, PCI_INTERRUPT_LINE, 1, (uint32_t)int_line);
+ pci_write_field(device, PCI_INTERRUPT_LINE, (uint32_t)int_line);
}
pci_remaps[pirq] = (uint8_t)int_line;
uint32_t out = 0;
memcpy(&out, &pci_remaps, 4);
- pci_write_field(pci_isa, 0x60, 4, out);
+ pci_write_field(pci_isa, 0x60, out);
return int_line;
}
- pci_write_field(device, PCI_INTERRUPT_LINE, 1, pci_remaps[pirq]);
+ pci_write_field(device, PCI_INTERRUPT_LINE, pci_remaps[pirq]);
return pci_remaps[pirq];
} else {
return (int)pci_read_field(device, PCI_INTERRUPT_LINE, 1);
}
-} \ No newline at end of file
+}
diff --git a/src/kernel/pci/pci.h b/src/kernel/pci/pci.h
index 6c14dfd..fc4bb5d 100644
--- a/src/kernel/pci/pci.h
+++ b/src/kernel/pci/pci.h
@@ -87,7 +87,7 @@ static inline uint32_t pci_box_device(int bus, int slot, int func)
uint32_t pci_read_field(uint32_t device, int field, int size);
-void pci_write_field(uint32_t device, int field, int size, uint32_t value);
+void pci_write_field(uint32_t device, int field, uint32_t value);
uint16_t pci_find_type(uint32_t dev);
@@ -105,4 +105,4 @@ void pci_remap();
int pci_get_interrupt(uint32_t device);
-#endif \ No newline at end of file
+#endif