From: Philip Homburg Date: Tue, 11 Apr 2006 11:50:29 +0000 (+0000) Subject: Extra debug output for iogap. X-Git-Tag: v3.1.2a~33 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/zpipe.c?a=commitdiff_plain;h=867e30469aa377b59ac927781c4235519ce86a3f;p=minix.git Extra debug output for iogap. --- diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index d9783da0a..d93ce70e8 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -1251,6 +1251,13 @@ PRIVATE void complete_bars() continue; if (base+size <= iogap_low) continue; + if (debug) + { + printf( + "pci device %d (%04x/%04x), bar %d: base 0x%x, size 0x%x\n", + i, pcidev[i].pd_vid, pcidev[i].pd_did, + j, base, size); + } if (base+size-iogap_low < iogap_high-base) iogap_low= base+size; else @@ -1259,7 +1266,14 @@ PRIVATE void complete_bars() } if (iogap_high < iogap_low) - panic("pci", "iogap_high too low", iogap_high); + { + if (debug) + { + printf("iogap_high too low, should panic\n"); + } + else + panic("pci", "iogap_high too low", iogap_high); + } if (debug) printf("I/O range = [0x%x..0x%x>\n", iogap_low, iogap_high); @@ -1506,10 +1520,13 @@ int busind; } return 0; } - printf("(warning) unsupported ISA bridge %04X/%04X for bus %d\n", - pcidev[unknown_bridge].pd_vid, - pcidev[unknown_bridge].pd_did, - busind); + if (debug) + { + printf( + "(warning) unsupported ISA bridge %04X/%04X for bus %d\n", + pcidev[unknown_bridge].pd_vid, + pcidev[unknown_bridge].pd_did, busind); + } return 0; }