Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 110456
b: refs/heads/master
c: 1a8e2bd
h: refs/heads/master
v: v3
  • Loading branch information
David Woodhouse authored and Jens Axboe committed Oct 9, 2008
1 parent 77b22a0 commit 751c943
Show file tree
Hide file tree
Showing 3 changed files with 8 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: e17fc0a1ccf88f6d4dcb363729f3141b0958c325
refs/heads/master: 1a8e2bddd5c29008f311613e75925fecbf522c5b
9 changes: 6 additions & 3 deletions trunk/drivers/block/ps3disk.c
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,8 @@ static void ps3disk_do_request(struct ps3_storage_device *dev,
if (blk_fs_request(req)) {
if (ps3disk_submit_request_sg(dev, req))
break;
} else if (req->cmd_type == REQ_TYPE_FLUSH) {
} else if (req->cmd_type == REQ_TYPE_LINUX_BLOCK &&
req->cmd[0] == REQ_LB_OP_FLUSH) {
if (ps3disk_submit_flush_request(dev, req))
break;
} else {
Expand Down Expand Up @@ -257,7 +258,8 @@ static irqreturn_t ps3disk_interrupt(int irq, void *data)
return IRQ_HANDLED;
}

if (req->cmd_type == REQ_TYPE_FLUSH) {
if (req->cmd_type == REQ_TYPE_LINUX_BLOCK &&
req->cmd[0] == REQ_LB_OP_FLUSH) {
read = 0;
num_sectors = req->hard_cur_sectors;
op = "flush";
Expand Down Expand Up @@ -405,7 +407,8 @@ static void ps3disk_prepare_flush(struct request_queue *q, struct request *req)

dev_dbg(&dev->sbd.core, "%s:%u\n", __func__, __LINE__);

req->cmd_type = REQ_TYPE_FLUSH;
req->cmd_type = REQ_TYPE_LINUX_BLOCK;
req->cmd[0] = REQ_LB_OP_FLUSH;
}

static unsigned long ps3disk_mask;
Expand Down
6 changes: 1 addition & 5 deletions trunk/include/linux/blkdev.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ enum rq_cmd_type_bits {
REQ_TYPE_PM_SUSPEND, /* suspend request */
REQ_TYPE_PM_RESUME, /* resume request */
REQ_TYPE_PM_SHUTDOWN, /* shutdown request */
REQ_TYPE_FLUSH, /* flush request */
REQ_TYPE_SPECIAL, /* driver defined type */
REQ_TYPE_LINUX_BLOCK, /* generic block layer message */
/*
Expand All @@ -76,11 +75,8 @@ enum rq_cmd_type_bits {
*
*/
enum {
/*
* just examples for now
*/
REQ_LB_OP_EJECT = 0x40, /* eject request */
REQ_LB_OP_FLUSH = 0x41, /* flush device */
REQ_LB_OP_FLUSH = 0x41, /* flush request */
REQ_LB_OP_DISCARD = 0x42, /* discard sectors */
};

Expand Down

0 comments on commit 751c943

Please sign in to comment.