Skip to contentSkip to conversation

xenomai-forge PSOS: miscellaneous fixes

PATCH In review Thomas De Schampheleire 2 participants 22 messages Oct 19, 2011 – Oct 26, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 xenomai-forge PSOS: miscellaneous fixes

This patch series includes some misc. fixes to xenomai-forge:

* definition of ERR_OBJTFULL (should also be added to Xenomai proper)
* port long_names feature to xenomai-forge and fix it
* add tm_getm() function (not present in pSOS but present in Xenomai proper)
* fix compiler warning in task.c

---
 include/psos/Makefile.am  |   2 +-
 include/psos/Makefile.in  |   2 +-
 include/psos/long_names.h |  14 ++++++++++++++
 include/psos/psos.h       |   5 +++++
 lib/psos/init.c           |  15 +++++++++++++++
 lib/psos/pt.c             |   6 ++++++
 lib/psos/queue.c          |   6 ++++++
 lib/psos/rn.c             |   5 +++++
 lib/psos/sem.c            |   6 ++++++
 lib/psos/task.c           |   9 +++++++--
 lib/psos/tm.c             |   7 +++++++
 11 files changed, 73 insertions(+), 4 deletions(-)
#7 lore raw

PATCH 1/1 psos: port long_names feature to xenomai-forge

In reply to Thomas De Schampheleire

While psos interface accepts 4 character ids, non null terminated, xenomai uses longer ids which must be null terminated. Revert to the behaviour of psos interface, while allowing long id strings if the global variable psos_long_names is set to non-zero.

This patch ports the original fix from xenomai to xenomai-forge, fixing following problems:
* a bug in __psos_maybe_short_name so that only 3 characters are retained
* the call to __psos_maybe_short_name also needs to be done in the ident functions
* the pt_create and pt_ident functions also need to be adapted

---
 include/psos/Makefile.am  |   2 +-
 include/psos/Makefile.in  |   2 +-
 include/psos/long_names.h |  14 ++++++++++++++
 include/psos/psos.h       |   2 ++
 lib/psos/init.c           |  15 +++++++++++++++
 lib/psos/pt.c             |   6 ++++++
 lib/psos/queue.c          |   6 ++++++
 lib/psos/rn.c             |   5 +++++
 lib/psos/sem.c            |   6 ++++++
 lib/psos/task.c           |   5 +++++
 10 files changed, 61 insertions(+), 2 deletions(-)
include/psos/Makefile.am +1 -1
@@ -1,3 +1,3 @@
 includesubdir = $(includedir)/psos
 
-includesub_HEADERS = psos.h
+includesub_HEADERS = psos.h long_names.h
include/psos/Makefile.in +1 -1
@@ -238,7 +238,7 @@ top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 includesubdir = $(includedir)/psos
-includesub_HEADERS = psos.h
+includesub_HEADERS = psos.h long_names.h
 all: all-am
 
 .SUFFIXES:
include/psos/long_names.h new file +14 -0
new file mode 100644
@@ -0,0 +1,14 @@
+#ifndef LONG_NAMES_H
+#define LONG_NAMES_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
+
+const char *__psos_maybe_short_name(char shrt[5], const char *lng);
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+#endif /* LONG_NAMES_H */
include/psos/psos.h +2 -0
@@ -371,6 +371,8 @@ u_long tm_wkwhen(u_long date,
 
 int psos_task_normalize_priority(unsigned long psos_prio);
 
+extern unsigned psos_long_names;
+
 #ifdef __cplusplus
 };
 #endif /* __cplusplus */
lib/psos/init.c +15 -0
@@ -17,6 +17,7 @@
  */
 
 #include <stdio.h>
+#include <string.h>
 #include <time.h>
 #include <stdlib.h>
 #include <unistd.h>
@@ -27,6 +28,7 @@
 #include <copperplate/clockobj.h>
 #include <copperplate/debug.h>
 #include <psos/psos.h>
+#include <psos/long_names.h>
 #include "tm.h"
 #include "task.h"
 #include "sem.h"
@@ -34,6 +36,8 @@
 #include "pt.h"
 #include "rn.h"
 
+unsigned psos_long_names;
+
 static unsigned int clock_resolution = 1000000; /* 1ms */
 
 static const struct option psos_options[] = {
@@ -105,3 +109,14 @@ static __attribute__ ((constructor)) voi
 {
 	copperplate_register_skin(&psos_skin);
 }
+
+const char *__psos_maybe_short_name(char shrt[5], const char *lng)
+{
+	if (psos_long_names)
+		return lng;
+
+	strncpy(shrt, lng, 5 - 1);
+	shrt[4] = '\0';
+
+	return (const char *)shrt;
+}
lib/psos/pt.c +6 -0
@@ -26,6 +26,7 @@
 #include <copperplate/cluster.h>
 #include <copperplate/lock.h>
 #include <psos/psos.h>
+#include <psos/long_names.h>
 #include "pt.h"
 
 #define pt_magic	0x8181fefe
@@ -127,6 +128,7 @@ u_long pt_create(const char *name,
 	u_long overhead;
 	caddr_t mp;
 	u_long n;
+	char short_name[5];
 
 	if ((uintptr_t)paddr & (sizeof(uintptr_t) - 1))
 		return ERR_PTADDR;
@@ -145,6 +147,7 @@ u_long pt_create(const char *name,
 	if (name == NULL || *name == '\0')
 		sprintf(pt->name, "pt%lu", ++anon_ptids);
 	else {
+		name = __psos_maybe_short_name(short_name, name);
 		strncpy(pt->name, name, sizeof(pt->name));
 		pt->name[sizeof(pt->name) - 1] = '\0';
 	}
@@ -289,10 +292,13 @@ u_long pt_ident(const char *name, u_long
 	struct pvclusterobj *cobj;
 	struct service svc;
 	struct psos_pt *pt;
+	char short_name[5];
 
 	if (node)
 		return ERR_NODENO;
 
+	name = __psos_maybe_short_name(short_name, name);
+
 	COPPERPLATE_PROTECT(svc);
 	cobj = pvcluster_findobj(&psos_pt_table, name);
 	COPPERPLATE_UNPROTECT(svc);
lib/psos/queue.c +6 -0
@@ -28,6 +28,7 @@
 #include <copperplate/panic.h>
 #include <copperplate/cluster.h>
 #include <psos/psos.h>
+#include <psos/long_names.h>
 #include "reference.h"
 #include "task.h"
 #include "queue.h"
@@ -85,6 +86,7 @@ static u_long __q_create(const char *nam
 	struct service svc;
 	int sobj_flags = 0;
 	int ret = SUCCESS;
+	char short_name[5];
 
 	COPPERPLATE_PROTECT(svc);
 
@@ -97,6 +99,7 @@ static u_long __q_create(const char *nam
 	if (name == NULL || *name == '\0')
 		sprintf(q->name, "q%lu", ++anon_qids);
 	else {
+		name = __psos_maybe_short_name(short_name, name);
 		strncpy(q->name, name, sizeof(q->name));
 		q->name[sizeof(q->name) - 1] = '\0';
 	}
@@ -197,10 +200,13 @@ static u_long __q_ident(const char *name
 	struct clusterobj *cobj;
 	struct psos_queue *q;
 	struct service svc;
+	char short_name[5];
 
 	if (node)
 		return ERR_NODENO;
 
+	name = __psos_maybe_short_name(short_name, name);
+
 	COPPERPLATE_PROTECT(svc);
 	cobj = cluster_findobj(&psos_queue_table, name);
 	COPPERPLATE_UNPROTECT(svc);
lib/psos/rn.c +5 -0
@@ -26,6 +26,7 @@
 #include <copperplate/threadobj.h>
 #include <copperplate/clockobj.h>
 #include <psos/psos.h>
+#include <psos/long_names.h>
 #include "tm.h"
 #include "rn.h"
 
@@ -68,6 +69,7 @@ u_long rn_create(const char *name, void 
 	int sobj_flags = 0, ret = SUCCESS;
 	struct psos_rn *rn;
 	struct service svc;
+	char short_name[5];
 
 	if ((uintptr_t)saddr & (sizeof(uintptr_t) - 1))
 		return ERR_RNADDR;
@@ -113,6 +115,7 @@ u_long rn_create(const char *name, void 
 	if (name == NULL || *name == '\0')
 		sprintf(rn->name, "rn%lu", ++anon_rnids);
 	else {
+		name = __psos_maybe_short_name(short_name, name);
 		strncpy(rn->name, name, sizeof(rn->name));
 		rn->name[sizeof(rn->name) - 1] = '\0';
 	}
@@ -190,6 +193,8 @@ u_long rn_ident(const char *name, u_long
 	struct pvclusterobj *cobj;
 	struct psos_rn *rn;
 	struct service svc;
+	char short_name[5];
+	name = __psos_maybe_short_name(short_name, name);
 
 	COPPERPLATE_PROTECT(svc);
 	cobj = pvcluster_findobj(&psos_rn_table, name);
lib/psos/sem.c +6 -0
@@ -30,6 +30,7 @@
 #include "sem.h"
 #include "tm.h"
 #include <psos/psos.h>
+#include <psos/long_names.h>
 
 #define sem_magic	0x8181fbfb
 
@@ -77,6 +78,7 @@ u_long sm_create(const char *name,
 	struct service svc;
 	int sobj_flags = 0;
 	int ret = SUCCESS;
+	char short_name[5];
 
 	COPPERPLATE_PROTECT(svc);
 
@@ -89,6 +91,7 @@ u_long sm_create(const char *name,
 	if (name == NULL || *name == '\0')
 		sprintf(sem->name, "sm%lu", ++anon_smids);
 	else {
+		name = __psos_maybe_short_name(short_name, name);
 		strncpy(sem->name, name, sizeof(sem->name));
 		sem->name[sizeof(sem->name) - 1] = '\0';
 	}
@@ -148,10 +151,13 @@ u_long sm_ident(const char *name, u_long
 	struct clusterobj *cobj;
 	struct psos_sem *sem;
 	struct service svc;
+	char short_name[5];
 
 	if (node)
 		return ERR_NODENO;
 
+	name = __psos_maybe_short_name(short_name, name);
+
 	COPPERPLATE_PROTECT(svc);
 	cobj = cluster_findobj(&psos_sem_table, name);
 	COPPERPLATE_UNPROTECT(svc);
lib/psos/task.c +5 -0
@@ -33,6 +33,7 @@
 #include <copperplate/clockobj.h>
 #include <copperplate/cluster.h>
 #include <psos/psos.h>
+#include <psos/long_names.h>
 #include "task.h"
 #include "tm.h"
 
@@ -247,6 +248,7 @@ u_long t_create(const char *name, u_long
 	struct syncstate syns;
 	struct service svc;
 	int ret, cprio;
+	char short_name[5];
 
 	ret = check_task_priority(prio, &cprio);
 	if (ret)
@@ -276,6 +278,7 @@ u_long t_create(const char *name, u_long
 	if (name == NULL || *name == '\0')
 		sprintf(task->name, "t%lu", ++anon_tids);
 	else {
+		name = __psos_maybe_short_name(short_name, name);
 		strncpy(task->name, name, sizeof(task->name));
 		task->name[sizeof(task->name) - 1] = '\0';
 	}
@@ -460,6 +463,7 @@ u_long t_ident(const char *name, u_long 
 	struct psos_task *task;
 	struct service svc;
 	int ret = SUCCESS;
+	char short_name[5];
 
 	if (node)
 		return ERR_NODENO;
@@ -471,6 +475,7 @@ u_long t_ident(const char *name, u_long 
 		if (task == NULL)
 			goto out;
 	} else {
+		name = __psos_maybe_short_name(short_name, name);
 		cobj = cluster_findobj(&psos_task_table, name);
 		if (cobj == NULL) {
 			ret = ERR_OBJNF;
#11 lore raw

PATCH 1/1 psos: add tm_getm function

In reply to Thomas De Schampheleire
---
 include/psos/psos.h |  2 ++
 lib/psos/tm.c       |  7 +++++++
 2 files changed, 9 insertions(+), 0 deletions(-)
include/psos/psos.h +2 -0
@@ -363,6 +363,8 @@ u_long tm_set(u_long date,
 	      u_long time,
 	      u_long ticks);
 
+u_long tm_getm(unsigned long long *ns);
+
 u_long tm_wkafter(u_long ticks);
 
 u_long tm_wkwhen(u_long date,
lib/psos/tm.c +7 -0
@@ -309,3 +309,10 @@ u_long tm_get(u_long *date_r, u_long *ti
 
 	return SUCCESS;
 }
+
+u_long tm_getm(unsigned long long *ns_r)
+{
+	*ns_r = clockobj_get_tsc();
+	return SUCCESS;
+}
+
#14 lore raw

PATCH 1/1 psos: fix compiler warning: cprio could be used uninitialized

In reply to Thomas De Schampheleire

Assign default 1 to satisfy compiler (tested with gcc 4.4.3)

---
 lib/psos/task.c |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
lib/psos/task.c +2 -2
@@ -247,7 +247,7 @@ u_long t_create(const char *name, u_long
 	pthread_attr_t thattr;
 	struct syncstate syns;
 	struct service svc;
-	int ret, cprio;
+	int ret, cprio = 1;
 	char short_name[5];
 
 	ret = check_task_priority(prio, &cprio);
@@ -414,7 +414,7 @@ u_long t_resume(u_long tid)
 u_long t_setpri(u_long tid, u_long newprio, u_long *oldprio_r)
 {
 	struct psos_task *task;
-	int ret, cprio;
+	int ret, cprio = 1;
 
 	task = get_psos_task_or_self(tid, &ret);
 	if (task == NULL)
#19 lore raw
In reply to Thomas De Schampheleire

Hi,

Quoted 22 lines · Thomas De Schampheleire

This patch series includes some misc. fixes to xenomai-forge:

* definition of ERR_OBJTFULL (should also be added to Xenomai proper)
* port long_names feature to xenomai-forge and fix it
* add tm_getm() function (not present in pSOS but present in Xenomai proper)
* fix compiler warning in task.c

---
 include/psos/Makefile.am  |   2 +-
 include/psos/Makefile.in  |   2 +-
 include/psos/long_names.h |  14 ++++++++++++++
 include/psos/psos.h       |   5 +++++
 lib/psos/init.c           |  15 +++++++++++++++
 lib/psos/pt.c             |   6 ++++++
 lib/psos/queue.c          |   6 ++++++
 lib/psos/rn.c             |   5 +++++
 lib/psos/sem.c            |   6 ++++++
 lib/psos/task.c           |   9 +++++++--
 lib/psos/tm.c             |   7 +++++++

Quoted 4 lines
 11 files changed, 73 insertions(+), 4 deletions(-)

Do you have any comments on this patch series?

Thanks,
Thomas

#2 lore raw

Re: [Xenomai-help] [PATCH 1 of 4] psos.h: add definition of ERR_OBJTFULL

In reply to Thomas De Schampheleire
Quoted 11 lines · Thomas De Schampheleire
---
  include/psos/psos.h |  1 +
  1 files changed, 1 insertions(+), 0 deletions(-)

include/psos/psos.h line 103

Quoted 7 lines
include/psos/psos.h +1 -0
@@ -97,6 +97,7 @@
  #define ERR_OBJDEL   0x05
  #define ERR_OBJID    0x06
  #define ERR_OBJTYPE  0x07
+#define ERR_OBJTFULL 0x08
  #define ERR_OBJNF    0x09
 
  #define ERR_NOTCB    0x0E

Where is this error code used in the Xenomai tree? Can't find it right now.

Signature · 1 line
Philippe.
#8 lore raw

Re: [Xenomai-help] [PATCH 2 of 4] psos: port long_names feature to xenomai-forge

In reply to Thomas De Schampheleire
Quoted 5 lines · Thomas De Schampheleire

While psos interface accepts 4 character ids, non null terminated, xenomai uses longer ids which must be null terminated. Revert to the behaviour of psos interface, while allowing long id strings if the global variable psos_long_names is set to non-zero.

Quoted 8 lines

This patch ports the original fix from xenomai to xenomai-forge, fixing following problems:
* a bug in __psos_maybe_short_name so that only 3 characters are retained
* the call to __psos_maybe_short_name also needs to be done in the ident functions
* the pt_create and pt_ident functions also need to be adapted

Please merge long_names.h into psos.h, having a separate header for this is way overkill and brings nothing.

Signature · 1 line
Philippe.
#12 lore raw

Re: [Xenomai-help] [PATCH 3 of 4] psos: add tm_getm function

In reply to Thomas De Schampheleire
Quoted 24 lines · Thomas De Schampheleire
---
  include/psos/psos.h |  2 ++
  lib/psos/tm.c       |  7 +++++++
  2 files changed, 9 insertions(+), 0 deletions(-)
include/psos/psos.h +2 -0
@@ -363,6 +363,8 @@ u_long tm_set(u_long date,
  	      u_long time,
  	      u_long ticks);
 
+u_long tm_getm(unsigned long long *ns);
+
  u_long tm_wkafter(u_long ticks);
 
  u_long tm_wkwhen(u_long date,

lib/psos/tm.c u_long tm_get(u_long *date_r, u_long *ti · line 317

Quoted 9 lines
lib/psos/tm.c +6 -0
@@ -309,3 +309,10 @@ u_long tm_get(u_long *date_r, u_long *ti
 
  	return SUCCESS;
  }
+
+u_long tm_getm(unsigned long long *ns_r)
+{
+	*ns_r = clockobj_get_tsc();
+	return SUCCESS;
+}

- *ns_r = clockobj_get_tsc();
+ *ns_r = clockobj_tsc_to_ns(clockobj_get_tsc());

Signature · 1 line
Philippe.
#15 lore raw

Re: [Xenomai-help] [PATCH 4 of 4] psos: fix compiler warning: cprio could be used uninitialized

In reply to Thomas De Schampheleire
Quoted 23 lines · Thomas De Schampheleire

Assign default 1 to satisfy compiler (tested with gcc 4.4.3)

---
  lib/psos/task.c |  4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)
lib/psos/task.c +1 -1
@@ -247,7 +247,7 @@ u_long t_create(const char *name, u_long
  	pthread_attr_t thattr;
  	struct syncstate syns;
  	struct service svc;
-	int ret, cprio;
+	int ret, cprio = 1;
  	char short_name[5];
 
  	ret = check_task_priority(prio,&cprio);

lib/psos/task.c u_long t_resume(u_long tid) · line 420

Quoted 8 lines
lib/psos/task.c +1 -1
@@ -414,7 +414,7 @@ u_long t_resume(u_long tid)
  u_long t_setpri(u_long tid, u_long newprio, u_long *oldprio_r)
  {
  	struct psos_task *task;
-	int ret, cprio;
+	int ret, cprio = 1;
 
  	task = get_psos_task_or_self(tid,&ret);
  	if (task == NULL)

Looks like 4.4.3 is wrong, 4.4.4+ does it better and does not choke. Just to make sure the optimizer is given a chance to see the truth, could you try without this patch, but with tagging check_task_priority() as inline instead, with --disable-debug, then with --enable-debug=full switches?

TIA,

Signature · 1 line
Philippe.
#3 lore raw

Re: [Xenomai-help] [PATCH 1 of 4] psos.h: add definition of ERR_OBJTFULL

In reply to Philippe Gerum

Hi,

Quoted 19 lines · Philippe Gerum
Quoted 18 lines · Thomas De Schampheleire

---
 include/psos/psos.h |  1 +

 1 files changed, 1 insertions(+), 0 deletions(-)
include/psos/psos.h +1 -0
@@ -97,6 +97,7 @@
  #define ERR_OBJDEL   0x05
  #define ERR_OBJID    0x06
  #define ERR_OBJTYPE  0x07
+#define ERR_OBJTFULL 0x08
  #define ERR_OBJNF    0x09
 
Quoted 3 lines

include/psos/psos.h line 103

Quoted 1 line
include/psos/psos.h +0 -0
  #define ERR_NOTCB    0x0E

Where is this error code used in the Xenomai tree? Can't find it right now.

It's not used in the Xenomai code itself, but it may be used by applications. The definition is absent both in Xenomai as Xenomai-forge.

~Thomas

#4 lore raw

Re: [Xenomai-help] [PATCH 1 of 4] psos.h: add definition of ERR_OBJTFULL

Quoted 22 lines · Thomas De Schampheleire

Hi,

Quoted 19 lines · Philippe Gerum
Quoted 18 lines · Thomas De Schampheleire
---
  include/psos/psos.h |  1 +
  1 files changed, 1 insertions(+), 0 deletions(-)
include/psos/psos.h +1 -0
@@ -97,6 +97,7 @@
  #define ERR_OBJDEL   0x05
  #define ERR_OBJID    0x06
  #define ERR_OBJTYPE  0x07
+#define ERR_OBJTFULL 0x08
  #define ERR_OBJNF    0x09
 
Quoted 9 lines
Quoted 3 lines

include/psos/psos.h line 103

Quoted 1 line
include/psos/psos.h +0 -0
  #define ERR_NOTCB    0x0E

Where is this error code used in the Xenomai tree? Can't find it right now.

It's not used in the Xenomai code itself, but it may be used by applications. The definition is absent both in Xenomai as Xenomai-forge.

~Thomas

Yes, the point is that so far, only the errors the Xenomai emulation does return are mentioned in this file. But we should merge this anyhow, since the original *_create() calls could throw this, so the app has to check despite Xenomai won't fail this way, right?

Signature · 1 line
Philippe.
#9 lore raw

Re: [Xenomai-help] [PATCH 2 of 4] psos: port long_names feature to xenomai-forge

In reply to Philippe Gerum
Quoted 16 lines · Philippe Gerum
Quoted 6 lines · Thomas De Schampheleire

While psos interface accepts 4 character ids, non null terminated, xenomai uses longer ids which must be null terminated. Revert to the behaviour of psos interface, while allowing long id strings if the global variable psos_long_names is set to non-zero.

Quoted 8 lines

This patch ports the original fix from xenomai to xenomai-forge, fixing following problems:
* a bug in __psos_maybe_short_name so that only 3 characters are retained
* the call to __psos_maybe_short_name also needs to be done in the ident functions
* the pt_create and pt_ident functions also need to be adapted

Quoted 2 lines

Please merge long_names.h into psos.h, having a separate header for this is way overkill and brings nothing.

It avoids exposing an internal interface to applications through psos.h. If anything, I think we should make a psos_internal.h or whatever, that can host __psos_maybe_short_name among others.

~Thomas

#13 lore raw

Re: [Xenomai-help] [PATCH 3 of 4] psos: add tm_getm function

In reply to Philippe Gerum
Quoted 27 lines · Philippe Gerum
Quoted 26 lines · Thomas De Schampheleire

---
 include/psos/psos.h |  2 ++
 lib/psos/tm.c       |  7 +++++++

 2 files changed, 9 insertions(+), 0 deletions(-)
include/psos/psos.h +2 -0
@@ -363,6 +363,8 @@ u_long tm_set(u_long date,
              u_long time,
              u_long ticks);
 
+u_long tm_getm(unsigned long long *ns);
+
  u_long tm_wkafter(u_long ticks);
 
  u_long tm_wkwhen(u_long date,
lib/psos/tm.c +0 -0
@@ -309,3 +309,10 @@ u_long tm_get(u_long *date_r, u_long *ti
 
Quoted 12 lines

lib/psos/tm.c u_long tm_get(u_long *date_r, u_long *ti · line 317

Quoted 8 lines
lib/psos/tm.c +6 -0
        return SUCCESS;
  }
+
+u_long tm_getm(unsigned long long *ns_r)
+{
+       *ns_r = clockobj_get_tsc();
+       return SUCCESS;
+}

-       *ns_r = clockobj_get_tsc();
+       *ns_r = clockobj_tsc_to_ns(clockobj_get_tsc());

Ok, thanks.

#16 lore raw

Re: [Xenomai-help] [PATCH 4 of 4] psos: fix compiler warning: cprio could be used uninitialized

In reply to Philippe Gerum
Quoted 30 lines · Philippe Gerum
Quoted 29 lines · Thomas De Schampheleire

Assign default 1 to satisfy compiler (tested with gcc 4.4.3)

---
 lib/psos/task.c |  4 ++--

 1 files changed, 2 insertions(+), 2 deletions(-)
lib/psos/task.c +2 -2
@@ -247,7 +247,7 @@ u_long t_create(const char *name, u_long
        pthread_attr_t thattr;
        struct syncstate syns;
        struct service svc;
-       int ret, cprio;
+       int ret, cprio = 1;
        char short_name[5];
 
        ret = check_task_priority(prio,&cprio);
@@ -414,7 +414,7 @@ u_long t_resume(u_long tid)
  u_long t_setpri(u_long tid, u_long newprio, u_long *oldprio_r)
  {
        struct psos_task *task;
-       int ret, cprio;
+       int ret, cprio = 1;
 
Quoted 8 lines

lib/psos/task.c u_long t_resume(u_long tid) · line 420

Quoted 3 lines
lib/psos/task.c +0 -0
        task = get_psos_task_or_self(tid,&ret);
        if (task == NULL)

Looks like 4.4.3 is wrong, 4.4.4+ does it better and does not choke. Just to make sure the optimizer is given a chance to see the truth, could you try without this patch, but with tagging check_task_priority() as inline instead, with --disable-debug, then with --enable-debug=full switches?

Without this patch, inlined check_task_prio, --disable-debug:
/bin/sh ../../libtool --tag=CC --mode=compile
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc -DHAVE_CONFIG_H -I. -I../../lib/include -O2 -D_GNU_SOURCE -D_REENTRANT -Wall -pipe -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo -MD -MP -MF .deps/libpsos_la-task.Tpo -c -o libpsos_la-task.lo test -f 'task.c' || echo './'task.c
libtool: compile:
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc -DHAVE_CONFIG_H -I. -I../../lib/include -O2 -D_GNU_SOURCE -D_REENTRANT -Wall -pipe -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__ -Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo -MD -MP -MF .deps/libpsos_la-task.Tpo -c task.c -fPIC -DPIC -o .libs/libpsos_la-task.o
cc1: warnings being treated as errors
task.c: In function 't_setpri':
task.c:417: error: 'cprio' may be used uninitialized in this function make[3]: *** [libpsos_la-task.lo] Error 1

Without this patch, inlined check_task_prio, --enable-debug=full
/bin/sh ../../libtool --tag=CC --mode=compile
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc -DHAVE_CONFIG_H -I. -I../../lib/include -g -D__XENO_DEBUG__ -D__XENO_DEBUG_FULL__ -D_GNU_SOURCE -D_REENTRANT -Wall -pipe -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo -MD -MP -MF .deps/libpsos_la-task.Tpo -c -o libpsos_la-task.lo test -f 'task.c' || echo './'task.c
libtool: compile:
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc -DHAVE_CONFIG_H -I. -I../../lib/include -g -D__XENO_DEBUG__ -D__XENO_DEBUG_FULL__ -D_GNU_SOURCE -D_REENTRANT -Wall -pipe -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long -Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__ -Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo -MD -MP -MF .deps/libpsos_la-task.Tpo -c task.c -fPIC -DPIC -o .libs/libpsos_la-task.o
cc1: warnings being treated as errors
task.c: In function 't_setpri':
task.c:417: error: 'cprio' may be used uninitialized in this function make[3]: *** [libpsos_la-task.lo] Error 1

So, debug or not, compiler keeps complaining.
For your reference, this is the change I did instead of the patch:

lib/psos/task.c +1 -1
@@ -228,7 +228,7 @@ int psos_task_normalize_priority(unsigne
        return psos_prio;
 }
 
-static int check_task_priority(u_long psos_prio, int *core_prio)
+static inline int check_task_priority(u_long psos_prio, int *core_prio)
 {
        if (psos_prio < 1 || psos_prio > 255) /* In theory. */
                return ERR_PRIOR;

powerpc-linux-gcc (crosstool-NG 1.12.1 - buildroot 2011.08-hgc55c56f04355) 4.4.3 Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

~Thomas

#5 lore raw

Re: [Xenomai-help] [PATCH 1 of 4] psos.h: add definition of ERR_OBJTFULL

In reply to Philippe Gerum

Hi,

Quoted 35 lines · Philippe Gerum
Quoted 34 lines · Thomas De Schampheleire

Hi,

Quoted 21 lines · Philippe Gerum
Quoted 19 lines · Thomas De Schampheleire

Signed-off-by: Thomas De
Schampheleire<[email protected]>

---
 include/psos/psos.h |  1 +

 1 files changed, 1 insertions(+), 0 deletions(-)
include/psos/psos.h +1 -0
@@ -97,6 +97,7 @@
  #define ERR_OBJDEL   0x05
  #define ERR_OBJID    0x06
  #define ERR_OBJTYPE  0x07
+#define ERR_OBJTFULL 0x08
  #define ERR_OBJNF    0x09
 
Quoted 4 lines

include/psos/psos.h line 103

Quoted 1 line
include/psos/psos.h +0 -0
  #define ERR_NOTCB    0x0E

Where is this error code used in the Xenomai tree? Can't find it right now.

It's not used in the Xenomai code itself, but it may be used by applications.
The definition is absent both in Xenomai as Xenomai-forge.

Quoted 7 lines
Quoted 2 lines

~Thomas

Yes, the point is that so far, only the errors the Xenomai emulation does return are mentioned in this file. But we should merge this anyhow, since the original *_create() calls could throw this, so the app has to check despite Xenomai won't fail this way, right?

Ok, I understand the origin now.
But indeed, as you say, legacy apps may still check for ERR_OBJTFULL or any other definition that was in the original psos.h, so Xenomai / Xenomai-forge has to supply these values as well.

~Thomas

#10 lore raw

Re: [Xenomai-help] [PATCH 2 of 4] psos: port long_names feature to xenomai-forge

In reply to Thomas De Schampheleire
Quoted 17 lines · Thomas De Schampheleire
Quoted 16 lines · Philippe Gerum
Quoted 14 lines · Thomas De Schampheleire

While psos interface accepts 4 character ids, non null terminated, xenomai uses longer ids which must be null terminated. Revert to the behaviour of psos interface, while allowing long id strings if the global variable psos_long_names is set to non-zero.

This patch ports the original fix from xenomai to xenomai-forge, fixing following problems:
* a bug in __psos_maybe_short_name so that only 3 characters are retained
* the call to __psos_maybe_short_name also needs to be done in the ident functions
* the pt_create and pt_ident functions also need to be adapted

Quoted 6 lines
Quoted 2 lines

Please merge long_names.h into psos.h, having a separate header for this is way overkill and brings nothing.

It avoids exposing an internal interface to applications through psos.h. If anything, I think we should make a psos_internal.h or whatever, that can host __psos_maybe_short_name among others.

Yes, that would be better. include/psos is really for external stuff anyway. lib/psos/internal.h would make sense.

Quoted 3 lines

~Thomas

Signature · 1 line
Philippe.
#17 lore raw

Re: [Xenomai-help] [PATCH 4 of 4] psos: fix compiler warning: cprio could be used uninitialized

In reply to Thomas De Schampheleire
Quoted 107 lines · Thomas De Schampheleire
Quoted 30 lines · Philippe Gerum
Quoted 29 lines · Thomas De Schampheleire

Assign default 1 to satisfy compiler (tested with gcc 4.4.3)

---
  lib/psos/task.c |  4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)
lib/psos/task.c +2 -2
@@ -247,7 +247,7 @@ u_long t_create(const char *name, u_long
        pthread_attr_t thattr;
        struct syncstate syns;
        struct service svc;
-       int ret, cprio;
+       int ret, cprio = 1;
        char short_name[5];
 
        ret = check_task_priority(prio,&cprio);
@@ -414,7 +414,7 @@ u_long t_resume(u_long tid)
  u_long t_setpri(u_long tid, u_long newprio, u_long *oldprio_r)
  {
        struct psos_task *task;
-       int ret, cprio;
+       int ret, cprio = 1;
 
Quoted 8 lines

lib/psos/task.c u_long t_resume(u_long tid) · line 420

Quoted 3 lines
lib/psos/task.c +0 -0
        task = get_psos_task_or_self(tid,&ret);
        if (task == NULL)

Looks like 4.4.3 is wrong, 4.4.4+ does it better and does not choke. Just to make sure the optimizer is given a chance to see the truth, could you try without this patch, but with tagging check_task_priority() as inline instead, with --disable-debug, then with --enable-debug=full switches?

Without this patch, inlined check_task_prio, --disable-debug:
/bin/sh ../../libtool --tag=CC --mode=compile
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -7
-DHAVE_CONFIG_H -I. -I../../lib/include  -O2 -D_GNU_SOURCE
-D_REENTRANT -Wall -pipe -Wstrict-prototypes -Wmissing-prototypes
-Wno-long-long -Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include   -pipe -Os  -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c -o libpsos_la-task.lo `test
-f 'task.c' || echo './'`task.c

libtool: compile:
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -6
-DHAVE_CONFIG_H -I. -I../../lib/include -O2 -D_GNU_SOURCE -D_REENTRANT
-Wall -pipe -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long
-Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c task.c  -fPIC -DPIC -o

.libs/libpsos_la-task.o
cc1: warnings being treated as errors
task.c: In function 't_setpri':
task.c:417: error: 'cprio' may be used uninitialized in this function make[3]: *** [libpsos_la-task.lo] Error 1

Without this patch, inlined check_task_prio, --enable-debug=full
/bin/sh ../../libtool --tag=CC --mode=compile
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -8
-DHAVE_CONFIG_H -I. -I../../lib/include  -g -D__XENO_DEBUG__
-D__XENO_DEBUG_FULL__ -D_GNU_SOURCE -D_REENTRANT -Wall -pipe
-Wstrict-prototypes -Wmissing-prototypes -Wno-long-long
-Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include   -pipe -Os  -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c -o libpsos_la-task.lo `test
-f 'task.c' || echo './'`task.c

libtool: compile:
/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -7
-DHAVE_CONFIG_H -I. -I../../lib/include -g -D__XENO_DEBUG__
-D__XENO_DEBUG_FULL__ -D_GNU_SOURCE -D_REENTRANT -Wall -pipe
-Wstrict-prototypes -Wmissing-prototypes -Wno-long-long
-Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c task.c  -fPIC -DPIC -o

.libs/libpsos_la-task.o
cc1: warnings being treated as errors
task.c: In function 't_setpri':
task.c:417: error: 'cprio' may be used uninitialized in this function make[3]: *** [libpsos_la-task.lo] Error 1

So, debug or not, compiler keeps complaining.
For your reference, this is the change I did instead of the patch:

lib/psos/task.c +1 -1
@@ -228,7 +228,7 @@ int psos_task_normalize_priority(unsigne
         return psos_prio;
  }
 
-static int check_task_priority(u_long psos_prio, int *core_prio)
+static inline int check_task_priority(u_long psos_prio, int *core_prio)
  {
         if (psos_prio<  1 || psos_prio>  255) /* In theory. */
                 return ERR_PRIOR;
Quoted 7 lines

powerpc-linux-gcc (crosstool-NG 1.12.1 - buildroot 2011.08-hgc55c56f04355) 4.4.3 Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

~Thomas

Ok, so I'll merge this.

Signature · 1 line
Philippe.
#6 lore raw

Re: [Xenomai-help] [PATCH 1 of 4] psos.h: add definition of ERR_OBJTFULL

In reply to Thomas De Schampheleire
Quoted 46 lines · Thomas De Schampheleire

Hi,

Quoted 35 lines · Philippe Gerum
Quoted 34 lines · Thomas De Schampheleire

Hi,

Quoted 21 lines · Philippe Gerum
Quoted 19 lines · Thomas De Schampheleire

Signed-off-by: Thomas De
Schampheleire<[email protected]>

---
  include/psos/psos.h |  1 +
  1 files changed, 1 insertions(+), 0 deletions(-)
include/psos/psos.h +1 -0
@@ -97,6 +97,7 @@
  #define ERR_OBJDEL   0x05
  #define ERR_OBJID    0x06
  #define ERR_OBJTYPE  0x07
+#define ERR_OBJTFULL 0x08
  #define ERR_OBJNF    0x09
 
Quoted 4 lines

include/psos/psos.h line 103

Quoted 1 line
include/psos/psos.h +0 -0
  #define ERR_NOTCB    0x0E

Where is this error code used in the Xenomai tree? Can't find it right now.

It's not used in the Xenomai code itself, but it may be used by applications.
The definition is absent both in Xenomai as Xenomai-forge.

Quoted 7 lines
Quoted 2 lines

~Thomas

Yes, the point is that so far, only the errors the Xenomai emulation does return are mentioned in this file. But we should merge this anyhow, since the original *_create() calls could throw this, so the app has to check despite Xenomai won't fail this way, right?

Quoted 4 lines

Ok, I understand the origin now.
But indeed, as you say, legacy apps may still check for ERR_OBJTFULL or any other definition that was in the original psos.h, so Xenomai / Xenomai-forge has to supply these values as well.

Ok, I'll merge this since this is explicitly defined by the original interface Xenomai does emulate. So, ok.

Quoted 3 lines

~Thomas

Signature · 1 line
Philippe.
#18 lore raw

Re: [Xenomai-help] [PATCH 4 of 4] psos: fix compiler warning: cprio could be used uninitialized

In reply to Philippe Gerum
Quoted 123 lines · Philippe Gerum
Quoted 122 lines · Thomas De Schampheleire
Quoted 32 lines · Philippe Gerum
Quoted 30 lines · Thomas De Schampheleire

Assign default 1 to satisfy compiler (tested with gcc 4.4.3)

Signed-off-by: Thomas De
Schampheleire<[email protected]>

---
 lib/psos/task.c |  4 ++--

 1 files changed, 2 insertions(+), 2 deletions(-)
lib/psos/task.c +2 -2
@@ -247,7 +247,7 @@ u_long t_create(const char *name, u_long
        pthread_attr_t thattr;
        struct syncstate syns;
        struct service svc;
-       int ret, cprio;
+       int ret, cprio = 1;
        char short_name[5];
 
        ret = check_task_priority(prio,&cprio);
@@ -414,7 +414,7 @@ u_long t_resume(u_long tid)
  u_long t_setpri(u_long tid, u_long newprio, u_long *oldprio_r)
  {
        struct psos_task *task;
-       int ret, cprio;
+       int ret, cprio = 1;
 
Quoted 9 lines

lib/psos/task.c u_long t_resume(u_long tid) · line 420

Quoted 3 lines
lib/psos/task.c +0 -0
        task = get_psos_task_or_self(tid,&ret);
        if (task == NULL)

Looks like 4.4.3 is wrong, 4.4.4+ does it better and does not choke. Just to
make sure the optimizer is given a chance to see the truth, could you try without this patch, but with tagging check_task_priority() as inline instead, with --disable-debug, then with --enable-debug=full switches?

Without this patch, inlined check_task_prio, --disable-debug:
/bin/sh ../../libtool  --tag=CC   --mode=compile

/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -7
-DHAVE_CONFIG_H -I. -I../../lib/include  -O2 -D_GNU_SOURCE
-D_REENTRANT -Wall -pipe -Wstrict-prototypes -Wmissing-prototypes
-Wno-long-long -Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include   -pipe -Os  -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c -o libpsos_la-task.lo `test
-f 'task.c' || echo './'`task.c

libtool: compile:

/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -6
-DHAVE_CONFIG_H -I. -I../../lib/include -O2 -D_GNU_SOURCE -D_REENTRANT
-Wall -pipe -Wstrict-prototypes -Wmissing-prototypes -Wno-long-long
-Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c task.c  -fPIC -DPIC -o

.libs/libpsos_la-task.o
cc1: warnings being treated as errors
task.c: In function 't_setpri':
task.c:417: error: 'cprio' may be used uninitialized in this function make[3]: *** [libpsos_la-task.lo] Error 1

Without this patch, inlined check_task_prio, --enable-debug=full /bin/sh ../../libtool  --tag=CC   --mode=compile

/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -8
-DHAVE_CONFIG_H -I. -I../../lib/include  -g -D__XENO_DEBUG__
-D__XENO_DEBUG_FULL__ -D_GNU_SOURCE -D_REENTRANT -Wall -pipe
-Wstrict-prototypes -Wmissing-prototypes -Wno-long-long
-Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include   -pipe -Os  -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c -o libpsos_la-task.lo `test
-f 'task.c' || echo './'`task.c

libtool: compile:

/repo/tdescham/reborn/buildroot-forge/output/host/usr/bin/powerpc-linux-gcc

(quoted diff) +0 -7
-DHAVE_CONFIG_H -I. -I../../lib/include -g -D__XENO_DEBUG__
-D__XENO_DEBUG_FULL__ -D_GNU_SOURCE -D_REENTRANT -Wall -pipe
-Wstrict-prototypes -Wmissing-prototypes -Wno-long-long
-Wno-unused-parameter -Werror -D__XENO__ -D__IN_XENO__
-Wstrict-prototypes -I../../include -pipe -Os -D_LARGEFILE_SOURCE
-D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -MT libpsos_la-task.lo
-MD -MP -MF .deps/libpsos_la-task.Tpo -c task.c  -fPIC -DPIC -o

.libs/libpsos_la-task.o
cc1: warnings being treated as errors
task.c: In function 't_setpri':
task.c:417: error: 'cprio' may be used uninitialized in this function make[3]: *** [libpsos_la-task.lo] Error 1

So, debug or not, compiler keeps complaining.
For your  reference, this is the change I did instead of the patch:

lib/psos/task.c +1 -1
@@ -228,7 +228,7 @@ int psos_task_normalize_priority(unsigne
         return psos_prio;
  }
 
-static int check_task_priority(u_long psos_prio, int *core_prio)
+static inline int check_task_priority(u_long psos_prio, int *core_prio)
  {

        if (psos_prio<  1 || psos_prio>  255) /* In theory. */ return ERR_PRIOR;

powerpc-linux-gcc (crosstool-NG 1.12.1 - buildroot 2011.08-hgc55c56f04355) 4.4.3
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Quoted 5 lines
Quoted 2 lines

~Thomas

Ok, so I'll merge this.

ok, thanks.

#20 lore raw
In reply to Thomas De Schampheleire
Quoted 31 lines · Thomas De Schampheleire

Hi,

Quoted 10 lines · Thomas De Schampheleire

This patch series includes some misc. fixes to xenomai-forge:

* definition of ERR_OBJTFULL (should also be added to Xenomai proper)
* port long_names feature to xenomai-forge and fix it
* add tm_getm() function (not present in pSOS but present in Xenomai proper)
* fix compiler warning in task.c

Quoted 16 lines
---
  include/psos/Makefile.am  |   2 +-
  include/psos/Makefile.in  |   2 +-
  include/psos/long_names.h |  14 ++++++++++++++
  include/psos/psos.h       |   5 +++++
  lib/psos/init.c           |  15 +++++++++++++++
  lib/psos/pt.c             |   6 ++++++
  lib/psos/queue.c          |   6 ++++++
  lib/psos/rn.c             |   5 +++++
  lib/psos/sem.c            |   6 ++++++
  lib/psos/task.c           |   9 +++++++--
  lib/psos/tm.c             |   7 +++++++
  11 files changed, 73 insertions(+), 4 deletions(-)
Quoted 1 line

Do you have any comments on this patch series?

Merged as discussed, thanks.

Quoted 9 lines

Thanks,
Thomas

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Signature · 1 line
Philippe.
#21 lore raw
Quoted 35 lines · Philippe Gerum
Quoted 34 lines · Thomas De Schampheleire

Hi,

Quoted 28 lines · Thomas De Schampheleire

This patch series includes some misc. fixes to xenomai-forge:

* definition of ERR_OBJTFULL (should also be added to Xenomai proper)
* port long_names feature to xenomai-forge and fix it
* add tm_getm() function (not present in pSOS but present in Xenomai proper)
* fix compiler warning in task.c

---
 include/psos/Makefile.am  |   2 +-
 include/psos/Makefile.in  |   2 +-
 include/psos/long_names.h |  14 ++++++++++++++
 include/psos/psos.h       |   5 +++++
 lib/psos/init.c           |  15 +++++++++++++++
 lib/psos/pt.c             |   6 ++++++
 lib/psos/queue.c          |   6 ++++++
 lib/psos/rn.c             |   5 +++++
 lib/psos/sem.c            |   6 ++++++
 lib/psos/task.c           |   9 +++++++--
 lib/psos/tm.c             |   7 +++++++

 11 files changed, 73 insertions(+), 4 deletions(-)
Quoted 4 lines
Quoted 1 line

Do you have any comments on this patch series?

Merged as discussed, thanks.

Thanks for implementing the updates.

~Thomas