diff options
Diffstat (limited to 'include/linux/blkdev.h')
| -rw-r--r-- | include/linux/blkdev.h | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index b54a0348a890..21a8674cd149 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h | |||
| @@ -54,16 +54,23 @@ struct as_io_context { | |||
| 54 | 54 | ||
| 55 | struct cfq_queue; | 55 | struct cfq_queue; |
| 56 | struct cfq_io_context { | 56 | struct cfq_io_context { |
| 57 | void (*dtor)(struct cfq_io_context *); | ||
| 58 | void (*exit)(struct cfq_io_context *); | ||
| 59 | |||
| 60 | struct io_context *ioc; | ||
| 61 | |||
| 62 | /* | 57 | /* |
| 63 | * circular list of cfq_io_contexts belonging to a process io context | 58 | * circular list of cfq_io_contexts belonging to a process io context |
| 64 | */ | 59 | */ |
| 65 | struct list_head list; | 60 | struct list_head list; |
| 66 | struct cfq_queue *cfqq; | 61 | struct cfq_queue *cfqq; |
| 62 | void *key; | ||
| 63 | |||
| 64 | struct io_context *ioc; | ||
| 65 | |||
| 66 | unsigned long last_end_request; | ||
| 67 | unsigned long last_queue; | ||
| 68 | unsigned long ttime_total; | ||
| 69 | unsigned long ttime_samples; | ||
| 70 | unsigned long ttime_mean; | ||
| 71 | |||
| 72 | void (*dtor)(struct cfq_io_context *); | ||
| 73 | void (*exit)(struct cfq_io_context *); | ||
| 67 | }; | 74 | }; |
| 68 | 75 | ||
| 69 | /* | 76 | /* |
| @@ -73,7 +80,9 @@ struct cfq_io_context { | |||
| 73 | */ | 80 | */ |
| 74 | struct io_context { | 81 | struct io_context { |
| 75 | atomic_t refcount; | 82 | atomic_t refcount; |
| 76 | pid_t pid; | 83 | struct task_struct *task; |
| 84 | |||
| 85 | int (*set_ioprio)(struct io_context *, unsigned int); | ||
| 77 | 86 | ||
| 78 | /* | 87 | /* |
| 79 | * For request batching | 88 | * For request batching |
| @@ -81,8 +90,6 @@ struct io_context { | |||
| 81 | unsigned long last_waited; /* Time last woken after wait for request */ | 90 | unsigned long last_waited; /* Time last woken after wait for request */ |
| 82 | int nr_batch_requests; /* Number of requests left in the batch */ | 91 | int nr_batch_requests; /* Number of requests left in the batch */ |
| 83 | 92 | ||
| 84 | spinlock_t lock; | ||
| 85 | |||
| 86 | struct as_io_context *aic; | 93 | struct as_io_context *aic; |
| 87 | struct cfq_io_context *cic; | 94 | struct cfq_io_context *cic; |
| 88 | }; | 95 | }; |
| @@ -134,6 +141,8 @@ struct request { | |||
| 134 | 141 | ||
| 135 | void *elevator_private; | 142 | void *elevator_private; |
| 136 | 143 | ||
| 144 | unsigned short ioprio; | ||
| 145 | |||
| 137 | int rq_status; /* should split this into a few status bits */ | 146 | int rq_status; /* should split this into a few status bits */ |
| 138 | struct gendisk *rq_disk; | 147 | struct gendisk *rq_disk; |
| 139 | int errors; | 148 | int errors; |
