public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch 9/9] s390: minor tape fixes.
@ 2006-04-03 17:23 Martin Schwidefsky
  0 siblings, 0 replies; only message in thread
From: Martin Schwidefsky @ 2006-04-03 17:23 UTC (permalink / raw)
  To: akpm, peter.oberparleiter, linux-kernel

From: Peter Oberparleiter <peter.oberparleiter@de.ibm.com>

[patch 9/9] s390: minor tape fixes.

Cleanup of minor bugs found by a source code checker.

Signed-off-by: Peter Oberparleiter <peter.oberparleiter@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
---

 drivers/s390/char/tape_block.c |    4 ++--
 drivers/s390/char/tape_core.c  |   10 +++-------
 2 files changed, 5 insertions(+), 9 deletions(-)

diff -urpN linux-2.6/drivers/s390/char/tape_block.c linux-2.6-patched/drivers/s390/char/tape_block.c
--- linux-2.6/drivers/s390/char/tape_block.c	2006-04-03 18:46:20.000000000 +0200
+++ linux-2.6-patched/drivers/s390/char/tape_block.c	2006-04-03 18:46:42.000000000 +0200
@@ -432,8 +432,8 @@ tapeblock_ioctl(
 ) {
 	int rc;
 	int minor;
-	struct gendisk *disk = inode->i_bdev->bd_disk;
-	struct tape_device *device = disk->private_data;
+	struct gendisk *disk;
+	struct tape_device *device;
 
 	rc     = 0;
 	disk   = inode->i_bdev->bd_disk;
diff -urpN linux-2.6/drivers/s390/char/tape_core.c linux-2.6-patched/drivers/s390/char/tape_core.c
--- linux-2.6/drivers/s390/char/tape_core.c	2006-04-03 18:46:20.000000000 +0200
+++ linux-2.6-patched/drivers/s390/char/tape_core.c	2006-04-03 18:46:42.000000000 +0200
@@ -210,18 +210,14 @@ tape_state_set(struct tape_device *devic
 		return;
 	}
 	DBF_EVENT(4, "ts. dev:	%x\n", device->first_minor);
-	if (device->tape_state < TO_SIZE && device->tape_state >= 0)
-		str = tape_state_verbose[device->tape_state];
-	else
-		str = "UNKNOWN TS";
-	DBF_EVENT(4, "old ts:	%s\n", str);
-	if (device->tape_state < TO_SIZE && device->tape_state >=0 )
+	DBF_EVENT(4, "old ts:\t\n");
+	if (device->tape_state < TS_SIZE && device->tape_state >=0 )
 		str = tape_state_verbose[device->tape_state];
 	else
 		str = "UNKNOWN TS";
 	DBF_EVENT(4, "%s\n", str);
 	DBF_EVENT(4, "new ts:\t\n");
-	if (newstate < TO_SIZE && newstate >= 0)
+	if (newstate < TS_SIZE && newstate >= 0)
 		str = tape_state_verbose[newstate];
 	else
 		str = "UNKNOWN TS";

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-04-03 17:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-03 17:23 [patch 9/9] s390: minor tape fixes Martin Schwidefsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox