aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/char/tape_block.c
diff options
context:
space:
mode:
authorCarsten Otte <cotte@de.ibm.com>2009-03-26 10:24:38 -0400
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2009-03-26 10:24:25 -0400
commitab640db01013192f6867785a7def7c9d9ec8903d (patch)
tree3df0fb5b788eeaaa4b0540fbf136b20c9ffd56f4 /drivers/s390/char/tape_block.c
parent1edad85b16fdda43c8ab809e2779e8bf64ab8bb2 (diff)
[S390] tape message cleanup
This is a cleanup of all the messages this driver prints. It uses the dev_message macros now. Signed-off-by: Carsten Otte <cotte@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/char/tape_block.c')
-rw-r--r--drivers/s390/char/tape_block.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/drivers/s390/char/tape_block.c b/drivers/s390/char/tape_block.c
index ae18baf59f06..f32e89e7c4f2 100644
--- a/drivers/s390/char/tape_block.c
+++ b/drivers/s390/char/tape_block.c
@@ -10,6 +10,8 @@
10 * Stefan Bader <shbader@de.ibm.com> 10 * Stefan Bader <shbader@de.ibm.com>
11 */ 11 */
12 12
13#define KMSG_COMPONENT "tape"
14
13#include <linux/fs.h> 15#include <linux/fs.h>
14#include <linux/module.h> 16#include <linux/module.h>
15#include <linux/blkdev.h> 17#include <linux/blkdev.h>
@@ -23,8 +25,6 @@
23 25
24#include "tape.h" 26#include "tape.h"
25 27
26#define PRINTK_HEADER "TAPE_BLOCK: "
27
28#define TAPEBLOCK_MAX_SEC 100 28#define TAPEBLOCK_MAX_SEC 100
29#define TAPEBLOCK_MIN_REQUEUE 3 29#define TAPEBLOCK_MIN_REQUEUE 3
30 30
@@ -279,8 +279,6 @@ tapeblock_cleanup_device(struct tape_device *device)
279 tape_put_device(device); 279 tape_put_device(device);
280 280
281 if (!device->blk_data.disk) { 281 if (!device->blk_data.disk) {
282 PRINT_ERR("(%s): No gendisk to clean up!\n",
283 dev_name(&device->cdev->dev));
284 goto cleanup_queue; 282 goto cleanup_queue;
285 } 283 }
286 284
@@ -314,7 +312,8 @@ tapeblock_revalidate_disk(struct gendisk *disk)
314 if (!device->blk_data.medium_changed) 312 if (!device->blk_data.medium_changed)
315 return 0; 313 return 0;
316 314
317 PRINT_INFO("Detecting media size...\n"); 315 dev_info(&device->cdev->dev, "Determining the size of the recorded "
316 "area...\n");
318 rc = tape_mtop(device, MTFSFM, 1); 317 rc = tape_mtop(device, MTFSFM, 1);
319 if (rc) 318 if (rc)
320 return rc; 319 return rc;
@@ -341,7 +340,8 @@ tapeblock_revalidate_disk(struct gendisk *disk)
341 device->bof = rc; 340 device->bof = rc;
342 nr_of_blks -= rc; 341 nr_of_blks -= rc;
343 342
344 PRINT_INFO("Found %i blocks on media\n", nr_of_blks); 343 dev_info(&device->cdev->dev, "The size of the recorded area is %i "
344 "blocks\n", nr_of_blks);
345 set_capacity(device->blk_data.disk, 345 set_capacity(device->blk_data.disk,
346 nr_of_blks*(TAPEBLOCK_HSEC_SIZE/512)); 346 nr_of_blks*(TAPEBLOCK_HSEC_SIZE/512));
347 347
@@ -376,8 +376,8 @@ tapeblock_open(struct block_device *bdev, fmode_t mode)
376 376
377 if (device->required_tapemarks) { 377 if (device->required_tapemarks) {
378 DBF_EVENT(2, "TBLOCK: missing tapemarks\n"); 378 DBF_EVENT(2, "TBLOCK: missing tapemarks\n");
379 PRINT_ERR("TBLOCK: Refusing to open tape with missing" 379 dev_warn(&device->cdev->dev, "Opening the tape failed because"
380 " end of file marks.\n"); 380 " of missing end-of-file marks\n");
381 rc = -EPERM; 381 rc = -EPERM;
382 goto put_device; 382 goto put_device;
383 } 383 }
@@ -452,7 +452,6 @@ tapeblock_ioctl(
452 rc = -EINVAL; 452 rc = -EINVAL;
453 break; 453 break;
454 default: 454 default:
455 PRINT_WARN("invalid ioctl 0x%x\n", command);
456 rc = -EINVAL; 455 rc = -EINVAL;
457 } 456 }
458 457
@@ -474,7 +473,6 @@ tapeblock_init(void)
474 473
475 if (tapeblock_major == 0) 474 if (tapeblock_major == 0)
476 tapeblock_major = rc; 475 tapeblock_major = rc;
477 PRINT_INFO("tape gets major %d for block device\n", tapeblock_major);
478 return 0; 476 return 0;
479} 477}
480 478