From 5b237f3832c42179c835e1d1a4b84d75f98f8723 Mon Sep 17 00:00:00 2001 From: "Ronald G. Minnich" Date: Thu, 19 Oct 2000 23:12:13 +0000 Subject: [PATCH] less debuggin --- romimages/RON_WINFAST6300/Makefile | 4 +--- src/lib/linuxpci.c | 16 ++++++++++++---- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/romimages/RON_WINFAST6300/Makefile b/romimages/RON_WINFAST6300/Makefile index f727b18f14..0c0bae7b34 100644 --- a/romimages/RON_WINFAST6300/Makefile +++ b/romimages/RON_WINFAST6300/Makefile @@ -10,8 +10,7 @@ CPUFLAGS += -DINBUF_COPY CPUFLAGS += -DUSE_DOC_MIL CPUFLAGS += -DCMD_LINE='"root=/dev/hda1 single"' -LINUXPATH=$(TOP)/../linux-2.4.0-test6.sis -LINUX=$(LINUXPATH)/vmlinux +LINUX=$(TOP)/../linux-2.4.0-test6.sis TOP=../.. INCLUDES=-nostdinc -I $(TOP)/src/include @@ -29,7 +28,6 @@ OBJECTS += serial_subr.o OBJECTS += mpspec.o OBJECTS += microcode.o OBJECTS += keyboard.o -LINUX=$(TOP)/../linux-2.4.0-test6.sis/ LINK = ld -T ldscript.ld -o $@ $(OBJECTS) CC=cc $(CFLAGS) diff --git a/src/lib/linuxpci.c b/src/lib/linuxpci.c index 7ca4ce71f9..d315acf818 100644 --- a/src/lib/linuxpci.c +++ b/src/lib/linuxpci.c @@ -21,6 +21,7 @@ extern void intel_post(unsigned char value); #define DEBUG +#undef DEBUGSCAN #ifdef DEBUG #define DBG(x...) printk(KERN_DEBUG x) @@ -28,6 +29,12 @@ extern void intel_post(unsigned char value); #define DBG(x...) #endif +#ifdef DEBUGSCAN +#define DBGSCAN(x...) printk(KERN_DEBUG x) +#else +#define DBGSCAN(x...) +#endif + /** * This is the root of the PCI tree. A PCI tree always has * one bus, bus 0. Bus 0 contains devices and bridges. @@ -215,7 +222,8 @@ unsigned int pci_scan_bus(struct pci_bus *bus) // returns 0 anyway. #if GCC_WORKS_ON_O2 if (pcibios_read_config_dword(bus->number, devfn, PCI_VENDOR_ID, &id)) { - DBG("PCI: devfn 0x%x, read_config_dword fails\n", devfn); + DBGSCAN("PCI: devfn 0x%x, read_config_dword fails\n", + devfn); continue; } #endif @@ -223,7 +231,7 @@ unsigned int pci_scan_bus(struct pci_bus *bus) /* some broken boards return 0 if a slot is empty: */ if (id == 0xffffffff || id == 0x00000000 || id == 0x0000ffff || id == 0xffff0000) { - DBG("PCI: devfn 0x%x, bad id 0x%x\n", devfn, id); + DBGSCAN("PCI: devfn 0x%x, bad id 0x%x\n", devfn, id); if (PCI_FUNC(devfn) == 0x00) { /* if this is a function 0 device and it is not present, skip to next device */ @@ -234,12 +242,12 @@ unsigned int pci_scan_bus(struct pci_bus *bus) } if (pcibios_read_config_byte(bus->number, devfn, PCI_HEADER_TYPE, &hdr_type)){ - DBG("PCI: devfn 0x%x, header type read fails\n", devfn); + DBGSCAN("PCI: devfn 0x%x, header type read fails\n", devfn); continue; } if (pcibios_read_config_dword(bus->number, devfn, PCI_CLASS_REVISION, &class)) { - DBG("PCI: devfn 0x%x, class read fails\n", devfn); + DBGSCAN("PCI: devfn 0x%x, class read fails\n", devfn); continue; }