Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 93760
b: refs/heads/master
c: 9798630
h: refs/heads/master
v: v3
  • Loading branch information
Borislav Petkov authored and Bartlomiej Zolnierkiewicz committed Apr 27, 2008
1 parent d726aaa commit 70011a8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fd0949e6e84e4e1649d8ea7367e78e72f59bb19f
refs/heads/master: 9798630a75c2c13849aeefcc1ba0559a701b5d95
11 changes: 4 additions & 7 deletions trunk/drivers/ide/ide-tape.c
Original file line number Diff line number Diff line change
Expand Up @@ -1641,12 +1641,12 @@ static int idetape_create_prevent_cmd(ide_drive_t *drive,
return 1;
}

static int __idetape_discard_read_pipeline(ide_drive_t *drive)
static void __idetape_discard_read_pipeline(ide_drive_t *drive)
{
idetape_tape_t *tape = drive->driver_data;

if (tape->chrdev_dir != IDETAPE_DIR_READ)
return 0;
return;

clear_bit(IDETAPE_FLAG_FILEMARK, &tape->flags);
tape->merge_stage_size = 0;
Expand All @@ -1656,8 +1656,6 @@ static int __idetape_discard_read_pipeline(ide_drive_t *drive)
}

tape->chrdev_dir = IDETAPE_DIR_NONE;

return 0;
}

/*
Expand Down Expand Up @@ -1689,13 +1687,12 @@ static void idetape_discard_read_pipeline(ide_drive_t *drive,
int restore_position)
{
idetape_tape_t *tape = drive->driver_data;
int cnt;
int seek, position;

cnt = __idetape_discard_read_pipeline(drive);
__idetape_discard_read_pipeline(drive);
if (restore_position) {
position = idetape_read_position(drive);
seek = position > cnt ? position - cnt : 0;
seek = position > 0 ? position : 0;
if (idetape_position_tape(drive, seek, 0, 0)) {
printk(KERN_INFO "ide-tape: %s: position_tape failed in"
" discard_pipeline()\n", tape->name);
Expand Down

0 comments on commit 70011a8

Please sign in to comment.