pr_info makes code cleaner and simplifies syntax Signed-off-by: Denis Kirjanov <kirja...@gmail.com> --- arch/powerpc/platforms/powermac/feature.c | 8 ++++---- arch/powerpc/platforms/powermac/low_i2c.c | 12 ++++++------ arch/powerpc/platforms/powermac/pci.c | 12 ++++++------ arch/powerpc/platforms/powermac/pic.c | 6 +++--- arch/powerpc/platforms/powermac/setup.c | 2 +- arch/powerpc/platforms/powermac/smp.c | 12 ++++++------ 6 files changed, 26 insertions(+), 26 deletions(-)
diff --git a/arch/powerpc/platforms/powermac/feature.c b/arch/powerpc/platforms/powermac/feature.c index 6365cea27abc..d3bcfe590384 100644 --- a/arch/powerpc/platforms/powermac/feature.c +++ b/arch/powerpc/platforms/powermac/feature.c @@ -2527,7 +2527,7 @@ static int __init probe_motherboard(void) pmac_mb.board_flags |= PMAC_MB_MOBILE; - printk(KERN_INFO "PowerMac motherboard: %s\n", pmac_mb.model_name); + pr_info("PowerMac motherboard: %s\n", pmac_mb.model_name); done: of_node_put(dt); return ret; @@ -2574,11 +2574,11 @@ static void __init probe_uninorth(void) } } - printk(KERN_INFO "Found %s memory controller & host bridge" + pr_info("Found %s memory controller & host bridge" " @ 0x%08x revision: 0x%02x\n", uninorth_maj == 3 ? "U3" : uninorth_maj == 4 ? "U4" : "UniNorth", (unsigned int)res.start, uninorth_rev); - printk(KERN_INFO "Mapped at 0x%08lx\n", (unsigned long)uninorth_base); + pr_info("Mapped at 0x%08lx\n", (unsigned long)uninorth_base); /* Set the arbitrer QAck delay according to what Apple does */ @@ -2664,7 +2664,7 @@ static void __init probe_one_macio(const char *name, const char *compat, int typ revp = of_get_property(node, "revision-id", NULL); if (revp) macio_chips[i].rev = *revp; - printk(KERN_INFO "Found a %s mac-io controller, rev: %d, mapped at 0x%p\n", + pr_info("Found a %s mac-io controller, rev: %d, mapped at 0x%p\n", macio_names[type], macio_chips[i].rev, macio_chips[i].base); return; diff --git a/arch/powerpc/platforms/powermac/low_i2c.c b/arch/powerpc/platforms/powermac/low_i2c.c index c097d591670e..fe38e6e0f8db 100644 --- a/arch/powerpc/platforms/powermac/low_i2c.c +++ b/arch/powerpc/platforms/powermac/low_i2c.c @@ -554,7 +554,7 @@ static struct pmac_i2c_host_kw *__init kw_i2c_host_init(struct device_node *np) "keywest i2c", host)) host->irq = 0; - printk(KERN_INFO "KeyWest i2c @0x%08x irq %d %pOF\n", + pr_info("KeyWest i2c @0x%08x irq %d %pOF\n", *addrp, host->irq, np); return host; @@ -588,7 +588,7 @@ static void __init kw_i2c_add(struct pmac_i2c_host_kw *host, bus->flags = pmac_i2c_multibus; list_add(&bus->link, &pmac_i2c_busses); - printk(KERN_INFO " channel %d bus %s\n", channel, + pr_info(" channel %d bus %s\n", channel, (controller == busnode) ? "<multibus>" : busnode->full_name); } @@ -793,7 +793,7 @@ static void __init pmu_i2c_probe(void) if (busnode == NULL) return; - printk(KERN_INFO "PMU i2c %pOF\n", busnode); + pr_info("PMU i2c %pOF\n", busnode); /* * We add bus 1 and 2 only for now, bus 0 is "special" @@ -817,7 +817,7 @@ static void __init pmu_i2c_probe(void) bus->flags = pmac_i2c_multibus; list_add(&bus->link, &pmac_i2c_busses); - printk(KERN_INFO " channel %d bus <multibus>\n", channel); + pr_info(" channel %d bus <multibus>\n", channel); } } @@ -909,7 +909,7 @@ static void __init smu_i2c_probe(void) if (controller == NULL) return; - printk(KERN_INFO "SMU i2c %pOF\n", controller); + pr_info("SMU i2c %pOF\n", controller); /* Look for childs, note that they might not be of the right * type as older device trees mix i2c busses and other things @@ -943,7 +943,7 @@ static void __init smu_i2c_probe(void) bus->flags = 0; list_add(&bus->link, &pmac_i2c_busses); - printk(KERN_INFO " channel %x bus %pOF\n", + pr_info(" channel %x bus %pOF\n", bus->channel, busnode); } } diff --git a/arch/powerpc/platforms/powermac/pci.c b/arch/powerpc/platforms/powermac/pci.c index d71359b5331c..5404189866af 100644 --- a/arch/powerpc/platforms/powermac/pci.c +++ b/arch/powerpc/platforms/powermac/pci.c @@ -482,7 +482,7 @@ static void __init init_bandit(struct pci_controller *bp) magic |= BANDIT_COHERENT; udelay(2); out_le32(bp->cfg_data, magic); - printk(KERN_INFO "Cache coherency enabled for bandit/PSX\n"); + pr_info("Cache coherency enabled for bandit/PSX\n"); } /* @@ -814,7 +814,7 @@ static int __init pmac_add_bridge(struct device_node *dev) disp_name = "U4-PCIE"; primary = 0; } - printk(KERN_INFO "Found %s PCI host bridge. Firmware bus number:" + pr_info("Found %s PCI host bridge. Firmware bus number:" " %d->%d\n", disp_name, hose->first_busno, hose->last_busno); #endif /* CONFIG_PPC64 */ @@ -835,7 +835,7 @@ static int __init pmac_add_bridge(struct device_node *dev) disp_name = "Chaos"; primary = 0; } - printk(KERN_INFO "Found %s PCI host bridge at 0x%016llx. " + pr_info("Found %s PCI host bridge at 0x%016llx. " "Firmware bus number: %d->%d\n", disp_name, (unsigned long long)rsrc.start, hose->first_busno, hose->last_busno); @@ -966,7 +966,7 @@ static bool pmac_pci_enable_device_hook(struct pci_dev *dev) if (dev->vendor == PCI_VENDOR_ID_APPLE && dev->class == PCI_CLASS_SERIAL_USB_OHCI && !node) { - printk(KERN_INFO "Apple USB OHCI %s disabled by firmware\n", + pr_info("Apple USB OHCI %s disabled by firmware\n", pci_name(dev)); return false; } @@ -1122,7 +1122,7 @@ static void pmac_pci_fixup_pciata(struct pci_dev *dev) good: pci_read_config_byte(dev, PCI_CLASS_PROG, &progif); if ((progif & 5) != 5) { - printk(KERN_INFO "PCI: %s Forcing PCI IDE into native mode\n", + pr_info("PCI: %s Forcing PCI IDE into native mode\n", pci_name(dev)); (void) pci_write_config_byte(dev, PCI_CLASS_PROG, progif|5); if (pci_read_config_byte(dev, PCI_CLASS_PROG, &progif) || @@ -1220,7 +1220,7 @@ static void fixup_u4_pcie(struct pci_dev* dev) return; /* Print things out */ - printk(KERN_INFO "PCI: Fixup U4 PCIe bridge range: %pR\n", region); + pr_info("PCI: Fixup U4 PCIe bridge range: %pR\n", region); /* Fixup bridge config space. We know it's a Mac, resource aren't * offset so let's just blast them as-is. We also know that they diff --git a/arch/powerpc/platforms/powermac/pic.c b/arch/powerpc/platforms/powermac/pic.c index 2202bf77c7a3..c9a5326aae41 100644 --- a/arch/powerpc/platforms/powermac/pic.c +++ b/arch/powerpc/platforms/powermac/pic.c @@ -345,7 +345,7 @@ static void __init pmac_pic_probe_oldstyle(void) (addr + 0x10); of_node_put(master); - printk(KERN_INFO "irq: Found primary Apple PIC %pOF for %d irqs\n", + pr_info("irq: Found primary Apple PIC %pOF for %d irqs\n", master, max_real_irqs); /* Map interrupts of cascaded controller */ @@ -359,7 +359,7 @@ static void __init pmac_pic_probe_oldstyle(void) (addr + 0x10); pmac_irq_cascade = irq_of_parse_and_map(slave, 0); - printk(KERN_INFO "irq: Found slave Apple PIC %pOF for %d irqs" + pr_info("irq: Found slave Apple PIC %pOF for %d irqs" " cascade: %d\n", slave, max_irqs - max_real_irqs, pmac_irq_cascade); } @@ -376,7 +376,7 @@ static void __init pmac_pic_probe_oldstyle(void) pr_err("Failed to register cascade interrupt\n"); } - printk(KERN_INFO "irq: System has %d possible interrupts\n", max_irqs); + pr_info("irq: System has %d possible interrupts\n", max_irqs); #ifdef CONFIG_XMON i = irq_create_mapping(NULL, 20); if (request_irq(i, xmon_irq, IRQF_NO_THREAD, "NMI - XMON", NULL)) diff --git a/arch/powerpc/platforms/powermac/setup.c b/arch/powerpc/platforms/powermac/setup.c index 6de1cd5d8a58..cb7d9f1db7fe 100644 --- a/arch/powerpc/platforms/powermac/setup.c +++ b/arch/powerpc/platforms/powermac/setup.c @@ -220,7 +220,7 @@ static void __init ohare_init(void) else sysctrl_regs[4] |= 0x04000000; if(has_l2cache) - printk(KERN_INFO "Level 2 cache enabled\n"); + pr_info("Level 2 cache enabled\n"); } } } diff --git a/arch/powerpc/platforms/powermac/smp.c b/arch/powerpc/platforms/powermac/smp.c index ffd5bc96b92c..49843b6e88b3 100644 --- a/arch/powerpc/platforms/powermac/smp.c +++ b/arch/powerpc/platforms/powermac/smp.c @@ -602,7 +602,7 @@ static void __init smp_core99_setup_i2c_hwsync(int ncpus) " sync, fallback to software sync !\n"); goto no_i2c_sync; } - printk(KERN_INFO "Processor timebase sync using %s i2c clock\n", + pr_info("Processor timebase sync using %s i2c clock\n", name); return; } @@ -702,7 +702,7 @@ static void __init smp_core99_setup(int ncpus) if (cpus && of_property_read_bool(cpus, "platform-cpu-timebase")) { pmac_tb_freeze = smp_core99_pfunc_tb_freeze; - printk(KERN_INFO "Processor timebase sync using" + pr_info("Processor timebase sync using" " platform function\n"); } of_node_put(cpus); @@ -724,7 +724,7 @@ static void __init smp_core99_setup(int ncpus) of_node_put(cpu); } pmac_tb_freeze = smp_core99_gpio_tb_freeze; - printk(KERN_INFO "Processor timebase sync using" + pr_info("Processor timebase sync using" " GPIO 0x%02x\n", core99_tb_gpio); } @@ -734,7 +734,7 @@ static void __init smp_core99_setup(int ncpus) if (pmac_tb_freeze == NULL) { smp_ops->give_timebase = smp_generic_give_timebase; smp_ops->take_timebase = smp_generic_take_timebase; - printk(KERN_INFO "Processor timebase sync using software\n"); + pr_info("Processor timebase sync using software\n"); } #ifndef CONFIG_PPC64 @@ -763,7 +763,7 @@ static void __init smp_core99_probe(void) for_each_node_by_type(cpus, "cpu") ++ncpus; - printk(KERN_INFO "PowerMac SMP probe found %d cpus\n", ncpus); + pr_info("PowerMac SMP probe found %d cpus\n", ncpus); /* Nothing more to do if less than 2 of them */ if (ncpus <= 1) @@ -940,7 +940,7 @@ static void pmac_cpu_offline_self(void) * on core99 platforms for now ... */ - printk(KERN_INFO "CPU#%d offline\n", cpu); + pr_info("CPU#%d offline\n", cpu); generic_set_cpu_dead(cpu); smp_wmb(); -- 2.47.2