diff options
| author | Miguel <m.i@gmx.at> | 2018-08-22 15:16:26 +0200 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2018-08-22 15:16:26 +0200 |
| commit | d57a38d7fa9501a5ec17f75a1efaef9d62df5bef (patch) | |
| tree | 508eb0131ba6d241f69483e3b7a9d556f786643f /driver/pci.c | |
| parent | eddfc270d887283674563530b9fd982a2692f8c3 (diff) | |
improving logging
Diffstat (limited to 'driver/pci.c')
| -rw-r--r-- | driver/pci.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/driver/pci.c b/driver/pci.c index a8cd68b..7ad5daa 100644 --- a/driver/pci.c +++ b/driver/pci.c @@ -3,7 +3,6 @@ #include "kernel/kernel.h" #include "asm/x86.h" #include "e1000.h" -#include "lib/logger/log.h" // logger facilities #define PCI_CONFIG_DATA 0xCFC #define PCI_CONFIG_ADDRESS 0xCF8 @@ -66,7 +65,7 @@ void test_bar(uint8_t bus, uint8_t slot, uint8_t offset) pciConfigSet(bus,slot,0,offset,(bar_high<<16)+bar_low); - log("e1000",FOOLOS_LOG_INFO,"%s bar: (0x%x 0x%x) size: 0x%x" ,bar_low&1?"i/o":"mem",bar_high, bar_low, size); + log("e1000",5,"%s bar: (0x%x 0x%x) size: 0x%x" ,bar_low&1?"i/o":"mem",bar_high, bar_low, size); } @@ -80,7 +79,7 @@ uint16_t pciCheck(uint8_t bus, uint8_t slot) if ((vendor = pciConfigReadWord(bus,slot,0,0)) != 0xFFFF) { device = pciConfigReadWord(bus,slot,0,2); - log(FOOLOS_MODULE_NAME,FOOLOS_LOG_INFO,"[%d,%d]: vendor: 0x%x / device: 0x%x",bus,slot,vendor,device); + log(FOOLOS_MODULE_NAME,5,"[%d,%d]: vendor: 0x%x / device: 0x%x",bus,slot,vendor,device); // check for: E1000 (82540EM). PCI Ethernet Controller if(vendor==0x8086&&device==0x100e) @@ -112,7 +111,7 @@ uint16_t pciCheck(uint8_t bus, uint8_t slot) void pci_init() { - log(FOOLOS_MODULE_NAME,FOOLOS_LOG_INFO,"scanning bus"); + log(FOOLOS_MODULE_NAME,5,"scanning bus"); // todo: recurse on pci to pci bridges! // todo: support multiple pci host controllers! // (check more funcitons of device 0:0) |
