[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1204361928-30229-8-git-send-email-petkovbb@gmail.com>
Date: Sat, 1 Mar 2008 09:58:31 +0100
From: Borislav Petkov <petkovbb@...glemail.com>
To: <bzolnier@...il.com>
Cc: linux-ide@...r.kernel.org, linux-kernel@...r.kernel.org,
Borislav Petkov <petkovbb@...il.com>
Subject: [PATCH 07/24] ide-tape: remove pipeline-specific code bits from idetape_chrdev_read
Also, simplify multiple-nested if construct.
Signed-off-by: Borislav Petkov <petkovbb@...il.com>
---
drivers/ide/ide-tape.c | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c
index a54c1cb..99d6b29 100644
--- a/drivers/ide/ide-tape.c
+++ b/drivers/ide/ide-tape.c
@@ -2278,7 +2278,7 @@ static void idetape_restart_speed_control(ide_drive_t *drive)
tape->uncontrolled_previous_head_time = jiffies;
}
-static int idetape_init_read(ide_drive_t *drive, int max_stages)
+static int idetape_init_read(ide_drive_t *drive)
{
idetape_tape_t *tape = drive->driver_data;
struct request rq;
@@ -2562,13 +2562,13 @@ static ssize_t idetape_chrdev_read(struct file *file, char __user *buf,
debug_log(DBG_CHRDEV, "Enter %s, count %Zd\n", __func__, count);
- if (tape->chrdev_dir != IDETAPE_DIR_READ) {
- if (test_bit(IDETAPE_FLAG_DETECT_BS, &tape->flags))
- if (count > tape->blk_size &&
- (count % tape->blk_size) == 0)
- tape->user_bs_factor = count / tape->blk_size;
- }
- rc = idetape_init_read(drive, tape->max_stages);
+ if (tape->chrdev_dir != IDETAPE_DIR_READ &&
+ test_bit(IDETAPE_FLAG_DETECT_BS, &tape->flags) &&
+ count > tape->blk_size &&
+ (count % tape->blk_size) == 0)
+ tape->user_bs_factor = count / tape->blk_size;
+
+ rc = idetape_init_read(drive);
if (rc < 0)
return rc;
if (count == 0)
--
1.5.4.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists