diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2007-10-12 21:27:47 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2007-10-12 21:27:47 -0400 |
commit | b981d8b3f5e008ff10d993be633ad00564fc22cd (patch) | |
tree | e292dc07b22308912cf6a58354a608b9e5e8e1fd /include/linux/blktrace_api.h | |
parent | b11d2127c4893a7315d1e16273bc8560049fa3ca (diff) | |
parent | 2b9e0aae1d50e880c58d46788e5e3ebd89d75d62 (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts:
drivers/macintosh/adbhid.c
Diffstat (limited to 'include/linux/blktrace_api.h')
-rw-r--r-- | include/linux/blktrace_api.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/include/linux/blktrace_api.h b/include/linux/blktrace_api.h index 3680ff9a30ed..7e11d23ac36a 100644 --- a/include/linux/blktrace_api.h +++ b/include/linux/blktrace_api.h | |||
@@ -105,7 +105,7 @@ struct blk_io_trace { | |||
105 | */ | 105 | */ |
106 | struct blk_io_trace_remap { | 106 | struct blk_io_trace_remap { |
107 | __be32 device; | 107 | __be32 device; |
108 | u32 __pad; | 108 | __be32 device_from; |
109 | __be64 sector; | 109 | __be64 sector; |
110 | }; | 110 | }; |
111 | 111 | ||
@@ -142,10 +142,14 @@ struct blk_user_trace_setup { | |||
142 | u32 pid; | 142 | u32 pid; |
143 | }; | 143 | }; |
144 | 144 | ||
145 | #ifdef __KERNEL__ | ||
145 | #if defined(CONFIG_BLK_DEV_IO_TRACE) | 146 | #if defined(CONFIG_BLK_DEV_IO_TRACE) |
146 | extern int blk_trace_ioctl(struct block_device *, unsigned, char __user *); | 147 | extern int blk_trace_ioctl(struct block_device *, unsigned, char __user *); |
147 | extern void blk_trace_shutdown(request_queue_t *); | 148 | extern void blk_trace_shutdown(struct request_queue *); |
148 | extern void __blk_add_trace(struct blk_trace *, sector_t, int, int, u32, int, int, void *); | 149 | extern void __blk_add_trace(struct blk_trace *, sector_t, int, int, u32, int, int, void *); |
150 | extern int do_blk_trace_setup(struct request_queue *q, | ||
151 | struct block_device *bdev, struct blk_user_trace_setup *buts); | ||
152 | |||
149 | 153 | ||
150 | /** | 154 | /** |
151 | * blk_add_trace_rq - Add a trace for a request oriented action | 155 | * blk_add_trace_rq - Add a trace for a request oriented action |
@@ -272,6 +276,7 @@ static inline void blk_add_trace_remap(struct request_queue *q, struct bio *bio, | |||
272 | return; | 276 | return; |
273 | 277 | ||
274 | r.device = cpu_to_be32(dev); | 278 | r.device = cpu_to_be32(dev); |
279 | r.device_from = cpu_to_be32(bio->bi_bdev->bd_dev); | ||
275 | r.sector = cpu_to_be64(to); | 280 | r.sector = cpu_to_be64(to); |
276 | 281 | ||
277 | __blk_add_trace(bt, from, bio->bi_size, bio->bi_rw, BLK_TA_REMAP, !bio_flagged(bio, BIO_UPTODATE), sizeof(r), &r); | 282 | __blk_add_trace(bt, from, bio->bi_size, bio->bi_rw, BLK_TA_REMAP, !bio_flagged(bio, BIO_UPTODATE), sizeof(r), &r); |
@@ -285,6 +290,7 @@ static inline void blk_add_trace_remap(struct request_queue *q, struct bio *bio, | |||
285 | #define blk_add_trace_generic(q, rq, rw, what) do { } while (0) | 290 | #define blk_add_trace_generic(q, rq, rw, what) do { } while (0) |
286 | #define blk_add_trace_pdu_int(q, what, bio, pdu) do { } while (0) | 291 | #define blk_add_trace_pdu_int(q, what, bio, pdu) do { } while (0) |
287 | #define blk_add_trace_remap(q, bio, dev, f, t) do {} while (0) | 292 | #define blk_add_trace_remap(q, bio, dev, f, t) do {} while (0) |
293 | #define do_blk_trace_setup(q, bdev, buts) (-ENOTTY) | ||
288 | #endif /* CONFIG_BLK_DEV_IO_TRACE */ | 294 | #endif /* CONFIG_BLK_DEV_IO_TRACE */ |
289 | 295 | #endif /* __KERNEL__ */ | |
290 | #endif | 296 | #endif |