Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 7636
b: refs/heads/master
c: e1f546e
h: refs/heads/master
v: v3
  • Loading branch information
James Bottomley authored and Jens Axboe committed Jun 20, 2005
1 parent c912d70 commit 7c17499
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 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: f1970baf6d74e03bd32072ab453f2fc01bc1b8d3
refs/heads/master: e1f546e185e9d8cb9303d74d1cd5bc704f265384
5 changes: 2 additions & 3 deletions trunk/drivers/block/scsi_ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ static int sg_io(struct file *file, request_queue_t *q,
struct gendisk *bd_disk, struct sg_io_hdr *hdr)
{
unsigned long start_time;
int reading, writing, ret;
int reading, writing, ret = 0;
struct request *rq;
struct bio *bio;
char sense[SCSI_SENSE_BUFFERSIZE];
Expand Down Expand Up @@ -249,7 +249,6 @@ static int sg_io(struct file *file, request_queue_t *q,
reading = 1;
break;
}
}

rq = blk_get_request(q, writing ? WRITE : READ, GFP_KERNEL);
if (!rq)
Expand Down Expand Up @@ -335,7 +334,7 @@ static int sg_io(struct file *file, request_queue_t *q,
hdr->sb_len_wr = len;
}

if (blk_rq_unmap_user(rq, bio, hdr->dxfer_len))
if (blk_rq_unmap_user(bio, hdr->dxfer_len))
ret = -EFAULT;

/* may not have succeeded, but output values written to control
Expand Down

0 comments on commit 7c17499

Please sign in to comment.