PCI: use dev_printk in x86 quirk messages

Convert quirk printks to dev_printk().

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


authored by

bjorn.helgaas@hp.com and committed by
Greg Kroah-Hartman
9ed88554 f0fda801

+34 -31
+23 -20
arch/x86/kernel/quirks.c
··· 30 raw_pci_ops->read(0, 0, 0x40, 0x4c, 2, &word); 31 32 if (!(word & (1 << 13))) { 33 - printk(KERN_INFO "Intel E7520/7320/7525 detected. " 34 - "Disabling irq balancing and affinity\n"); 35 #ifdef CONFIG_IRQBALANCE 36 irqbalance_disable(""); 37 #endif ··· 104 pci_read_config_dword(dev, 0xF0, &rcba); 105 rcba &= 0xFFFFC000; 106 if (rcba == 0) { 107 - printk(KERN_DEBUG "RCBA disabled. Cannot force enable HPET\n"); 108 return; 109 } 110 111 /* use bits 31:14, 16 kB aligned */ 112 rcba_base = ioremap_nocache(rcba, 0x4000); 113 if (rcba_base == NULL) { 114 - printk(KERN_DEBUG "ioremap failed. Cannot force enable HPET\n"); 115 return; 116 } 117 ··· 124 /* HPET is enabled in HPTC. Just not reported by BIOS */ 125 val = val & 0x3; 126 force_hpet_address = 0xFED00000 | (val << 12); 127 - printk(KERN_DEBUG "Force enabled HPET at base address 0x%lx\n", 128 - force_hpet_address); 129 iounmap(rcba_base); 130 return; 131 } ··· 144 if (err) { 145 force_hpet_address = 0; 146 iounmap(rcba_base); 147 - printk(KERN_DEBUG "Failed to force enable HPET\n"); 148 } else { 149 force_hpet_resume_type = ICH_FORCE_HPET_RESUME; 150 - printk(KERN_DEBUG "Force enabled HPET at base address 0x%lx\n", 151 - force_hpet_address); 152 } 153 } 154 ··· 211 if (val & 0x4) { 212 val &= 0x3; 213 force_hpet_address = 0xFED00000 | (val << 12); 214 - printk(KERN_DEBUG "HPET at base address 0x%lx\n", 215 - force_hpet_address); 216 return; 217 } 218 ··· 232 /* HPET is enabled in HPTC. Just not reported by BIOS */ 233 val &= 0x3; 234 force_hpet_address = 0xFED00000 | (val << 12); 235 - printk(KERN_DEBUG "Force enabled HPET at base address 0x%lx\n", 236 - force_hpet_address); 237 cached_dev = dev; 238 force_hpet_resume_type = OLD_ICH_FORCE_HPET_RESUME; 239 return; 240 } 241 242 - printk(KERN_DEBUG "Failed to force enable HPET\n"); 243 } 244 245 /* ··· 297 */ 298 if (val & 0x80) { 299 force_hpet_address = (val & ~0x3ff); 300 - printk(KERN_DEBUG "HPET at base address 0x%lx\n", 301 - force_hpet_address); 302 return; 303 } 304 ··· 312 pci_read_config_dword(dev, 0x68, &val); 313 if (val & 0x80) { 314 force_hpet_address = (val & ~0x3ff); 315 - printk(KERN_DEBUG "Force enabled HPET at base address 0x%lx\n", 316 - force_hpet_address); 317 cached_dev = dev; 318 force_hpet_resume_type = VT8237_FORCE_HPET_RESUME; 319 return; 320 } 321 322 - printk(KERN_DEBUG "Failed to force enable HPET\n"); 323 } 324 325 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8235, ··· 347 pci_read_config_dword(dev, 0x44, &val); 348 force_hpet_address = val & 0xfffffffe; 349 force_hpet_resume_type = NVIDIA_FORCE_HPET_RESUME; 350 - printk(KERN_DEBUG "Force enabled HPET at base address 0x%lx\n", 351 force_hpet_address); 352 cached_dev = dev; 353 return;
··· 30 raw_pci_ops->read(0, 0, 0x40, 0x4c, 2, &word); 31 32 if (!(word & (1 << 13))) { 33 + dev_info(&dev->dev, "Intel E7520/7320/7525 detected; " 34 + "disabling irq balancing and affinity\n"); 35 #ifdef CONFIG_IRQBALANCE 36 irqbalance_disable(""); 37 #endif ··· 104 pci_read_config_dword(dev, 0xF0, &rcba); 105 rcba &= 0xFFFFC000; 106 if (rcba == 0) { 107 + dev_printk(KERN_DEBUG, &dev->dev, "RCBA disabled; " 108 + "cannot force enable HPET\n"); 109 return; 110 } 111 112 /* use bits 31:14, 16 kB aligned */ 113 rcba_base = ioremap_nocache(rcba, 0x4000); 114 if (rcba_base == NULL) { 115 + dev_printk(KERN_DEBUG, &dev->dev, "ioremap failed; " 116 + "cannot force enable HPET\n"); 117 return; 118 } 119 ··· 122 /* HPET is enabled in HPTC. Just not reported by BIOS */ 123 val = val & 0x3; 124 force_hpet_address = 0xFED00000 | (val << 12); 125 + dev_printk(KERN_DEBUG, &dev->dev, "Force enabled HPET at " 126 + "0x%lx\n", force_hpet_address); 127 iounmap(rcba_base); 128 return; 129 } ··· 142 if (err) { 143 force_hpet_address = 0; 144 iounmap(rcba_base); 145 + dev_printk(KERN_DEBUG, &dev->dev, 146 + "Failed to force enable HPET\n"); 147 } else { 148 force_hpet_resume_type = ICH_FORCE_HPET_RESUME; 149 + dev_printk(KERN_DEBUG, &dev->dev, "Force enabled HPET at " 150 + "0x%lx\n", force_hpet_address); 151 } 152 } 153 ··· 208 if (val & 0x4) { 209 val &= 0x3; 210 force_hpet_address = 0xFED00000 | (val << 12); 211 + dev_printk(KERN_DEBUG, &dev->dev, "HPET at 0x%lx\n", 212 + force_hpet_address); 213 return; 214 } 215 ··· 229 /* HPET is enabled in HPTC. Just not reported by BIOS */ 230 val &= 0x3; 231 force_hpet_address = 0xFED00000 | (val << 12); 232 + dev_printk(KERN_DEBUG, &dev->dev, "Force enabled HPET at " 233 + "0x%lx\n", force_hpet_address); 234 cached_dev = dev; 235 force_hpet_resume_type = OLD_ICH_FORCE_HPET_RESUME; 236 return; 237 } 238 239 + dev_printk(KERN_DEBUG, &dev->dev, "Failed to force enable HPET\n"); 240 } 241 242 /* ··· 294 */ 295 if (val & 0x80) { 296 force_hpet_address = (val & ~0x3ff); 297 + dev_printk(KERN_DEBUG, &dev->dev, "HPET at 0x%lx\n", 298 + force_hpet_address); 299 return; 300 } 301 ··· 309 pci_read_config_dword(dev, 0x68, &val); 310 if (val & 0x80) { 311 force_hpet_address = (val & ~0x3ff); 312 + dev_printk(KERN_DEBUG, &dev->dev, "Force enabled HPET at " 313 + "0x%lx\n", force_hpet_address); 314 cached_dev = dev; 315 force_hpet_resume_type = VT8237_FORCE_HPET_RESUME; 316 return; 317 } 318 319 + dev_printk(KERN_DEBUG, &dev->dev, "Failed to force enable HPET\n"); 320 } 321 322 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8235, ··· 344 pci_read_config_dword(dev, 0x44, &val); 345 force_hpet_address = val & 0xfffffffe; 346 force_hpet_resume_type = NVIDIA_FORCE_HPET_RESUME; 347 + dev_printk(KERN_DEBUG, &dev->dev, "Force enabled HPET at 0x%lx\n", 348 force_hpet_address); 349 cached_dev = dev; 350 return;
+11 -11
arch/x86/pci/fixup.c
··· 17 int pxb, reg; 18 u8 busno, suba, subb; 19 20 - printk(KERN_WARNING "PCI: Searching for i450NX host bridges on %s\n", pci_name(d)); 21 reg = 0xd0; 22 for(pxb = 0; pxb < 2; pxb++) { 23 pci_read_config_byte(d, reg++, &busno); ··· 41 */ 42 u8 busno; 43 pci_read_config_byte(d, 0x4a, &busno); 44 - printk(KERN_INFO "PCI: i440KX/GX host bridge %s: secondary bus %02x\n", pci_name(d), busno); 45 pci_scan_bus_with_sysdata(busno); 46 pcibios_last_bus = -1; 47 } ··· 55 */ 56 int i; 57 58 - printk(KERN_WARNING "PCI: Fixing base address flags for device %s\n", pci_name(d)); 59 for(i = 0; i < 4; i++) 60 d->resource[i].flags |= PCI_BASE_ADDRESS_SPACE_IO; 61 } ··· 68 * Fix class to be PCI_CLASS_STORAGE_SCSI 69 */ 70 if (!d->class) { 71 - printk(KERN_WARNING "PCI: fixing NCR 53C810 class code for %s\n", pci_name(d)); 72 d->class = PCI_CLASS_STORAGE_SCSI << 8; 73 } 74 } ··· 80 * SiS 5597 and 5598 chipsets require latency timer set to 81 * at most 32 to avoid lockups. 82 */ 83 - DBG("PCI: Setting max latency to 32\n"); 84 pcibios_max_latency = 32; 85 } 86 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_5597, pci_fixup_latency); ··· 138 139 pci_read_config_byte(d, where, &v); 140 if (v & ~mask) { 141 - printk(KERN_WARNING "Disabling VIA memory write queue (PCI ID %04x, rev %02x): [%02x] %02x & %02x -> %02x\n", \ 142 d->device, d->revision, where, v, mask, v & mask); 143 v &= mask; 144 pci_write_config_byte(d, where, v); ··· 200 * Apply fixup if needed, but don't touch disconnect state 201 */ 202 if ((val & 0x00FF0000) != 0x00010000) { 203 - printk(KERN_WARNING "PCI: nForce2 C1 Halt Disconnect fixup\n"); 204 pci_write_config_dword(dev, 0x6c, (val & 0xFF00FFFF) | 0x00010000); 205 } 206 } ··· 348 pci_read_config_word(pdev, PCI_COMMAND, &config); 349 if (config & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) { 350 pdev->resource[PCI_ROM_RESOURCE].flags |= IORESOURCE_ROM_SHADOW; 351 - printk(KERN_DEBUG "Boot video device is %s\n", pci_name(pdev)); 352 } 353 } 354 DECLARE_PCI_FIXUP_FINAL(PCI_ANY_ID, PCI_ANY_ID, pci_fixup_video); ··· 388 /* verify the change for status output */ 389 pci_read_config_byte(dev, 0x50, &val); 390 if (val & 0x40) 391 - printk(KERN_INFO "PCI: Detected MSI K8T Neo2-FIR, " 392 "can't enable onboard soundcard!\n"); 393 else 394 - printk(KERN_INFO "PCI: Detected MSI K8T Neo2-FIR, " 395 - "enabled onboard soundcard.\n"); 396 } 397 } 398 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8237,
··· 17 int pxb, reg; 18 u8 busno, suba, subb; 19 20 + dev_warn(&d->dev, "Searching for i450NX host bridges\n"); 21 reg = 0xd0; 22 for(pxb = 0; pxb < 2; pxb++) { 23 pci_read_config_byte(d, reg++, &busno); ··· 41 */ 42 u8 busno; 43 pci_read_config_byte(d, 0x4a, &busno); 44 + dev_info(&d->dev, "i440KX/GX host bridge; secondary bus %02x\n", busno); 45 pci_scan_bus_with_sysdata(busno); 46 pcibios_last_bus = -1; 47 } ··· 55 */ 56 int i; 57 58 + dev_warn(&d->dev, "Fixing base address flags\n"); 59 for(i = 0; i < 4; i++) 60 d->resource[i].flags |= PCI_BASE_ADDRESS_SPACE_IO; 61 } ··· 68 * Fix class to be PCI_CLASS_STORAGE_SCSI 69 */ 70 if (!d->class) { 71 + dev_warn(&d->dev, "Fixing NCR 53C810 class code\n"); 72 d->class = PCI_CLASS_STORAGE_SCSI << 8; 73 } 74 } ··· 80 * SiS 5597 and 5598 chipsets require latency timer set to 81 * at most 32 to avoid lockups. 82 */ 83 + dev_dbg(&d->dev, "Setting max latency to 32\n"); 84 pcibios_max_latency = 32; 85 } 86 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_5597, pci_fixup_latency); ··· 138 139 pci_read_config_byte(d, where, &v); 140 if (v & ~mask) { 141 + dev_warn(&d->dev, "Disabling VIA memory write queue (PCI ID %04x, rev %02x): [%02x] %02x & %02x -> %02x\n", \ 142 d->device, d->revision, where, v, mask, v & mask); 143 v &= mask; 144 pci_write_config_byte(d, where, v); ··· 200 * Apply fixup if needed, but don't touch disconnect state 201 */ 202 if ((val & 0x00FF0000) != 0x00010000) { 203 + dev_warn(&dev->dev, "nForce2 C1 Halt Disconnect fixup\n"); 204 pci_write_config_dword(dev, 0x6c, (val & 0xFF00FFFF) | 0x00010000); 205 } 206 } ··· 348 pci_read_config_word(pdev, PCI_COMMAND, &config); 349 if (config & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) { 350 pdev->resource[PCI_ROM_RESOURCE].flags |= IORESOURCE_ROM_SHADOW; 351 + dev_printk(KERN_DEBUG, &pdev->dev, "Boot video device\n"); 352 } 353 } 354 DECLARE_PCI_FIXUP_FINAL(PCI_ANY_ID, PCI_ANY_ID, pci_fixup_video); ··· 388 /* verify the change for status output */ 389 pci_read_config_byte(dev, 0x50, &val); 390 if (val & 0x40) 391 + dev_info(&dev->dev, "Detected MSI K8T Neo2-FIR; " 392 "can't enable onboard soundcard!\n"); 393 else 394 + dev_info(&dev->dev, "Detected MSI K8T Neo2-FIR; " 395 + "enabled onboard soundcard\n"); 396 } 397 } 398 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8237,