[Xenomai-git] Philippe Gerum : cobalt/clock: add helper to change resolution
Module: xenomai-3 Branch: next Commit: 92801bec0d00637575806fd034c3a91b1cb80d5e URL: http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=92801bec0d00637575806fd034c3a91b1cb80d5e Author: Philippe Gerum Date: Mon Feb 1 21:11:09 2016 +0100 cobalt/clock: add helper to change resolution --- include/cobalt/kernel/clock.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/include/cobalt/kernel/clock.h b/include/cobalt/kernel/clock.h index 6ad8719..c290b1d 100644 --- a/include/cobalt/kernel/clock.h +++ b/include/cobalt/kernel/clock.h @@ -273,6 +273,12 @@ static inline xnticks_t xnclock_get_resolution(struct xnclock *clock) return clock->resolution; /* ns */ } +static inline void xnclock_set_resolution(struct xnclock *clock, + xnticks_t resolution) +{ + clock->resolution = resolution; /* ns */ +} + static inline int xnclock_set_gravity(struct xnclock *clock, const struct xnclock_gravity *gravity) { ___ Xenomai-git mailing list Xenomai-git@xenomai.org http://xenomai.org/mailman/listinfo/xenomai-git
[Xenomai-git] Philippe Gerum : cobalt/clock: add helper to change resolution
Module: xenomai-3 Branch: stable-3.0.x Commit: 61227a98c8a8178a41cad08a6d098c5f9d7338d5 URL: http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=61227a98c8a8178a41cad08a6d098c5f9d7338d5 Author: Philippe Gerum Date: Mon Feb 1 21:11:09 2016 +0100 cobalt/clock: add helper to change resolution --- include/cobalt/kernel/clock.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/include/cobalt/kernel/clock.h b/include/cobalt/kernel/clock.h index 6ad8719..c290b1d 100644 --- a/include/cobalt/kernel/clock.h +++ b/include/cobalt/kernel/clock.h @@ -273,6 +273,12 @@ static inline xnticks_t xnclock_get_resolution(struct xnclock *clock) return clock->resolution; /* ns */ } +static inline void xnclock_set_resolution(struct xnclock *clock, + xnticks_t resolution) +{ + clock->resolution = resolution; /* ns */ +} + static inline int xnclock_set_gravity(struct xnclock *clock, const struct xnclock_gravity *gravity) { ___ Xenomai-git mailing list Xenomai-git@xenomai.org http://xenomai.org/mailman/listinfo/xenomai-git