diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-11-18 09:46:34 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-11-19 08:22:34 +0100 |
commit | b7282c736c9b692b2122d718bbd05eb7611d734c (patch) | |
tree | a3f5d6f38c7e86bd05dafe2e45b213689836f370 /spec/rtems | |
parent | spec: Specify rtems_build_name() function (diff) | |
download | rtems-central-b7282c736c9b692b2122d718bbd05eb7611d734c.tar.bz2 |
spec: Use RTEMS_WHO_AM_I for rtems_task_ident()
Diffstat (limited to 'spec/rtems')
-rw-r--r-- | spec/rtems/task/if/ident.yml | 4 | ||||
-rw-r--r-- | spec/rtems/task/req/ident.yml | 27 |
2 files changed, 18 insertions, 13 deletions
diff --git a/spec/rtems/task/if/ident.yml b/spec/rtems/task/if/ident.yml index 1b4e67aa..c739e0b4 100644 --- a/spec/rtems/task/if/ident.yml +++ b/spec/rtems/task/if/ident.yml @@ -18,8 +18,8 @@ description: | This directive obtains a task identifier associated with the task name specified in ${.:/params[0]/name}. - A task may obtain its own identifier by specifying ${self-define:/name} for - the name. + A task may obtain its own identifier by specifying + ${../../object/if/who-am-i:/name} for the name. The node to search is specified in ${.:/params[1]/name}. It shall be diff --git a/spec/rtems/task/req/ident.yml b/spec/rtems/task/req/ident.yml index 964c6532..17b2b526 100644 --- a/spec/rtems/task/req/ident.yml +++ b/spec/rtems/task/req/ident.yml @@ -6,10 +6,12 @@ functional-type: action links: - role: interface-function uid: ../if/ident +- role: interface-function + uid: ../../object/if/who-am-i post-conditions: - name: Status states: - - name: OkAndSelfId + - name: OkAndWhoAmI test-code: | T_rsc( ctx->status, RTEMS_SUCCESSFUL ); T_eq_ptr( ctx->id, &ctx->id_value ); @@ -29,21 +31,24 @@ post-conditions: pre-conditions: - name: Name states: - - name: Self + - name: WhoAmI test-code: | ctx->id_value = 0xffffffff; ctx->id = &ctx->id_value; text: | - While the ${../if/ident:/params[0]/name} parameter is - ${../if/self:/name}. - - name: NotSelf + While the ${../if/ident:/params[0]/name} parameter is equal to + ${../../object/if/who-am-i:/name}, + while ${../if/ident:/params[2]/name} parameter is not equal to + ${/c/if/null:/name}. + - name: NotWhoAmI test-code: | ctx->id = NULL; /* Preparation performed by ${../../req/ident:/test-run}() */ text: | - While the ${../if/ident:/params[0]/name} is not ${../if/self:/name} or - ${../if/ident:/params[2]/name} parameter is ${/c/if/null:/name}, the - behaviour of ${../if/ident:/name} shall be specified by + While the ${../if/ident:/params[0]/name} is not equal to + ${../../object/if/who-am-i:/name} or ${../if/ident:/params[2]/name} + parameter is equal to ${/c/if/null:/name}, + the behaviour of ${../if/ident:/name} shall be specified by ${../../req/ident}. test-epilogue: null test-prologue: null @@ -141,14 +146,14 @@ text: ${.:text-template} transition-map: - enabled-by: true post-conditions: - Status: OkAndSelfId + Status: OkAndWhoAmI pre-conditions: Name: - - Self + - WhoAmI - enabled-by: true post-conditions: Status: Skip pre-conditions: Name: - - NotSelf + - NotWhoAmI type: requirement |