diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2007-07-17 12:42:43 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-07-20 16:35:46 -0400 |
commit | ae38d93bd710d8014925f1cb9b689dc89c13d778 (patch) | |
tree | 22c2248afdfa33ae294f9ba4d16d03f4f467a658 /drivers/media | |
parent | 11d28766deedc8bcadc87db8a65775a41c15789a (diff) |
V4L/DVB (5854): ivtv: cleanup of driver messages
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/video/ivtv/ivtv-driver.c | 39 | ||||
-rw-r--r-- | drivers/media/video/ivtv/ivtv-fileops.c | 2 | ||||
-rw-r--r-- | drivers/media/video/ivtv/ivtv-firmware.c | 8 | ||||
-rw-r--r-- | drivers/media/video/ivtv/ivtv-gpio.c | 2 | ||||
-rw-r--r-- | drivers/media/video/ivtv/ivtv-i2c.c | 10 |
5 files changed, 29 insertions, 32 deletions
diff --git a/drivers/media/video/ivtv/ivtv-driver.c b/drivers/media/video/ivtv/ivtv-driver.c index 8bccb0e8d27b..9e4edb8b7d82 100644 --- a/drivers/media/video/ivtv/ivtv-driver.c +++ b/drivers/media/video/ivtv/ivtv-driver.c | |||
@@ -426,7 +426,7 @@ static void ivtv_process_eeprom(struct ivtv *itv) | |||
426 | if (itv->options.newi2c == -1 && tv.has_ir != -1 && tv.has_ir != 2) { | 426 | if (itv->options.newi2c == -1 && tv.has_ir != -1 && tv.has_ir != 2) { |
427 | itv->options.newi2c = (tv.has_ir & 2) ? 1 : 0; | 427 | itv->options.newi2c = (tv.has_ir & 2) ? 1 : 0; |
428 | if (itv->options.newi2c) { | 428 | if (itv->options.newi2c) { |
429 | IVTV_INFO("reopen i2c bus for IR-blaster support\n"); | 429 | IVTV_INFO("Reopen i2c bus for IR-blaster support\n"); |
430 | exit_ivtv_i2c(itv); | 430 | exit_ivtv_i2c(itv); |
431 | init_ivtv_i2c(itv); | 431 | init_ivtv_i2c(itv); |
432 | } | 432 | } |
@@ -950,7 +950,7 @@ static int __devinit ivtv_probe(struct pci_dev *dev, | |||
950 | 950 | ||
951 | /* Make sure we've got a place for this card */ | 951 | /* Make sure we've got a place for this card */ |
952 | if (ivtv_cards_active == IVTV_MAX_CARDS) { | 952 | if (ivtv_cards_active == IVTV_MAX_CARDS) { |
953 | printk(KERN_ERR "ivtv: Maximum number of cards detected (%d).\n", | 953 | printk(KERN_ERR "ivtv: Maximum number of cards detected (%d)\n", |
954 | ivtv_cards_active); | 954 | ivtv_cards_active); |
955 | spin_unlock(&ivtv_cards_lock); | 955 | spin_unlock(&ivtv_cards_lock); |
956 | return -ENOMEM; | 956 | return -ENOMEM; |
@@ -965,9 +965,7 @@ static int __devinit ivtv_probe(struct pci_dev *dev, | |||
965 | itv->dev = dev; | 965 | itv->dev = dev; |
966 | itv->num = ivtv_cards_active++; | 966 | itv->num = ivtv_cards_active++; |
967 | snprintf(itv->name, sizeof(itv->name) - 1, "ivtv%d", itv->num); | 967 | snprintf(itv->name, sizeof(itv->name) - 1, "ivtv%d", itv->num); |
968 | if (itv->num) { | 968 | IVTV_INFO("Initializing card #%d\n", itv->num); |
969 | printk(KERN_INFO "ivtv: ====================== NEXT CARD ======================\n"); | ||
970 | } | ||
971 | 969 | ||
972 | spin_unlock(&ivtv_cards_lock); | 970 | spin_unlock(&ivtv_cards_lock); |
973 | 971 | ||
@@ -1214,7 +1212,7 @@ static int __devinit ivtv_probe(struct pci_dev *dev, | |||
1214 | if (itv->has_cx23415) | 1212 | if (itv->has_cx23415) |
1215 | ivtv_set_osd_alpha(itv); | 1213 | ivtv_set_osd_alpha(itv); |
1216 | 1214 | ||
1217 | IVTV_INFO("Initialized %s, card #%d\n", itv->card_name, itv->num); | 1215 | IVTV_INFO("Initialized card #%d: %s\n", itv->num, itv->card_name); |
1218 | 1216 | ||
1219 | return 0; | 1217 | return 0; |
1220 | 1218 | ||
@@ -1247,15 +1245,15 @@ static void ivtv_remove(struct pci_dev *pci_dev) | |||
1247 | { | 1245 | { |
1248 | struct ivtv *itv = pci_get_drvdata(pci_dev); | 1246 | struct ivtv *itv = pci_get_drvdata(pci_dev); |
1249 | 1247 | ||
1250 | IVTV_DEBUG_INFO("Removing Card #%d.\n", itv->num); | 1248 | IVTV_DEBUG_INFO("Removing Card #%d\n", itv->num); |
1251 | 1249 | ||
1252 | /* Stop all captures */ | 1250 | /* Stop all captures */ |
1253 | IVTV_DEBUG_INFO(" Stopping all streams.\n"); | 1251 | IVTV_DEBUG_INFO("Stopping all streams\n"); |
1254 | if (atomic_read(&itv->capturing) > 0) | 1252 | if (atomic_read(&itv->capturing) > 0) |
1255 | ivtv_stop_all_captures(itv); | 1253 | ivtv_stop_all_captures(itv); |
1256 | 1254 | ||
1257 | /* Stop all decoding */ | 1255 | /* Stop all decoding */ |
1258 | IVTV_DEBUG_INFO(" Stopping decoding.\n"); | 1256 | IVTV_DEBUG_INFO("Stopping decoding\n"); |
1259 | if (atomic_read(&itv->decoding) > 0) { | 1257 | if (atomic_read(&itv->decoding) > 0) { |
1260 | int type; | 1258 | int type; |
1261 | 1259 | ||
@@ -1268,30 +1266,30 @@ static void ivtv_remove(struct pci_dev *pci_dev) | |||
1268 | } | 1266 | } |
1269 | 1267 | ||
1270 | /* Interrupts */ | 1268 | /* Interrupts */ |
1271 | IVTV_DEBUG_INFO(" Disabling interrupts.\n"); | 1269 | IVTV_DEBUG_INFO("Disabling interrupts\n"); |
1272 | ivtv_set_irq_mask(itv, 0xffffffff); | 1270 | ivtv_set_irq_mask(itv, 0xffffffff); |
1273 | del_timer_sync(&itv->dma_timer); | 1271 | del_timer_sync(&itv->dma_timer); |
1274 | 1272 | ||
1275 | /* Stop all Work Queues */ | 1273 | /* Stop all Work Queues */ |
1276 | IVTV_DEBUG_INFO(" Stop Work Queues.\n"); | 1274 | IVTV_DEBUG_INFO("Stop Work Queues\n"); |
1277 | flush_workqueue(itv->irq_work_queues); | 1275 | flush_workqueue(itv->irq_work_queues); |
1278 | destroy_workqueue(itv->irq_work_queues); | 1276 | destroy_workqueue(itv->irq_work_queues); |
1279 | 1277 | ||
1280 | IVTV_DEBUG_INFO(" Stopping Firmware.\n"); | 1278 | IVTV_DEBUG_INFO("Stopping Firmware\n"); |
1281 | ivtv_halt_firmware(itv); | 1279 | ivtv_halt_firmware(itv); |
1282 | 1280 | ||
1283 | IVTV_DEBUG_INFO(" Unregistering v4l devices.\n"); | 1281 | IVTV_DEBUG_INFO("Unregistering v4l devices\n"); |
1284 | ivtv_streams_cleanup(itv); | 1282 | ivtv_streams_cleanup(itv); |
1285 | IVTV_DEBUG_INFO(" Freeing dma resources.\n"); | 1283 | IVTV_DEBUG_INFO("Freeing dma resources\n"); |
1286 | ivtv_udma_free(itv); | 1284 | ivtv_udma_free(itv); |
1287 | 1285 | ||
1288 | exit_ivtv_i2c(itv); | 1286 | exit_ivtv_i2c(itv); |
1289 | 1287 | ||
1290 | IVTV_DEBUG_INFO(" Releasing irq.\n"); | 1288 | IVTV_DEBUG_INFO(" Releasing irq\n"); |
1291 | free_irq(itv->dev->irq, (void *)itv); | 1289 | free_irq(itv->dev->irq, (void *)itv); |
1292 | ivtv_iounmap(itv); | 1290 | ivtv_iounmap(itv); |
1293 | 1291 | ||
1294 | IVTV_DEBUG_INFO(" Releasing mem.\n"); | 1292 | IVTV_DEBUG_INFO(" Releasing mem\n"); |
1295 | release_mem_region(itv->base_addr, IVTV_ENCODER_SIZE); | 1293 | release_mem_region(itv->base_addr, IVTV_ENCODER_SIZE); |
1296 | release_mem_region(itv->base_addr + IVTV_REG_OFFSET, IVTV_REG_SIZE); | 1294 | release_mem_region(itv->base_addr + IVTV_REG_OFFSET, IVTV_REG_SIZE); |
1297 | if (itv->has_cx23415) | 1295 | if (itv->has_cx23415) |
@@ -1312,28 +1310,27 @@ static struct pci_driver ivtv_pci_driver = { | |||
1312 | 1310 | ||
1313 | static int module_start(void) | 1311 | static int module_start(void) |
1314 | { | 1312 | { |
1315 | printk(KERN_INFO "ivtv: ==================== START INIT IVTV ====================\n"); | 1313 | printk(KERN_INFO "ivtv: Start initialization, version %s\n", IVTV_VERSION); |
1316 | printk(KERN_INFO "ivtv: version %s loading\n", IVTV_VERSION); | ||
1317 | 1314 | ||
1318 | memset(ivtv_cards, 0, sizeof(ivtv_cards)); | 1315 | memset(ivtv_cards, 0, sizeof(ivtv_cards)); |
1319 | 1316 | ||
1320 | /* Validate parameters */ | 1317 | /* Validate parameters */ |
1321 | if (ivtv_first_minor < 0 || ivtv_first_minor >= IVTV_MAX_CARDS) { | 1318 | if (ivtv_first_minor < 0 || ivtv_first_minor >= IVTV_MAX_CARDS) { |
1322 | printk(KERN_ERR "ivtv: ivtv_first_minor must be between 0 and %d. Exiting...\n", | 1319 | printk(KERN_ERR "ivtv: Exiting, ivtv_first_minor must be between 0 and %d\n", |
1323 | IVTV_MAX_CARDS - 1); | 1320 | IVTV_MAX_CARDS - 1); |
1324 | return -1; | 1321 | return -1; |
1325 | } | 1322 | } |
1326 | 1323 | ||
1327 | if (ivtv_debug < 0 || ivtv_debug > 1023) { | 1324 | if (ivtv_debug < 0 || ivtv_debug > 1023) { |
1328 | ivtv_debug = 0; | 1325 | ivtv_debug = 0; |
1329 | printk(KERN_INFO "ivtv: debug value must be >= 0 and <= 1023!\n"); | 1326 | printk(KERN_INFO "ivtv: Debug value must be >= 0 and <= 1023\n"); |
1330 | } | 1327 | } |
1331 | 1328 | ||
1332 | if (pci_register_driver(&ivtv_pci_driver)) { | 1329 | if (pci_register_driver(&ivtv_pci_driver)) { |
1333 | printk(KERN_ERR "ivtv: Error detecting PCI card\n"); | 1330 | printk(KERN_ERR "ivtv: Error detecting PCI card\n"); |
1334 | return -ENODEV; | 1331 | return -ENODEV; |
1335 | } | 1332 | } |
1336 | printk(KERN_INFO "ivtv: ==================== END INIT IVTV ====================\n"); | 1333 | printk(KERN_INFO "ivtv: End initialization\n"); |
1337 | return 0; | 1334 | return 0; |
1338 | } | 1335 | } |
1339 | 1336 | ||
diff --git a/drivers/media/video/ivtv/ivtv-fileops.c b/drivers/media/video/ivtv/ivtv-fileops.c index ee7e884e9c4f..489fbf25e723 100644 --- a/drivers/media/video/ivtv/ivtv-fileops.c +++ b/drivers/media/video/ivtv/ivtv-fileops.c | |||
@@ -832,7 +832,7 @@ int ivtv_v4l2_open(struct inode *inode, struct file *filp) | |||
832 | if (itv == NULL) { | 832 | if (itv == NULL) { |
833 | /* Couldn't find a device registered | 833 | /* Couldn't find a device registered |
834 | on that minor, shouldn't happen! */ | 834 | on that minor, shouldn't happen! */ |
835 | printk(KERN_WARNING "ivtv: no ivtv device found on minor %d\n", minor); | 835 | printk(KERN_WARNING "ivtv: No ivtv device found on minor %d\n", minor); |
836 | return -ENXIO; | 836 | return -ENXIO; |
837 | } | 837 | } |
838 | 838 | ||
diff --git a/drivers/media/video/ivtv/ivtv-firmware.c b/drivers/media/video/ivtv/ivtv-firmware.c index 2b6208a6a108..5bc45c9f0df2 100644 --- a/drivers/media/video/ivtv/ivtv-firmware.c +++ b/drivers/media/video/ivtv/ivtv-firmware.c | |||
@@ -61,7 +61,7 @@ retry: | |||
61 | the wrong file was sometimes loaded. So we check filesizes to | 61 | the wrong file was sometimes loaded. So we check filesizes to |
62 | see if at least the right-sized file was loaded. If not, then we | 62 | see if at least the right-sized file was loaded. If not, then we |
63 | retry. */ | 63 | retry. */ |
64 | IVTV_INFO("retry: file loaded was not %s (expected size %ld, got %zd)\n", fn, size, fw->size); | 64 | IVTV_INFO("Retry: file loaded was not %s (expected size %ld, got %zd)\n", fn, size, fw->size); |
65 | release_firmware(fw); | 65 | release_firmware(fw); |
66 | retries--; | 66 | retries--; |
67 | goto retry; | 67 | goto retry; |
@@ -73,11 +73,11 @@ retry: | |||
73 | src++; | 73 | src++; |
74 | } | 74 | } |
75 | release_firmware(fw); | 75 | release_firmware(fw); |
76 | IVTV_INFO("loaded %s firmware (%zd bytes)\n", fn, fw->size); | 76 | IVTV_INFO("Loaded %s firmware (%zd bytes)\n", fn, fw->size); |
77 | return size; | 77 | return size; |
78 | } | 78 | } |
79 | IVTV_ERR("unable to open firmware %s (must be %ld bytes)\n", fn, size); | 79 | IVTV_ERR("Unable to open firmware %s (must be %ld bytes)\n", fn, size); |
80 | IVTV_ERR("did you put the firmware in the hotplug firmware directory?\n"); | 80 | IVTV_ERR("Did you put the firmware in the hotplug firmware directory?\n"); |
81 | return -ENOMEM; | 81 | return -ENOMEM; |
82 | } | 82 | } |
83 | 83 | ||
diff --git a/drivers/media/video/ivtv/ivtv-gpio.c b/drivers/media/video/ivtv/ivtv-gpio.c index 676418cbaaad..6a5a7aa66976 100644 --- a/drivers/media/video/ivtv/ivtv-gpio.c +++ b/drivers/media/video/ivtv/ivtv-gpio.c | |||
@@ -130,7 +130,7 @@ int ivtv_reset_tuner_gpio(enum v4l2_tuner_type mode, void *priv, int ptr) | |||
130 | 130 | ||
131 | if (itv->card->type != IVTV_CARD_PG600V2 || itv->options.tuner != TUNER_XCEIVE_XC3028) | 131 | if (itv->card->type != IVTV_CARD_PG600V2 || itv->options.tuner != TUNER_XCEIVE_XC3028) |
132 | return -EINVAL; | 132 | return -EINVAL; |
133 | IVTV_INFO("Resetting tuner.\n"); | 133 | IVTV_INFO("Resetting tuner\n"); |
134 | curout = read_reg(IVTV_REG_GPIO_OUT); | 134 | curout = read_reg(IVTV_REG_GPIO_OUT); |
135 | curdir = read_reg(IVTV_REG_GPIO_DIR); | 135 | curdir = read_reg(IVTV_REG_GPIO_DIR); |
136 | curdir |= (1 << 12); /* GPIO bit 12 */ | 136 | curdir |= (1 << 12); /* GPIO bit 12 */ |
diff --git a/drivers/media/video/ivtv/ivtv-i2c.c b/drivers/media/video/ivtv/ivtv-i2c.c index 7143554234ff..b3557435456d 100644 --- a/drivers/media/video/ivtv/ivtv-i2c.c +++ b/drivers/media/video/ivtv/ivtv-i2c.c | |||
@@ -144,7 +144,7 @@ static int attach_inform(struct i2c_client *client) | |||
144 | } | 144 | } |
145 | } | 145 | } |
146 | if (i == I2C_CLIENTS_MAX) { | 146 | if (i == I2C_CLIENTS_MAX) { |
147 | IVTV_ERR("insufficient room for new I2C client!\n"); | 147 | IVTV_ERR("Insufficient room for new I2C client\n"); |
148 | } | 148 | } |
149 | return 0; | 149 | return 0; |
150 | } | 150 | } |
@@ -569,7 +569,7 @@ int ivtv_call_i2c_client(struct ivtv *itv, int addr, unsigned int cmd, void *arg | |||
569 | } | 569 | } |
570 | } | 570 | } |
571 | if (cmd != VIDIOC_G_CHIP_IDENT) | 571 | if (cmd != VIDIOC_G_CHIP_IDENT) |
572 | IVTV_ERR("i2c addr 0x%02x not found for command 0x%x!\n", addr, cmd); | 572 | IVTV_ERR("i2c addr 0x%02x not found for command 0x%x\n", addr, cmd); |
573 | return -ENODEV; | 573 | return -ENODEV; |
574 | } | 574 | } |
575 | 575 | ||
@@ -640,7 +640,7 @@ int ivtv_i2c_hw(struct ivtv *itv, u32 hw, unsigned int cmd, void *arg) | |||
640 | 640 | ||
641 | addr = ivtv_i2c_hw_addr(itv, hw); | 641 | addr = ivtv_i2c_hw_addr(itv, hw); |
642 | if (addr < 0) { | 642 | if (addr < 0) { |
643 | IVTV_ERR("i2c hardware 0x%08x (%s) not found for command 0x%x!\n", | 643 | IVTV_ERR("i2c hardware 0x%08x (%s) not found for command 0x%x\n", |
644 | hw, ivtv_i2c_hw_name(hw), cmd); | 644 | hw, ivtv_i2c_hw_name(hw), cmd); |
645 | return addr; | 645 | return addr; |
646 | } | 646 | } |
@@ -655,7 +655,7 @@ int ivtv_i2c_id(struct ivtv *itv, u32 id, unsigned int cmd, void *arg) | |||
655 | addr = ivtv_i2c_id_addr(itv, id); | 655 | addr = ivtv_i2c_id_addr(itv, id); |
656 | if (addr < 0) { | 656 | if (addr < 0) { |
657 | if (cmd != VIDIOC_G_CHIP_IDENT) | 657 | if (cmd != VIDIOC_G_CHIP_IDENT) |
658 | IVTV_ERR("i2c ID 0x%08x (%s) not found for command 0x%x!\n", | 658 | IVTV_ERR("i2c ID 0x%08x (%s) not found for command 0x%x\n", |
659 | id, ivtv_i2c_id_name(id), cmd); | 659 | id, ivtv_i2c_id_name(id), cmd); |
660 | return addr; | 660 | return addr; |
661 | } | 661 | } |
@@ -696,7 +696,7 @@ int ivtv_upd64083(struct ivtv *itv, unsigned int cmd, void *arg) | |||
696 | void ivtv_call_i2c_clients(struct ivtv *itv, unsigned int cmd, void *arg) | 696 | void ivtv_call_i2c_clients(struct ivtv *itv, unsigned int cmd, void *arg) |
697 | { | 697 | { |
698 | if (itv->i2c_adap.algo == NULL) { | 698 | if (itv->i2c_adap.algo == NULL) { |
699 | IVTV_ERR("adapter is not set"); | 699 | IVTV_ERR("Adapter is not set"); |
700 | return; | 700 | return; |
701 | } | 701 | } |
702 | i2c_clients_command(&itv->i2c_adap, cmd, arg); | 702 | i2c_clients_command(&itv->i2c_adap, cmd, arg); |