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

Author: Philippe Gerum <r...@xenomai.org>
Date:   Tue Apr 15 17:44:31 2014 +0200

cobalt/synch: drop typedefs for non-opaque aggregates

---

 include/cobalt/kernel/rtdm/driver.h |    8 ++++----
 include/cobalt/kernel/select.h      |    2 +-
 include/cobalt/kernel/synch.h       |    4 ++--
 kernel/cobalt/posix/mutex.h         |    2 +-
 kernel/cobalt/rtdm/drvlib.c         |    2 +-
 kernel/cobalt/thread.c              |    4 ++--
 6 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/include/cobalt/kernel/rtdm/driver.h 
b/include/cobalt/kernel/rtdm/driver.h
index 47e59b2..dc8f2f3 100644
--- a/include/cobalt/kernel/rtdm/driver.h
+++ b/include/cobalt/kernel/rtdm/driver.h
@@ -1165,7 +1165,7 @@ void rtdm_toseq_init(rtdm_toseq_t *timeout_seq, 
nanosecs_rel_t timeout);
 /* --- event services --- */
 
 typedef struct {
-       xnsynch_t synch_base;
+       struct xnsynch synch_base;
        DECLARE_XNSELECT(select_block);
 } rtdm_event_t;
 
@@ -1182,7 +1182,7 @@ void rtdm_event_signal(rtdm_event_t *event);
 void rtdm_event_clear(rtdm_event_t *event);
 
 #ifndef DOXYGEN_CPP /* Avoid static inline tags for RTDM in doxygen */
-void __rtdm_synch_flush(xnsynch_t *synch, unsigned long reason);
+void __rtdm_synch_flush(struct xnsynch *synch, unsigned long reason);
 
 static inline void rtdm_event_pulse(rtdm_event_t *event)
 {
@@ -1202,7 +1202,7 @@ static inline void rtdm_event_destroy(rtdm_event_t *event)
 
 typedef struct {
        unsigned long value;
-       xnsynch_t synch_base;
+       struct xnsynch synch_base;
        DECLARE_XNSELECT(select_block);
 } rtdm_sem_t;
 
@@ -1226,7 +1226,7 @@ static inline void rtdm_sem_destroy(rtdm_sem_t *sem)
 /* --- mutex services --- */
 
 typedef struct {
-       xnsynch_t synch_base;
+       struct xnsynch synch_base;
 } rtdm_mutex_t;
 
 void rtdm_mutex_init(rtdm_mutex_t *mutex);
diff --git a/include/cobalt/kernel/select.h b/include/cobalt/kernel/select.h
index 20398f4..e10de38 100644
--- a/include/cobalt/kernel/select.h
+++ b/include/cobalt/kernel/select.h
@@ -37,7 +37,7 @@
 #define XNSELECT_MAX_TYPES 3
 
 struct xnselector {
-       xnsynch_t synchbase;
+       struct xnsynch synchbase;
        struct fds {
                fd_set expected;
                fd_set pending;
diff --git a/include/cobalt/kernel/synch.h b/include/cobalt/kernel/synch.h
index 181e053..78f3402 100644
--- a/include/cobalt/kernel/synch.h
+++ b/include/cobalt/kernel/synch.h
@@ -49,7 +49,7 @@
 struct xnthread;
 struct xnsynch;
 
-typedef struct xnsynch {
+struct xnsynch {
        struct list_head link;  /** thread->claimq */
        int wprio;              /** wait prio in claimq */
        unsigned long status;    /** Status word */
@@ -57,7 +57,7 @@ typedef struct xnsynch {
        struct xnthread *owner; /** Thread which owns the resource */
        atomic_long_t *fastlock; /** Pointer to fast lock word */
        void (*cleanup)(struct xnsynch *synch); /* Cleanup handler */
-} xnsynch_t;
+};
 
 static inline void xnsynch_set_status(struct xnsynch *synch, int bits)
 {
diff --git a/kernel/cobalt/posix/mutex.h b/kernel/cobalt/posix/mutex.h
index 0fc29e6..d3579ce 100644
--- a/kernel/cobalt/posix/mutex.h
+++ b/kernel/cobalt/posix/mutex.h
@@ -26,7 +26,7 @@ typedef struct cobalt_mutexattr pthread_mutexattr_t;
 
 struct cobalt_mutex {
        unsigned int magic;
-       xnsynch_t synchbase;
+       struct xnsynch synchbase;
        /** cobalt_mutexq */
        struct list_head link;
        struct list_head conds;
diff --git a/kernel/cobalt/rtdm/drvlib.c b/kernel/cobalt/rtdm/drvlib.c
index a89decc..0ac47dd 100644
--- a/kernel/cobalt/rtdm/drvlib.c
+++ b/kernel/cobalt/rtdm/drvlib.c
@@ -659,7 +659,7 @@ void rtdm_timer_stop_in_handler(rtdm_timer_t *timer);
 
 #define RTDM_SYNCH_DELETED          XNSYNCH_SPARE0
 
-void __rtdm_synch_flush(xnsynch_t *synch, unsigned long reason)
+void __rtdm_synch_flush(struct xnsynch *synch, unsigned long reason)
 {
        spl_t s;
 
diff --git a/kernel/cobalt/thread.c b/kernel/cobalt/thread.c
index 2182f6e..e2152ba 100644
--- a/kernel/cobalt/thread.c
+++ b/kernel/cobalt/thread.c
@@ -735,7 +735,7 @@ int xnthread_set_mode(xnthread_t *thread, int clrmask, int 
setmask)
 EXPORT_SYMBOL_GPL(xnthread_set_mode);
 
 /**
- * @fn void xnthread_suspend(xnthread_t *thread, int mask,xnticks_t timeout, 
xntmode_t timeout_mode,xnsynch_t *wchan)
+ * @fn void xnthread_suspend(xnthread_t *thread, int mask,xnticks_t timeout, 
xntmode_t timeout_mode,struct xnsynch *wchan)
  * @brief Suspend a thread.
  *
  * Suspends the execution of a thread according to a given suspensive
@@ -794,7 +794,7 @@ EXPORT_SYMBOL_GPL(xnthread_set_mode);
  */
 void xnthread_suspend(xnthread_t *thread, int mask,
                      xnticks_t timeout, xntmode_t timeout_mode,
-                     xnsynch_t *wchan)
+                     struct xnsynch *wchan)
 {
        unsigned long oldstate;
        struct xnsched *sched;


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

Reply via email to