Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 199909
b: refs/heads/master
c: 28f4197
h: refs/heads/master
i:
  199907: c2100a7
v: v3
  • Loading branch information
Jens Axboe committed Jun 1, 2010
1 parent a6a9782 commit 4ddc5e3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 713b686494a577b3c4f4f9f585a4705fc30d51c2
refs/heads/master: 28f4197e5d4707311febeec8a0eb97cb5fd93c97
9 changes: 9 additions & 0 deletions trunk/include/linux/blkdev.h
Original file line number Diff line number Diff line change
Expand Up @@ -1211,14 +1211,23 @@ struct work_struct;
int kblockd_schedule_work(struct request_queue *q, struct work_struct *work);

#ifdef CONFIG_BLK_CGROUP
/*
* This should not be using sched_clock(). A real patch is in progress
* to fix this up, until that is in place we need to disable preemption
* around sched_clock() in this function and set_io_start_time_ns().
*/
static inline void set_start_time_ns(struct request *req)
{
preempt_disable();
req->start_time_ns = sched_clock();
preempt_enable();
}

static inline void set_io_start_time_ns(struct request *req)
{
preempt_disable();
req->io_start_time_ns = sched_clock();
preempt_enable();
}

static inline uint64_t rq_start_time_ns(struct request *req)
Expand Down

0 comments on commit 4ddc5e3

Please sign in to comment.