summaryrefslogtreecommitdiff
path: root/drivers/media/pci/cx23885/cx23885-cards.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>2016-11-13 09:46:11 -0200
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2016-11-18 08:09:36 -0200
commite39682b5d96ae7a33a0f6b5578911913be8f14b6 (patch)
treeb7aa9b903756aca9e874e132e0a604e307ef71b0 /drivers/media/pci/cx23885/cx23885-cards.c
parentf1dc10b6e18df849429c1625bbcdf04ecc25d5c3 (diff)
[media] cx23885: convert it to use pr_foo() macros
Instead of calling printk() directly, use pr_foo() macros, as suggested at the Kernel's coding style. Please notice that a conversion to dev_foo() is not trivial, as several parts on this driver uses pr_cont(). Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/pci/cx23885/cx23885-cards.c')
-rw-r--r--drivers/media/pci/cx23885/cx23885-cards.c49
1 files changed, 24 insertions, 25 deletions
diff --git a/drivers/media/pci/cx23885/cx23885-cards.c b/drivers/media/pci/cx23885/cx23885-cards.c
index e2c4edbfbdb7..0350f13c5a9f 100644
--- a/drivers/media/pci/cx23885/cx23885-cards.c
+++ b/drivers/media/pci/cx23885/cx23885-cards.c
@@ -15,6 +15,8 @@
* GNU General Public License for more details.
*/
+#include "cx23885.h"
+
#include <linux/init.h>
#include <linux/module.h>
#include <linux/pci.h>
@@ -23,7 +25,6 @@
#include <linux/firmware.h>
#include <misc/altera.h>
-#include "cx23885.h"
#include "tuner-xc2028.h"
#include "netup-eeprom.h"
#include "netup-init.h"
@@ -1096,26 +1097,24 @@ void cx23885_card_list(struct cx23885_dev *dev)
if (0 == dev->pci->subsystem_vendor &&
0 == dev->pci->subsystem_device) {
- printk(KERN_INFO
- "%s: Board has no valid PCIe Subsystem ID and can't\n"
- "%s: be autodetected. Pass card=<n> insmod option\n"
- "%s: to workaround that. Redirect complaints to the\n"
- "%s: vendor of the TV card. Best regards,\n"
- "%s: -- tux\n",
- dev->name, dev->name, dev->name, dev->name, dev->name);
+ pr_info("%s: Board has no valid PCIe Subsystem ID and can't\n"
+ "%s: be autodetected. Pass card=<n> insmod option\n"
+ "%s: to workaround that. Redirect complaints to the\n"
+ "%s: vendor of the TV card. Best regards,\n"
+ "%s: -- tux\n",
+ dev->name, dev->name, dev->name, dev->name, dev->name);
} else {
- printk(KERN_INFO
- "%s: Your board isn't known (yet) to the driver.\n"
- "%s: Try to pick one of the existing card configs via\n"
- "%s: card=<n> insmod option. Updating to the latest\n"
- "%s: version might help as well.\n",
- dev->name, dev->name, dev->name, dev->name);
+ pr_info("%s: Your board isn't known (yet) to the driver.\n"
+ "%s: Try to pick one of the existing card configs via\n"
+ "%s: card=<n> insmod option. Updating to the latest\n"
+ "%s: version might help as well.\n",
+ dev->name, dev->name, dev->name, dev->name);
}
- printk(KERN_INFO "%s: Here is a list of valid choices for the card=<n> insmod option:\n",
+ pr_info("%s: Here is a list of valid choices for the card=<n> insmod option:\n",
dev->name);
for (i = 0; i < cx23885_bcount; i++)
- printk(KERN_INFO "%s: card=%d -> %s\n",
- dev->name, i, cx23885_boards[i].name);
+ pr_info("%s: card=%d -> %s\n",
+ dev->name, i, cx23885_boards[i].name);
}
static void viewcast_eeprom(struct cx23885_dev *dev, u8 *eeprom_data)
@@ -1304,13 +1303,13 @@ static void hauppauge_eeprom(struct cx23885_dev *dev, u8 *eeprom_data)
*/
break;
default:
- printk(KERN_WARNING "%s: warning: unknown hauppauge model #%d\n",
+ pr_warn("%s: warning: unknown hauppauge model #%d\n",
dev->name, tv.model);
break;
}
- printk(KERN_INFO "%s: hauppauge eeprom: model=%d\n",
- dev->name, tv.model);
+ pr_info("%s: hauppauge eeprom: model=%d\n",
+ dev->name, tv.model);
}
/* Some TBS cards require initing a chip using a bitbanged SPI attached
@@ -1352,8 +1351,8 @@ int cx23885_tuner_callback(void *priv, int component, int command, int arg)
return 0;
if (command != 0) {
- printk(KERN_ERR "%s(): Unknown command 0x%x.\n",
- __func__, command);
+ pr_err("%s(): Unknown command 0x%x.\n",
+ __func__, command);
return -EINVAL;
}
@@ -2336,12 +2335,12 @@ void cx23885_card_setup(struct cx23885_dev *dev)
filename = "dvb-netup-altera-01.fw";
break;
}
- printk(KERN_INFO "NetUP card rev=0x%x fw_filename=%s\n",
- cinfo.rev, filename);
+ pr_info("NetUP card rev=0x%x fw_filename=%s\n",
+ cinfo.rev, filename);
ret = request_firmware(&fw, filename, &dev->pci->dev);
if (ret != 0)
- printk(KERN_ERR "did not find the firmware file. (%s) Please see linux/Documentation/dvb/ for more details on firmware-problems.",
+ pr_err("did not find the firmware file. (%s) Please see linux/Documentation/dvb/ for more details on firmware-problems.",
filename);
else
altera_init(&netup_config, fw);