diff options
author | Glenn Elliott <gelliott@cs.unc.edu> | 2012-03-04 19:47:13 -0500 |
---|---|---|
committer | Glenn Elliott <gelliott@cs.unc.edu> | 2012-03-04 19:47:13 -0500 |
commit | c71c03bda1e86c9d5198c5d83f712e695c4f2a1e (patch) | |
tree | ecb166cb3e2b7e2adb3b5e292245fefd23381ac8 /include/linux/elevator.h | |
parent | ea53c912f8a86a8567697115b6a0d8152beee5c8 (diff) | |
parent | 6a00f206debf8a5c8899055726ad127dbeeed098 (diff) |
Merge branch 'mpi-master' into wip-k-fmlpwip-k-fmlp
Conflicts:
litmus/sched_cedf.c
Diffstat (limited to 'include/linux/elevator.h')
-rw-r--r-- | include/linux/elevator.h | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/include/linux/elevator.h b/include/linux/elevator.h index 4fd978e7eb83..21a8ebf2dc3a 100644 --- a/include/linux/elevator.h +++ b/include/linux/elevator.h | |||
@@ -20,7 +20,6 @@ typedef void (elevator_bio_merged_fn) (struct request_queue *, | |||
20 | typedef int (elevator_dispatch_fn) (struct request_queue *, int); | 20 | typedef int (elevator_dispatch_fn) (struct request_queue *, int); |
21 | 21 | ||
22 | typedef void (elevator_add_req_fn) (struct request_queue *, struct request *); | 22 | typedef void (elevator_add_req_fn) (struct request_queue *, struct request *); |
23 | typedef int (elevator_queue_empty_fn) (struct request_queue *); | ||
24 | typedef struct request *(elevator_request_list_fn) (struct request_queue *, struct request *); | 23 | typedef struct request *(elevator_request_list_fn) (struct request_queue *, struct request *); |
25 | typedef void (elevator_completed_req_fn) (struct request_queue *, struct request *); | 24 | typedef void (elevator_completed_req_fn) (struct request_queue *, struct request *); |
26 | typedef int (elevator_may_queue_fn) (struct request_queue *, int); | 25 | typedef int (elevator_may_queue_fn) (struct request_queue *, int); |
@@ -46,7 +45,6 @@ struct elevator_ops | |||
46 | elevator_activate_req_fn *elevator_activate_req_fn; | 45 | elevator_activate_req_fn *elevator_activate_req_fn; |
47 | elevator_deactivate_req_fn *elevator_deactivate_req_fn; | 46 | elevator_deactivate_req_fn *elevator_deactivate_req_fn; |
48 | 47 | ||
49 | elevator_queue_empty_fn *elevator_queue_empty_fn; | ||
50 | elevator_completed_req_fn *elevator_completed_req_fn; | 48 | elevator_completed_req_fn *elevator_completed_req_fn; |
51 | 49 | ||
52 | elevator_request_list_fn *elevator_former_req_fn; | 50 | elevator_request_list_fn *elevator_former_req_fn; |
@@ -101,17 +99,16 @@ struct elevator_queue | |||
101 | */ | 99 | */ |
102 | extern void elv_dispatch_sort(struct request_queue *, struct request *); | 100 | extern void elv_dispatch_sort(struct request_queue *, struct request *); |
103 | extern void elv_dispatch_add_tail(struct request_queue *, struct request *); | 101 | extern void elv_dispatch_add_tail(struct request_queue *, struct request *); |
104 | extern void elv_add_request(struct request_queue *, struct request *, int, int); | 102 | extern void elv_add_request(struct request_queue *, struct request *, int); |
105 | extern void __elv_add_request(struct request_queue *, struct request *, int, int); | 103 | extern void __elv_add_request(struct request_queue *, struct request *, int); |
106 | extern void elv_insert(struct request_queue *, struct request *, int); | ||
107 | extern int elv_merge(struct request_queue *, struct request **, struct bio *); | 104 | extern int elv_merge(struct request_queue *, struct request **, struct bio *); |
105 | extern int elv_try_merge(struct request *, struct bio *); | ||
108 | extern void elv_merge_requests(struct request_queue *, struct request *, | 106 | extern void elv_merge_requests(struct request_queue *, struct request *, |
109 | struct request *); | 107 | struct request *); |
110 | extern void elv_merged_request(struct request_queue *, struct request *, int); | 108 | extern void elv_merged_request(struct request_queue *, struct request *, int); |
111 | extern void elv_bio_merged(struct request_queue *q, struct request *, | 109 | extern void elv_bio_merged(struct request_queue *q, struct request *, |
112 | struct bio *); | 110 | struct bio *); |
113 | extern void elv_requeue_request(struct request_queue *, struct request *); | 111 | extern void elv_requeue_request(struct request_queue *, struct request *); |
114 | extern int elv_queue_empty(struct request_queue *); | ||
115 | extern struct request *elv_former_request(struct request_queue *, struct request *); | 112 | extern struct request *elv_former_request(struct request_queue *, struct request *); |
116 | extern struct request *elv_latter_request(struct request_queue *, struct request *); | 113 | extern struct request *elv_latter_request(struct request_queue *, struct request *); |
117 | extern int elv_register_queue(struct request_queue *q); | 114 | extern int elv_register_queue(struct request_queue *q); |
@@ -167,6 +164,8 @@ extern struct request *elv_rb_find(struct rb_root *, sector_t); | |||
167 | #define ELEVATOR_INSERT_BACK 2 | 164 | #define ELEVATOR_INSERT_BACK 2 |
168 | #define ELEVATOR_INSERT_SORT 3 | 165 | #define ELEVATOR_INSERT_SORT 3 |
169 | #define ELEVATOR_INSERT_REQUEUE 4 | 166 | #define ELEVATOR_INSERT_REQUEUE 4 |
167 | #define ELEVATOR_INSERT_FLUSH 5 | ||
168 | #define ELEVATOR_INSERT_SORT_MERGE 6 | ||
170 | 169 | ||
171 | /* | 170 | /* |
172 | * return values from elevator_may_queue_fn | 171 | * return values from elevator_may_queue_fn |
@@ -195,15 +194,9 @@ enum { | |||
195 | /* | 194 | /* |
196 | * io context count accounting | 195 | * io context count accounting |
197 | */ | 196 | */ |
198 | #define elv_ioc_count_mod(name, __val) \ | 197 | #define elv_ioc_count_mod(name, __val) this_cpu_add(name, __val) |
199 | do { \ | 198 | #define elv_ioc_count_inc(name) this_cpu_inc(name) |
200 | preempt_disable(); \ | 199 | #define elv_ioc_count_dec(name) this_cpu_dec(name) |
201 | __get_cpu_var(name) += (__val); \ | ||
202 | preempt_enable(); \ | ||
203 | } while (0) | ||
204 | |||
205 | #define elv_ioc_count_inc(name) elv_ioc_count_mod(name, 1) | ||
206 | #define elv_ioc_count_dec(name) elv_ioc_count_mod(name, -1) | ||
207 | 200 | ||
208 | #define elv_ioc_count_read(name) \ | 201 | #define elv_ioc_count_read(name) \ |
209 | ({ \ | 202 | ({ \ |