Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

parport: Convert printk(KERN_<LEVEL> to pr_<level>(

Use the more common kernel style.

Miscellanea:

o Coalesce formats
o Realign arguments

Signed-off-by: Joe Perches <joe@perches.com>
Reviewed-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Link: https://lore.kernel.org/r/20200403134325.11523-2-sudipm.mukherjee@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Joe Perches and committed by
Greg Kroah-Hartman
decf26f6 d98ce9fe

+110 -146
+2 -4
drivers/parport/daisy.c
··· 145 145 ((num_ports = num_mux_ports(port)) == 2 || num_ports == 4)) { 146 146 /* Leave original as port zero. */ 147 147 port->muxport = 0; 148 - printk(KERN_INFO 149 - "%s: 1st (default) port of %d-way multiplexor\n", 148 + pr_info("%s: 1st (default) port of %d-way multiplexor\n", 150 149 port->name, num_ports); 151 150 for (i = 1; i < num_ports; i++) { 152 151 /* Clone the port. */ ··· 158 159 continue; 159 160 } 160 161 161 - printk(KERN_INFO 162 - "%s: %d%s port of %d-way multiplexor on %s\n", 162 + pr_info("%s: %d%s port of %d-way multiplexor on %s\n", 163 163 extra->name, i + 1, th[i + 1], num_ports, 164 164 port->name); 165 165
+2 -2
drivers/parport/ieee1284.c
··· 319 319 #ifndef CONFIG_PARPORT_1284 320 320 if (mode == IEEE1284_MODE_COMPAT) 321 321 return 0; 322 - printk (KERN_ERR "parport: IEEE1284 not supported in this kernel\n"); 322 + pr_err("parport: IEEE1284 not supported in this kernel\n"); 323 323 return -1; 324 324 #else 325 325 int m = mode & ~IEEE1284_ADDR; ··· 674 674 ssize_t parport_read (struct parport *port, void *buffer, size_t len) 675 675 { 676 676 #ifndef CONFIG_PARPORT_1284 677 - printk (KERN_ERR "parport: IEEE1284 not supported in this kernel\n"); 677 + pr_err("parport: IEEE1284 not supported in this kernel\n"); 678 678 return -ENODEV; 679 679 #else 680 680 int mode = port->physport->ieee1284.mode;
+1 -2
drivers/parport/ieee1284_ops.c
··· 579 579 pr_debug("ECP read timed out at 45\n"); 580 580 581 581 if (command) 582 - printk (KERN_WARNING 583 - "%s: command ignored (%02x)\n", 582 + pr_warn("%s: command ignored (%02x)\n", 584 583 port->name, byte); 585 584 586 585 break;
+1 -1
drivers/parport/parport_amiga.c
··· 212 212 if (err) 213 213 goto out_irq; 214 214 215 - printk(KERN_INFO "%s: Amiga built-in port using irq\n", p->name); 215 + pr_info("%s: Amiga built-in port using irq\n", p->name); 216 216 /* XXX: set operating mode */ 217 217 parport_announce_port(p); 218 218
+1 -1
drivers/parport/parport_atari.c
··· 200 200 } 201 201 202 202 this_port = p; 203 - printk(KERN_INFO "%s: Atari built-in port using irq\n", p->name); 203 + pr_info("%s: Atari built-in port using irq\n", p->name); 204 204 parport_announce_port (p); 205 205 206 206 return 0;
+2 -4
drivers/parport/parport_cs.c
··· 142 142 link->irq, PARPORT_DMA_NONE, 143 143 &link->dev, IRQF_SHARED); 144 144 if (p == NULL) { 145 - printk(KERN_NOTICE "parport_cs: parport_pc_probe_port() at " 146 - "0x%3x, irq %u failed\n", 147 - (unsigned int) link->resource[0]->start, 148 - link->irq); 145 + pr_notice("parport_cs: parport_pc_probe_port() at 0x%3x, irq %u failed\n", 146 + (unsigned int)link->resource[0]->start, link->irq); 149 147 goto failed; 150 148 } 151 149
+3 -4
drivers/parport/parport_gsc.c
··· 282 282 p->size = (p->modes & PARPORT_MODE_EPP)?8:3; 283 283 p->private_data = priv; 284 284 285 - printk(KERN_INFO "%s: PC-style at 0x%lx", p->name, p->base); 285 + pr_info("%s: PC-style at 0x%lx", p->name, p->base); 286 286 p->irq = irq; 287 287 if (p->irq == PARPORT_IRQ_AUTO) { 288 288 p->irq = PARPORT_IRQ_NONE; ··· 315 315 if (p->irq != PARPORT_IRQ_NONE) { 316 316 if (request_irq (p->irq, parport_irq_handler, 317 317 0, p->name, p)) { 318 - printk (KERN_WARNING "%s: irq %d in use, " 319 - "resorting to polled operation\n", 318 + pr_warn("%s: irq %d in use, resorting to polled operation\n", 320 319 p->name, p->irq); 321 320 p->irq = PARPORT_IRQ_NONE; 322 321 p->dma = PARPORT_DMA_NONE; ··· 346 347 unsigned long port; 347 348 348 349 if (!dev->irq) { 349 - printk(KERN_WARNING "IRQ not found for parallel device at 0x%llx\n", 350 + pr_warn("IRQ not found for parallel device at 0x%llx\n", 350 351 (unsigned long long)dev->hpa.start); 351 352 return -ENODEV; 352 353 }
+10 -15
drivers/parport/parport_ip32.c
··· 1337 1337 ecr = parport_ip32_read_econtrol(p); 1338 1338 if ((ecr & ECR_F_EMPTY) && !(ecr & ECR_SERVINTR) 1339 1339 && !lost_interrupt) { 1340 - printk(KERN_WARNING PPIP32 1341 - "%s: lost interrupt in %s\n", 1342 - p->name, __func__); 1340 + pr_warn(PPIP32 "%s: lost interrupt in %s\n", 1341 + p->name, __func__); 1343 1342 lost_interrupt = 1; 1344 1343 } 1345 1344 } ··· 1642 1643 DSR_nBUSY | DSR_nFAULT)) { 1643 1644 /* Avoid to flood the logs */ 1644 1645 if (ready_before) 1645 - printk(KERN_INFO PPIP32 "%s: not ready in %s\n", 1646 - p->name, __func__); 1646 + pr_info(PPIP32 "%s: not ready in %s\n", 1647 + p->name, __func__); 1647 1648 ready_before = 0; 1648 1649 goto stop; 1649 1650 } ··· 1723 1724 DSR_nBUSY | DSR_nFAULT)) { 1724 1725 /* Avoid to flood the logs */ 1725 1726 if (ready_before) 1726 - printk(KERN_INFO PPIP32 "%s: not ready in %s\n", 1727 - p->name, __func__); 1727 + pr_info(PPIP32 "%s: not ready in %s\n", 1728 + p->name, __func__); 1728 1729 ready_before = 0; 1729 1730 goto stop; 1730 1731 } ··· 2063 2064 p->modes |= PARPORT_MODE_TRISTATE; 2064 2065 2065 2066 if (!parport_ip32_fifo_supported(p)) { 2066 - printk(KERN_WARNING PPIP32 2067 - "%s: error: FIFO disabled\n", p->name); 2067 + pr_warn(PPIP32 "%s: error: FIFO disabled\n", p->name); 2068 2068 /* Disable hardware modes depending on a working FIFO. */ 2069 2069 features &= ~PARPORT_IP32_ENABLE_SPP; 2070 2070 features &= ~PARPORT_IP32_ENABLE_ECP; ··· 2075 2077 if (features & PARPORT_IP32_ENABLE_IRQ) { 2076 2078 int irq = MACEISA_PARALLEL_IRQ; 2077 2079 if (request_irq(irq, parport_ip32_interrupt, 0, p->name, p)) { 2078 - printk(KERN_WARNING PPIP32 2079 - "%s: error: IRQ disabled\n", p->name); 2080 + pr_warn(PPIP32 "%s: error: IRQ disabled\n", p->name); 2080 2081 /* DMA cannot work without interrupts. */ 2081 2082 features &= ~PARPORT_IP32_ENABLE_DMA; 2082 2083 } else { ··· 2088 2091 /* Allocate DMA resources */ 2089 2092 if (features & PARPORT_IP32_ENABLE_DMA) { 2090 2093 if (parport_ip32_dma_register()) 2091 - printk(KERN_WARNING PPIP32 2092 - "%s: error: DMA disabled\n", p->name); 2094 + pr_warn(PPIP32 "%s: error: DMA disabled\n", p->name); 2093 2095 else { 2094 2096 pr_probe(p, "DMA support enabled\n"); 2095 2097 p->dma = 0; /* arbitrary value != PARPORT_DMA_NONE */ ··· 2130 2134 parport_ip32_dump_state(p, "end init", 0); 2131 2135 2132 2136 /* Print out what we found */ 2133 - printk(KERN_INFO "%s: SGI IP32 at 0x%lx (0x%lx)", 2134 - p->name, p->base, p->base_hi); 2137 + pr_info("%s: SGI IP32 at 0x%lx (0x%lx)", p->name, p->base, p->base_hi); 2135 2138 if (p->irq != PARPORT_IRQ_NONE) 2136 2139 printk(", irq %d", p->irq); 2137 2140 printk(" [");
+1 -1
drivers/parport/parport_mfc3.c
··· 325 325 p->dev = &z->dev; 326 326 327 327 this_port[pias++] = p; 328 - printk(KERN_INFO "%s: Multiface III port using irq\n", p->name); 328 + pr_info("%s: Multiface III port using irq\n", p->name); 329 329 /* XXX: set operating mode */ 330 330 331 331 p->private_data = (void *)piabase;
+70 -96
drivers/parport/parport_pc.c
··· 982 982 outb(0xaa, io); 983 983 984 984 if (verbose_probing) { 985 - printk(KERN_INFO 986 - "SMSC 37c669 LPT Config: cr_1=0x%02x, 4=0x%02x, " 987 - "A=0x%2x, 23=0x%02x, 26=0x%02x, 27=0x%02x\n", 985 + pr_info("SMSC 37c669 LPT Config: cr_1=0x%02x, 4=0x%02x, A=0x%2x, 23=0x%02x, 26=0x%02x, 27=0x%02x\n", 988 986 cr1, cr4, cra, cr23, cr26, cr27); 989 987 990 988 /* The documentation calls DMA and IRQ-Lines by letters, so 991 989 the board maker can/will wire them 992 990 appropriately/randomly... G=reserved H=IDE-irq, */ 993 - printk(KERN_INFO 994 - "SMSC LPT Config: io=0x%04x, irq=%c, dma=%c, fifo threshold=%d\n", 995 - cr23 * 4, 996 - (cr27 & 0x0f) ? 'A' - 1 + (cr27 & 0x0f) : '-', 997 - (cr26 & 0x0f) ? 'A' - 1 + (cr26 & 0x0f) : '-', 998 - cra & 0x0f); 999 - printk(KERN_INFO "SMSC LPT Config: enabled=%s power=%s\n", 1000 - (cr23 * 4 >= 0x100) ? "yes" : "no", 1001 - (cr1 & 4) ? "yes" : "no"); 1002 - printk(KERN_INFO 1003 - "SMSC LPT Config: Port mode=%s, EPP version =%s\n", 1004 - (cr1 & 0x08) ? "Standard mode only (SPP)" 1005 - : modes[cr4 & 0x03], 1006 - (cr4 & 0x40) ? "1.7" : "1.9"); 991 + pr_info("SMSC LPT Config: io=0x%04x, irq=%c, dma=%c, fifo threshold=%d\n", 992 + cr23 * 4, 993 + (cr27 & 0x0f) ? 'A' - 1 + (cr27 & 0x0f) : '-', 994 + (cr26 & 0x0f) ? 'A' - 1 + (cr26 & 0x0f) : '-', 995 + cra & 0x0f); 996 + pr_info("SMSC LPT Config: enabled=%s power=%s\n", 997 + (cr23 * 4 >= 0x100) ? "yes" : "no", 998 + (cr1 & 4) ? "yes" : "no"); 999 + pr_info("SMSC LPT Config: Port mode=%s, EPP version =%s\n", 1000 + (cr1 & 0x08) ? "Standard mode only (SPP)" 1001 + : modes[cr4 & 0x03], 1002 + (cr4 & 0x40) ? "1.7" : "1.9"); 1007 1003 } 1008 1004 1009 1005 /* Heuristics ! BIOS setup for this mainboard device limits ··· 1009 1013 if (cr23 * 4 >= 0x100) { /* if active */ 1010 1014 s = find_free_superio(); 1011 1015 if (s == NULL) 1012 - printk(KERN_INFO "Super-IO: too many chips!\n"); 1016 + pr_info("Super-IO: too many chips!\n"); 1013 1017 else { 1014 1018 int d; 1015 1019 switch (cr23 * 4) { ··· 1074 1078 outb(0xaa, io); 1075 1079 1076 1080 if (verbose_probing) { 1077 - printk(KERN_INFO 1078 - "Winbond LPT Config: cr_30=%02x 60,61=%02x%02x 70=%02x 74=%02x, f0=%02x\n", 1079 - cr30, cr60, cr61, cr70, cr74, crf0); 1080 - printk(KERN_INFO "Winbond LPT Config: active=%s, io=0x%02x%02x irq=%d, ", 1081 - (cr30 & 0x01) ? "yes" : "no", cr60, cr61, cr70 & 0x0f); 1081 + pr_info("Winbond LPT Config: cr_30=%02x 60,61=%02x%02x 70=%02x 74=%02x, f0=%02x\n", 1082 + cr30, cr60, cr61, cr70, cr74, crf0); 1083 + pr_info("Winbond LPT Config: active=%s, io=0x%02x%02x irq=%d, ", 1084 + (cr30 & 0x01) ? "yes" : "no", cr60, cr61, cr70 & 0x0f); 1082 1085 if ((cr74 & 0x07) > 3) 1083 1086 pr_cont("dma=none\n"); 1084 1087 else 1085 1088 pr_cont("dma=%d\n", cr74 & 0x07); 1086 - printk(KERN_INFO 1087 - "Winbond LPT Config: irqtype=%s, ECP fifo threshold=%d\n", 1088 - irqtypes[crf0>>7], (crf0>>3)&0x0f); 1089 - printk(KERN_INFO "Winbond LPT Config: Port mode=%s\n", 1090 - modes[crf0 & 0x07]); 1089 + pr_info("Winbond LPT Config: irqtype=%s, ECP fifo threshold=%d\n", 1090 + irqtypes[crf0 >> 7], (crf0 >> 3) & 0x0f); 1091 + pr_info("Winbond LPT Config: Port mode=%s\n", 1092 + modes[crf0 & 0x07]); 1091 1093 } 1092 1094 1093 1095 if (cr30 & 0x01) { /* the settings can be interrogated later ... */ 1094 1096 s = find_free_superio(); 1095 1097 if (s == NULL) 1096 - printk(KERN_INFO "Super-IO: too many chips!\n"); 1098 + pr_info("Super-IO: too many chips!\n"); 1097 1099 else { 1098 1100 s->io = (cr60 << 8) | cr61; 1099 1101 s->irq = cr70 & 0x0f; ··· 1145 1151 progif = 0; 1146 1152 1147 1153 if (verbose_probing) 1148 - printk(KERN_INFO "Winbond chip at EFER=0x%x key=0x%02x " 1149 - "devid=%02x devrev=%02x oldid=%02x type=%s\n", 1150 - efer, key, devid, devrev, oldid, type); 1154 + pr_info("Winbond chip at EFER=0x%x key=0x%02x devid=%02x devrev=%02x oldid=%02x type=%s\n", 1155 + efer, key, devid, devrev, oldid, type); 1151 1156 1152 1157 if (progif == 2) 1153 1158 show_parconfig_winbond(efer, key); ··· 1177 1184 type = "37c666GT"; 1178 1185 1179 1186 if (verbose_probing) 1180 - printk(KERN_INFO "SMSC chip at EFER=0x%x " 1181 - "key=0x%02x devid=%02x devrev=%02x type=%s\n", 1182 - efer, key, devid, devrev, type); 1187 + pr_info("SMSC chip at EFER=0x%x key=0x%02x devid=%02x devrev=%02x type=%s\n", 1188 + efer, key, devid, devrev, type); 1183 1189 1184 1190 if (func) 1185 1191 func(efer, key); ··· 1350 1358 dev |= inb(0x2f); 1351 1359 if (dev == 0x8712 || dev == 0x8705 || dev == 0x8715 || 1352 1360 dev == 0x8716 || dev == 0x8718 || dev == 0x8726) { 1353 - printk(KERN_INFO "IT%04X SuperIO detected.\n", dev); 1361 + pr_info("IT%04X SuperIO detected\n", dev); 1354 1362 outb(0x07, 0x2E); /* Parallel Port */ 1355 1363 outb(0x03, 0x2F); 1356 1364 outb(0xF0, 0x2E); /* BOOT 0x80 off */ ··· 1437 1445 if (user_specified) 1438 1446 /* That didn't work, but the user thinks there's a 1439 1447 * port here. */ 1440 - printk(KERN_INFO "parport 0x%lx (WARNING): CTR: " 1441 - "wrote 0x%02x, read 0x%02x\n", pb->base, w, r); 1448 + pr_info("parport 0x%lx (WARNING): CTR: wrote 0x%02x, read 0x%02x\n", 1449 + pb->base, w, r); 1442 1450 1443 1451 /* Try the data register. The data lines aren't tri-stated at 1444 1452 * this stage, so we expect back what we wrote. */ ··· 1456 1464 if (user_specified) { 1457 1465 /* Didn't work, but the user is convinced this is the 1458 1466 * place. */ 1459 - printk(KERN_INFO "parport 0x%lx (WARNING): DATA: " 1460 - "wrote 0x%02x, read 0x%02x\n", pb->base, w, r); 1461 - printk(KERN_INFO "parport 0x%lx: You gave this address, " 1462 - "but there is probably no parallel port there!\n", 1467 + pr_info("parport 0x%lx (WARNING): DATA: wrote 0x%02x, read 0x%02x\n", 1468 + pb->base, w, r); 1469 + pr_info("parport 0x%lx: You gave this address, but there is probably no parallel port there!\n", 1463 1470 pb->base); 1464 1471 } 1465 1472 ··· 1633 1642 1634 1643 if (i <= priv->fifo_depth) { 1635 1644 if (verbose_probing) 1636 - printk(KERN_INFO "0x%lx: readIntrThreshold is %d\n", 1645 + pr_info("0x%lx: readIntrThreshold is %d\n", 1637 1646 pb->base, i); 1638 1647 } else 1639 1648 /* Number of bytes we can read if we get an interrupt. */ ··· 1648 1657 switch (pword) { 1649 1658 case 0: 1650 1659 pword = 2; 1651 - printk(KERN_WARNING "0x%lx: Unsupported pword size!\n", 1652 - pb->base); 1660 + pr_warn("0x%lx: Unsupported pword size!\n", pb->base); 1653 1661 break; 1654 1662 case 2: 1655 1663 pword = 4; 1656 - printk(KERN_WARNING "0x%lx: Unsupported pword size!\n", 1657 - pb->base); 1664 + pr_warn("0x%lx: Unsupported pword size!\n", pb->base); 1658 1665 break; 1659 1666 default: 1660 - printk(KERN_WARNING "0x%lx: Unknown implementation ID\n", 1661 - pb->base); 1667 + pr_warn("0x%lx: Unknown implementation ID\n", pb->base); 1662 1668 /* Fall through - Assume 1 */ 1663 1669 case 1: 1664 1670 pword = 1; ··· 2095 2107 2096 2108 p->size = (p->modes & PARPORT_MODE_EPP) ? 8 : 3; 2097 2109 2098 - printk(KERN_INFO "%s: PC-style at 0x%lx", p->name, p->base); 2110 + pr_info("%s: PC-style at 0x%lx", p->name, p->base); 2099 2111 if (p->base_hi && priv->ecr) 2100 - printk(KERN_CONT " (0x%lx)", p->base_hi); 2112 + pr_cont(" (0x%lx)", p->base_hi); 2101 2113 if (p->irq == PARPORT_IRQ_AUTO) { 2102 2114 p->irq = PARPORT_IRQ_NONE; 2103 2115 parport_irq_probe(p); ··· 2108 2120 p->irq = PARPORT_IRQ_NONE; 2109 2121 } 2110 2122 if (p->irq != PARPORT_IRQ_NONE) { 2111 - printk(KERN_CONT ", irq %d", p->irq); 2123 + pr_cont(", irq %d", p->irq); 2112 2124 priv->ctr_writable |= 0x10; 2113 2125 2114 2126 if (p->dma == PARPORT_DMA_AUTO) { ··· 2132 2144 /* p->ops->ecp_read_data = parport_pc_ecp_read_block_pio; */ 2133 2145 #endif /* IEEE 1284 support */ 2134 2146 if (p->dma != PARPORT_DMA_NONE) { 2135 - printk(KERN_CONT ", dma %d", p->dma); 2147 + pr_cont(", dma %d", p->dma); 2136 2148 p->modes |= PARPORT_MODE_DMA; 2137 2149 } else 2138 - printk(KERN_CONT ", using FIFO"); 2150 + pr_cont(", using FIFO"); 2139 2151 } else 2140 2152 /* We can't use the DMA channel after all. */ 2141 2153 p->dma = PARPORT_DMA_NONE; 2142 2154 #endif /* Allowed to use FIFO/DMA */ 2143 2155 2144 - printk(KERN_CONT " ["); 2156 + pr_cont(" ["); 2145 2157 2146 2158 #define printmode(x) \ 2147 2159 {\ 2148 2160 if (p->modes & PARPORT_MODE_##x) {\ 2149 - printk(KERN_CONT "%s%s", f ? "," : "", #x);\ 2161 + pr_cont("%s%s", f ? "," : "", #x); \ 2150 2162 f++;\ 2151 2163 } \ 2152 2164 } ··· 2162 2174 } 2163 2175 #undef printmode 2164 2176 #ifndef CONFIG_PARPORT_1284 2165 - printk(KERN_CONT "(,...)"); 2177 + pr_cont("(,...)"); 2166 2178 #endif /* CONFIG_PARPORT_1284 */ 2167 - printk(KERN_CONT "]\n"); 2179 + pr_cont("]\n"); 2168 2180 if (probedirq != PARPORT_IRQ_NONE) 2169 - printk(KERN_INFO "%s: irq %d detected\n", p->name, probedirq); 2181 + pr_info("%s: irq %d detected\n", p->name, probedirq); 2170 2182 2171 2183 /* If No ECP release the ports grabbed above. */ 2172 2184 if (ECR_res && (p->modes & PARPORT_MODE_ECP) == 0) { ··· 2181 2193 if (p->irq != PARPORT_IRQ_NONE) { 2182 2194 if (request_irq(p->irq, parport_irq_handler, 2183 2195 irqflags, p->name, p)) { 2184 - printk(KERN_WARNING "%s: irq %d in use, " 2185 - "resorting to polled operation\n", 2196 + pr_warn("%s: irq %d in use, resorting to polled operation\n", 2186 2197 p->name, p->irq); 2187 2198 p->irq = PARPORT_IRQ_NONE; 2188 2199 p->dma = PARPORT_DMA_NONE; ··· 2191 2204 #ifdef HAS_DMA 2192 2205 if (p->dma != PARPORT_DMA_NONE) { 2193 2206 if (request_dma(p->dma, p->name)) { 2194 - printk(KERN_WARNING "%s: dma %d in use, " 2195 - "resorting to PIO operation\n", 2207 + pr_warn("%s: dma %d in use, resorting to PIO operation\n", 2196 2208 p->name, p->dma); 2197 2209 p->dma = PARPORT_DMA_NONE; 2198 2210 } else { ··· 2201 2215 &priv->dma_handle, 2202 2216 GFP_KERNEL); 2203 2217 if (!priv->dma_buf) { 2204 - printk(KERN_WARNING "%s: " 2205 - "cannot get buffer for DMA, " 2206 - "resorting to PIO operation\n", 2218 + pr_warn("%s: cannot get buffer for DMA, resorting to PIO operation\n", 2207 2219 p->name); 2208 2220 free_dma(p->dma); 2209 2221 p->dma = PARPORT_DMA_NONE; ··· 2314 2330 } 2315 2331 } 2316 2332 if (i >= 5) { 2317 - printk(KERN_INFO "parport_pc: cannot find ITE8872 INTA\n"); 2333 + pr_info("parport_pc: cannot find ITE8872 INTA\n"); 2318 2334 return 0; 2319 2335 } 2320 2336 ··· 2323 2339 2324 2340 switch (type) { 2325 2341 case 0x2: 2326 - printk(KERN_INFO "parport_pc: ITE8871 found (1P)\n"); 2342 + pr_info("parport_pc: ITE8871 found (1P)\n"); 2327 2343 ite8872set = 0x64200000; 2328 2344 break; 2329 2345 case 0xa: 2330 - printk(KERN_INFO "parport_pc: ITE8875 found (1P)\n"); 2346 + pr_info("parport_pc: ITE8875 found (1P)\n"); 2331 2347 ite8872set = 0x64200000; 2332 2348 break; 2333 2349 case 0xe: 2334 - printk(KERN_INFO "parport_pc: ITE8872 found (2S1P)\n"); 2350 + pr_info("parport_pc: ITE8872 found (2S1P)\n"); 2335 2351 ite8872set = 0x64e00000; 2336 2352 break; 2337 2353 case 0x6: 2338 - printk(KERN_INFO "parport_pc: ITE8873 found (1S)\n"); 2354 + pr_info("parport_pc: ITE8873 found (1S)\n"); 2339 2355 release_region(inta_addr[i], 32); 2340 2356 return 0; 2341 2357 case 0x8: 2342 - printk(KERN_INFO "parport_pc: ITE8874 found (2S)\n"); 2358 + pr_info("parport_pc: ITE8874 found (2S)\n"); 2343 2359 release_region(inta_addr[i], 32); 2344 2360 return 0; 2345 2361 default: 2346 - printk(KERN_INFO "parport_pc: unknown ITE887x\n"); 2347 - printk(KERN_INFO "parport_pc: please mail 'lspci -nvv' " 2348 - "output to Rich.Liu@ite.com.tw\n"); 2362 + pr_info("parport_pc: unknown ITE887x\n"); 2363 + pr_info("parport_pc: please mail 'lspci -nvv' output to Rich.Liu@ite.com.tw\n"); 2349 2364 release_region(inta_addr[i], 32); 2350 2365 return 0; 2351 2366 } ··· 2379 2396 release_region(inta_addr[i], 32); 2380 2397 if (parport_pc_probe_port(ite8872_lpt, ite8872_lpthi, 2381 2398 irq, PARPORT_DMA_NONE, &pdev->dev, 0)) { 2382 - printk(KERN_INFO 2383 - "parport_pc: ITE 8872 parallel port: io=0x%X", 2384 - ite8872_lpt); 2399 + pr_info("parport_pc: ITE 8872 parallel port: io=0x%X", 2400 + ite8872_lpt); 2385 2401 if (irq != PARPORT_IRQ_NONE) 2386 2402 pr_cont(", irq=%d", irq); 2387 2403 pr_cont("\n"); ··· 2507 2525 pci_write_config_byte(pdev, via->via_pci_superio_config_reg, tmp); 2508 2526 2509 2527 if (siofunc == VIA_FUNCTION_PARPORT_DISABLE) { 2510 - printk(KERN_INFO "parport_pc: VIA parallel port disabled in BIOS\n"); 2528 + pr_info("parport_pc: VIA parallel port disabled in BIOS\n"); 2511 2529 return 0; 2512 2530 } 2513 2531 ··· 2540 2558 case 0x278: 2541 2559 port2 = 0x678; break; 2542 2560 default: 2543 - printk(KERN_INFO 2544 - "parport_pc: Weird VIA parport base 0x%X, ignoring\n", 2545 - port1); 2561 + pr_info("parport_pc: Weird VIA parport base 0x%X, ignoring\n", 2562 + port1); 2546 2563 return 0; 2547 2564 } 2548 2565 ··· 2560 2579 2561 2580 /* finally, do the probe with values obtained */ 2562 2581 if (parport_pc_probe_port(port1, port2, irq, dma, &pdev->dev, 0)) { 2563 - printk(KERN_INFO 2564 - "parport_pc: VIA parallel port: io=0x%X", port1); 2582 + pr_info("parport_pc: VIA parallel port: io=0x%X", port1); 2565 2583 if (irq != PARPORT_IRQ_NONE) 2566 2584 pr_cont(", irq=%d", irq); 2567 2585 if (dma != PARPORT_DMA_NONE) ··· 2569 2589 return 1; 2570 2590 } 2571 2591 2572 - printk(KERN_WARNING "parport_pc: Strange, can't probe VIA parallel port: io=0x%X, irq=%d, dma=%d\n", 2592 + pr_warn("parport_pc: Strange, can't probe VIA parallel port: io=0x%X, irq=%d, dma=%d\n", 2573 2593 port1, irq, dma); 2574 2594 return 0; 2575 2595 } ··· 3091 3111 if (ep != s) 3092 3112 *val = r; 3093 3113 else { 3094 - printk(KERN_ERR "parport: bad specifier `%s'\n", s); 3114 + pr_err("parport: bad specifier `%s'\n", s); 3095 3115 return -1; 3096 3116 } 3097 3117 } ··· 3181 3201 irqval[0] = val; 3182 3202 break; 3183 3203 default: 3184 - printk(KERN_WARNING 3185 - "parport_pc: irq specified " 3186 - "without base address. Use 'io=' " 3187 - "to specify one\n"); 3204 + pr_warn("parport_pc: irq specified without base address. Use 'io=' to specify one\n"); 3188 3205 } 3189 3206 3190 3207 if (dma[0] && !parport_parse_dma(dma[0], &val)) ··· 3191 3214 dmaval[0] = val; 3192 3215 break; 3193 3216 default: 3194 - printk(KERN_WARNING 3195 - "parport_pc: dma specified " 3196 - "without base address. Use 'io=' " 3197 - "to specify one\n"); 3217 + pr_warn("parport_pc: dma specified without base address. Use 'io=' to specify one\n"); 3198 3218 } 3199 3219 } 3200 3220 return 0; ··· 3230 3256 3231 3257 val = simple_strtoul(str, &endptr, 0); 3232 3258 if (endptr == str) { 3233 - printk(KERN_WARNING "parport=%s not understood\n", str); 3259 + pr_warn("parport=%s not understood\n", str); 3234 3260 return 1; 3235 3261 } 3236 3262 3237 3263 if (parport_setup_ptr == PARPORT_PC_MAX_PORTS) { 3238 - printk(KERN_ERR "parport=%s ignored, too many ports\n", str); 3264 + pr_err("parport=%s ignored, too many ports\n", str); 3239 3265 return 1; 3240 3266 } 3241 3267
+1 -1
drivers/parport/parport_sunbpp.c
··· 314 314 value_tcr &= ~P_TCR_DIR; 315 315 sbus_writeb(value_tcr, &regs->p_tcr); 316 316 317 - printk(KERN_INFO "%s: sunbpp at 0x%lx\n", p->name, p->base); 317 + pr_info("%s: sunbpp at 0x%lx\n", p->name, p->base); 318 318 319 319 dev_set_drvdata(&op->dev, p); 320 320
+4 -3
drivers/parport/probe.c
··· 38 38 { 39 39 struct parport_device_info *info = &port->probe_info[device + 1]; 40 40 41 - printk(KERN_INFO "%s", port->name); 41 + pr_info("%s", port->name); 42 42 43 43 if (device >= 0) 44 44 printk (" (addr %d)", device); ··· 58 58 struct parport_device_info *info = &port->probe_info[device + 1]; 59 59 60 60 if (!txt) { 61 - printk(KERN_WARNING "%s probe: memory squeeze\n", port->name); 61 + pr_warn("%s probe: memory squeeze\n", port->name); 62 62 return; 63 63 } 64 64 strcpy(txt, str); ··· 98 98 goto rock_on; 99 99 } 100 100 } 101 - printk(KERN_WARNING "%s probe: warning, class '%s' not understood.\n", port->name, sep); 101 + pr_warn("%s probe: warning, class '%s' not understood\n", 102 + port->name, sep); 102 103 info->class = PARPORT_CLASS_OTHER; 103 104 } else if (!strcmp(p, "CMD") || 104 105 !strcmp(p, "COMMAND SET")) {
+12 -12
drivers/parport/share.c
··· 554 554 #endif 555 555 556 556 if (!port->dev) 557 - printk(KERN_WARNING "%s: fix this legacy no-device port driver!\n", 558 - port->name); 557 + pr_warn("%s: fix this legacy no-device port driver!\n", 558 + port->name); 559 559 560 560 parport_proc_register(port); 561 561 mutex_lock(&registration_lock); ··· 727 727 728 728 if (flags & PARPORT_DEV_LURK) { 729 729 if (!pf || !kf) { 730 - printk(KERN_INFO "%s: refused to register lurking device (%s) without callbacks\n", port->name, name); 730 + pr_info("%s: refused to register lurking device (%s) without callbacks\n", 731 + port->name, name); 731 732 return NULL; 732 733 } 733 734 } ··· 997 996 998 997 #ifdef PARPORT_PARANOID 999 998 if (!dev) { 1000 - printk(KERN_ERR "parport_unregister_device: passed NULL\n"); 999 + pr_err("%s: passed NULL\n", __func__); 1001 1000 return; 1002 1001 } 1003 1002 #endif ··· 1138 1137 unsigned long flags; 1139 1138 1140 1139 if (port->cad == dev) { 1141 - printk(KERN_INFO "%s: %s already owner\n", 1142 - dev->port->name,dev->name); 1140 + pr_info("%s: %s already owner\n", dev->port->name, dev->name); 1143 1141 return 0; 1144 1142 } 1145 1143 ··· 1158 1158 * I think we'll actually deadlock rather than 1159 1159 * get here, but just in case.. 1160 1160 */ 1161 - printk(KERN_WARNING 1162 - "%s: %s released port when preempted!\n", 1163 - port->name, oldcad->name); 1161 + pr_warn("%s: %s released port when preempted!\n", 1162 + port->name, oldcad->name); 1164 1163 if (port->cad) 1165 1164 goto blocked; 1166 1165 } ··· 1319 1320 write_lock_irqsave(&port->cad_lock, flags); 1320 1321 if (port->cad != dev) { 1321 1322 write_unlock_irqrestore(&port->cad_lock, flags); 1322 - printk(KERN_WARNING "%s: %s tried to release parport when not owner\n", 1323 - port->name, dev->name); 1323 + pr_warn("%s: %s tried to release parport when not owner\n", 1324 + port->name, dev->name); 1324 1325 return; 1325 1326 } 1326 1327 ··· 1360 1361 if (dev->port->cad) /* racy but no matter */ 1361 1362 return; 1362 1363 } else { 1363 - printk(KERN_ERR "%s: don't know how to wake %s\n", port->name, pd->name); 1364 + pr_err("%s: don't know how to wake %s\n", 1365 + port->name, pd->name); 1364 1366 } 1365 1367 } 1366 1368