aboutsummaryrefslogtreecommitdiff
path: root/core/test
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2015-09-10 10:08:56 +1000
committerStewart Smith <stewart@linux.vnet.ibm.com>2015-09-11 16:32:37 +1000
commitb5f05ac337b3495cf506f5492fd053e90ae0bda3 (patch)
tree13430c290a130c3f777736abec56173f987416b2 /core/test
parentebf9084d8a4d2f70e4e7d2c6a35cac2c7f6e2681 (diff)
downloadskiboot-b5f05ac337b3495cf506f5492fd053e90ae0bda3.zip
skiboot-b5f05ac337b3495cf506f5492fd053e90ae0bda3.tar.gz
skiboot-b5f05ac337b3495cf506f5492fd053e90ae0bda3.tar.bz2
timer: Pass current timer to timer callbacks
The caller usually has it and it avoids additional mftb() which can be expensive. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> [stewart@linux.vnet.ibm.com: fix run-timer unit test] Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'core/test')
-rw-r--r--core/test/run-timer.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/test/run-timer.c b/core/test/run-timer.c
index 8452ee0..13b175e 100644
--- a/core/test/run-timer.c
+++ b/core/test/run-timer.c
@@ -31,9 +31,10 @@ static void init_rand(void)
}
}
-static void expiry(struct timer *t, void *data)
+static void expiry(struct timer *t, void *data, uint64_t now)
{
(void)data;
+ (void)now;
assert(t->target >= last);
count--;
}