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

[media] media: rc: nuvoton-cir: replace nvt_pr with dev_ functions

Replace nvt_pr with the respective dev_ functions thus slightly
simplifying the code.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

authored by

Heiner Kallweit and committed by
Mauro Carvalho Chehab
211477fe af082334

+8 -10
+8 -7
drivers/media/rc/nuvoton-cir.c
··· 274 274 275 275 /* warn, but still let the driver load, if we don't know this chip */ 276 276 if (!chip_name) 277 - nvt_pr(KERN_WARNING, 278 - "unknown chip, id: 0x%02x 0x%02x, it may not work...", 279 - nvt->chip_major, nvt->chip_minor); 277 + dev_warn(&nvt->pdev->dev, 278 + "unknown chip, id: 0x%02x 0x%02x, it may not work...", 279 + nvt->chip_major, nvt->chip_minor); 280 280 else 281 281 dev_info(&nvt->pdev->dev, 282 282 "found %s or compatible: chip id: 0x%02x 0x%02x", ··· 483 483 duration *= SAMPLE_PERIOD; 484 484 485 485 if (!count || !duration) { 486 - nvt_pr(KERN_NOTICE, "Unable to determine carrier! (c:%u, d:%u)", 487 - count, duration); 486 + dev_notice(&nvt->pdev->dev, 487 + "Unable to determine carrier! (c:%u, d:%u)", 488 + count, duration); 488 489 return 0; 489 490 } 490 491 ··· 660 659 661 660 static void nvt_handle_rx_fifo_overrun(struct nvt_dev *nvt) 662 661 { 663 - nvt_pr(KERN_WARNING, "RX FIFO overrun detected, flushing data!"); 662 + dev_warn(&nvt->pdev->dev, "RX FIFO overrun detected, flushing data!"); 664 663 665 664 nvt->pkts = 0; 666 665 nvt_clear_cir_fifo(nvt); ··· 1089 1088 1090 1089 device_init_wakeup(&pdev->dev, true); 1091 1090 1092 - nvt_pr(KERN_NOTICE, "driver has been successfully loaded\n"); 1091 + dev_notice(&pdev->dev, "driver has been successfully loaded\n"); 1093 1092 if (debug) { 1094 1093 cir_dump_regs(nvt); 1095 1094 cir_wake_dump_regs(nvt);
-3
drivers/media/rc/nuvoton-cir.h
··· 35 35 static int debug; 36 36 37 37 38 - #define nvt_pr(level, text, ...) \ 39 - printk(level KBUILD_MODNAME ": " text, ## __VA_ARGS__) 40 - 41 38 #define nvt_dbg(text, ...) \ 42 39 if (debug) \ 43 40 printk(KERN_DEBUG \