Module: xenomai-3
Branch: next
Commit: 979fe3106754daa45d32d5c922a46fe37a182a43
URL:    
http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=979fe3106754daa45d32d5c922a46fe37a182a43

Author: Philippe Gerum <r...@xenomai.org>
Date:   Fri Jul 31 17:41:41 2015 +0200

lib/cobalt: export cobalt_thread_mode()

---

 config/apirev               |    2 +-
 include/cobalt/sys/cobalt.h |    2 ++
 lib/cobalt/internal.c       |    5 +++++
 3 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/config/apirev b/config/apirev
index b1bd38b..8351c19 100644
--- a/config/apirev
+++ b/config/apirev
@@ -1 +1 @@
-13
+14
diff --git a/include/cobalt/sys/cobalt.h b/include/cobalt/sys/cobalt.h
index e80800b..e7c58d7 100644
--- a/include/cobalt/sys/cobalt.h
+++ b/include/cobalt/sys/cobalt.h
@@ -70,6 +70,8 @@ int cobalt_thread_join(pthread_t thread);
 
 pid_t cobalt_thread_pid(pthread_t thread);
 
+int cobalt_thread_mode(void);
+  
 int cobalt_monitor_init(cobalt_monitor_t *mon,
                        clockid_t clk_id, int flags);
 
diff --git a/lib/cobalt/internal.c b/lib/cobalt/internal.c
index 09cce81..348ca14 100644
--- a/lib/cobalt/internal.c
+++ b/lib/cobalt/internal.c
@@ -70,6 +70,11 @@ pid_t cobalt_thread_pid(pthread_t thread)
        return XENOMAI_SYSCALL1(sc_cobalt_thread_getpid, thread);
 }
 
+int cobalt_thread_mode(void)
+{
+       return cobalt_get_current_mode();
+}
+
 int cobalt_thread_join(pthread_t thread)
 {
        int ret, oldtype;


_______________________________________________
Xenomai-git mailing list
Xenomai-git@xenomai.org
http://xenomai.org/mailman/listinfo/xenomai-git

Reply via email to