mirror of
https://github.com/gbowne1/ClassicOS.git
synced 2026-01-29 16:15:20 -08:00
Update pci.c
Change this to use io.h to define the in/out assembly instead of doing directly
This commit is contained in:
12
kernel/pci.c
12
kernel/pci.c
@@ -1,15 +1,5 @@
|
|||||||
#include "pci.h"
|
#include "pci.h"
|
||||||
|
#include "io.h"
|
||||||
/* --- Internal I/O Helpers (If not defined in your kernel) --- */
|
|
||||||
static inline void outl(uint16_t port, uint32_t val) {
|
|
||||||
__asm__ volatile ("outl %0, %1" : : "a"(val), "Nd"(port));
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline uint32_t inl(uint16_t port) {
|
|
||||||
uint32_t ret;
|
|
||||||
__asm__ volatile ("inl %1, %0" : "=a"(ret) : "Nd"(port));
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* --- Configuration Access Functions --- */
|
/* --- Configuration Access Functions --- */
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user