[Xenomai-git] Gilles Chanteperdrix : cobalt/registry: allow to retrieve an object key from its handle
Module: xenomai-forge Branch: master Commit: 0ba78c15f892e5fab25b8a83521fbbb26b0749b9 URL: http://git.xenomai.org/?p=xenomai-forge.git;a=commit;h=0ba78c15f892e5fab25b8a83521fbbb26b0749b9 Author: Gilles Chanteperdrix gilles.chanteperd...@xenomai.org Date: Sun Dec 15 17:08:54 2013 +0100 cobalt/registry: allow to retrieve an object key from its handle --- include/cobalt/kernel/registry.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/include/cobalt/kernel/registry.h b/include/cobalt/kernel/registry.h index 6c25eee..5197542 100644 --- a/include/cobalt/kernel/registry.h +++ b/include/cobalt/kernel/registry.h @@ -163,6 +163,12 @@ static inline void *xnregistry_lookup(xnhandle_t handle) return object ? object-objaddr : NULL; } +static inline const char *xnregistry_key(xnhandle_t handle) +{ + struct xnobject *object = xnregistry_validate(handle); + return object ? object-key : NULL; +} + int xnregistry_enter(const char *key, void *objaddr, xnhandle_t *phandle, ___ Xenomai-git mailing list Xenomai-git@xenomai.org http://www.xenomai.org/mailman/listinfo/xenomai-git
[Xenomai-git] Gilles Chanteperdrix : cobalt/registry: allow to retrieve an object key from its handle
Module: xenomai-forge Branch: next Commit: 0ba78c15f892e5fab25b8a83521fbbb26b0749b9 URL: http://git.xenomai.org/?p=xenomai-forge.git;a=commit;h=0ba78c15f892e5fab25b8a83521fbbb26b0749b9 Author: Gilles Chanteperdrix gilles.chanteperd...@xenomai.org Date: Sun Dec 15 17:08:54 2013 +0100 cobalt/registry: allow to retrieve an object key from its handle --- include/cobalt/kernel/registry.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/include/cobalt/kernel/registry.h b/include/cobalt/kernel/registry.h index 6c25eee..5197542 100644 --- a/include/cobalt/kernel/registry.h +++ b/include/cobalt/kernel/registry.h @@ -163,6 +163,12 @@ static inline void *xnregistry_lookup(xnhandle_t handle) return object ? object-objaddr : NULL; } +static inline const char *xnregistry_key(xnhandle_t handle) +{ + struct xnobject *object = xnregistry_validate(handle); + return object ? object-key : NULL; +} + int xnregistry_enter(const char *key, void *objaddr, xnhandle_t *phandle, ___ Xenomai-git mailing list Xenomai-git@xenomai.org http://www.xenomai.org/mailman/listinfo/xenomai-git
[Xenomai-git] Gilles Chanteperdrix : cobalt/registry: allow to retrieve an object key from its handle
Module: xenomai-gch Branch: for-forge Commit: 0ba78c15f892e5fab25b8a83521fbbb26b0749b9 URL: http://git.xenomai.org/?p=xenomai-gch.git;a=commit;h=0ba78c15f892e5fab25b8a83521fbbb26b0749b9 Author: Gilles Chanteperdrix gilles.chanteperd...@xenomai.org Date: Sun Dec 15 17:08:54 2013 +0100 cobalt/registry: allow to retrieve an object key from its handle --- include/cobalt/kernel/registry.h |6 ++ 1 file changed, 6 insertions(+) diff --git a/include/cobalt/kernel/registry.h b/include/cobalt/kernel/registry.h index 6c25eee..5197542 100644 --- a/include/cobalt/kernel/registry.h +++ b/include/cobalt/kernel/registry.h @@ -163,6 +163,12 @@ static inline void *xnregistry_lookup(xnhandle_t handle) return object ? object-objaddr : NULL; } +static inline const char *xnregistry_key(xnhandle_t handle) +{ + struct xnobject *object = xnregistry_validate(handle); + return object ? object-key : NULL; +} + int xnregistry_enter(const char *key, void *objaddr, xnhandle_t *phandle, ___ Xenomai-git mailing list Xenomai-git@xenomai.org http://www.xenomai.org/mailman/listinfo/xenomai-git