summaryrefslogtreecommitdiff
path: root/btt/inlines.h
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2006-12-01 10:51:31 +0100
committerJens Axboe <jens.axboe@oracle.com>2006-12-01 10:51:31 +0100
commit001b263355c68e219fb64d25564c41a0ee07a274 (patch)
tree635e6489da1f8d58492ac25fa642083ae6386233 /btt/inlines.h
parent095181f283c440c7669f2c14aef5e84c80ff433e (diff)
downloadblktrace-001b263355c68e219fb64d25564c41a0ee07a274.tar.gz
blktrace-001b263355c68e219fb64d25564c41a0ee07a274.tar.bz2
[PATCH] BTT patch: (3/3) time bounded trace analysis
Added in -t and -T options to allow bounding of traces analyzed. Be forewarned: this can result in some excessive numbers of orphaned traces (partial IO streams before the -t tiem and after the -T time won't be analyzed). Signed-off-by: Alan D. Brunelle <Alan.Brunelle@hp.com> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'btt/inlines.h')
-rw-r--r--btt/inlines.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/btt/inlines.h b/btt/inlines.h
index 4a763b5..cfc7160 100644
--- a/btt/inlines.h
+++ b/btt/inlines.h
@@ -259,12 +259,18 @@ static inline void __unlink(struct io *down_iop, struct io *up_iop)
static inline void add_retry(struct io *iop)
{
- list_add_tail(&iop->retry, &retries);
+ if (!iop->on_retry_list) {
+ list_add_tail(&iop->retry, &retries);
+ iop->on_retry_list = 1;
+ }
}
static inline void del_retry(struct io *iop)
{
- LIST_DEL(&iop->retry);
+ if (iop->on_retry_list) {
+ LIST_DEL(&iop->retry);
+ iop->on_retry_list = 0;
+ }
}
static inline __u64 tdelta(struct io *iop1, struct io *iop2)