Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 249131
b: refs/heads/master
c: aac7af6
h: refs/heads/master
i:
  249129: d0a0ba8
  249127: eb99311
v: v3
  • Loading branch information
K. Y. Srinivasan authored and Greg Kroah-Hartman committed Apr 25, 2011
1 parent acf7b2a commit 2cf829e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 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: 26a197396253c1774b2affce2e29306aca9ee86a
refs/heads/master: aac7af6db1aa4e0e85791f39a168decefb4b15f5
9 changes: 1 addition & 8 deletions trunk/drivers/staging/hv/blkvsc_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ struct block_device_context {
unsigned int device_id_len;
int num_outstanding_reqs;
int shutting_down;
int media_not_present;
unsigned int sector_size;
sector_t capacity;
unsigned int port;
Expand Down Expand Up @@ -446,7 +445,6 @@ static int blkvsc_do_operation(struct block_device_context *blkdev,
case DO_CAPACITY:
blkdev->sector_size = 0;
blkdev->capacity = 0;
blkdev->media_not_present = 0; /* assume a disk is present */

blkvsc_req->cmnd[0] = READ_CAPACITY;
blkvsc_req->cmd_len = 16;
Expand All @@ -473,10 +471,6 @@ static int blkvsc_do_operation(struct block_device_context *blkdev,
scsi_normalize_sense(blkvsc_req->sense_buffer,
SCSI_SENSE_BUFFERSIZE, &sense_hdr);

if (sense_hdr.asc == 0x3A)
/* Medium not present */
blkdev->media_not_present = 1;

return 0;
}

Expand Down Expand Up @@ -964,8 +958,7 @@ static void blkvsc_request(struct request_queue *queue)
DPRINT_DBG(BLKVSC_DRV, "- req %p\n", req);

blkdev = req->rq_disk->private_data;
if (blkdev->shutting_down || req->cmd_type != REQ_TYPE_FS ||
blkdev->media_not_present) {
if (blkdev->shutting_down || req->cmd_type != REQ_TYPE_FS) {
__blk_end_request_cur(req, 0);
continue;
}
Expand Down

0 comments on commit 2cf829e

Please sign in to comment.