Module: xenomai-forge
Branch: master
Commit: 72540c8d1fcf5d014f012e9877c4b77ea0e5af9e
URL:    
http://git.xenomai.org/?p=xenomai-forge.git;a=commit;h=72540c8d1fcf5d014f012e9877c4b77ea0e5af9e

Author: Philippe Gerum <r...@xenomai.org>
Date:   Sat Nov 26 12:25:36 2011 +0100

copperplate/clockobj: fix build with disabled lores clock

---

 include/copperplate/clockobj.h |    1 +
 lib/copperplate/clockobj.c     |    4 ++++
 2 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/include/copperplate/clockobj.h b/include/copperplate/clockobj.h
index 85f3796..287eed6 100644
--- a/include/copperplate/clockobj.h
+++ b/include/copperplate/clockobj.h
@@ -22,6 +22,7 @@
 #include <pthread.h>
 #include <time.h>
 #include <xeno_config.h>
+#include <copperplate/init.h>
 #include <copperplate/list.h>
 #include <copperplate/debug.h>
 #include <copperplate/lock.h>
diff --git a/lib/copperplate/clockobj.c b/lib/copperplate/clockobj.c
index 5d27654..f7410b5 100644
--- a/lib/copperplate/clockobj.c
+++ b/lib/copperplate/clockobj.c
@@ -251,12 +251,16 @@ int clockobj_set_resolution(struct clockobj *clkobj, 
unsigned int resolution_ns)
 
 #include <asm/xenomai/arith.h>
 
+#ifndef CONFIG_XENO_LORES_CLOCK_DISABLED
+
 sticks_t clockobj_ns_to_ticks(struct clockobj *clkobj, sticks_t ns)
 {
        /* Cobalt has optimized arith ops, use them. */
        return xnarch_ulldiv(ns, clkobj->resolution, NULL);
 }
 
+#endif /* !CONFIG_XENO_LORES_CLOCK_DISABLED */
+
 void clockobj_get_time(struct clockobj *clkobj,
                       ticks_t *pticks, ticks_t *ptsc)
 {


_______________________________________________
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git

Reply via email to