source: rtems/cpukit/rtems/src/statustext.c @ d78d529

5
Last change on this file since d78d529 was c499856, checked in by Chris Johns <chrisj@…>, on 03/20/14 at 21:10:47

Change all references of rtems.com to rtems.org.

  • Property mode set to 100644
File size: 1.4 KB
Line 
1/**
2 * @file
3 *
4 * @ingroup ClassicStatus
5 */
6
7/*
8 * Copyright (c) 2014 embedded brains GmbH.  All rights reserved.
9 *
10 *  embedded brains GmbH
11 *  Dornierstr. 4
12 *  82178 Puchheim
13 *  Germany
14 *  <rtems@embedded-brains.de>
15 *
16 * The license and distribution terms for this file may be
17 * found in the file LICENSE in this distribution or at
18 * http://www.rtems.org/license/LICENSE.
19 */
20
21#if HAVE_CONFIG_H
22  #include "config.h"
23#endif
24
25#include <rtems.h>
26
27static const char *const status_code_text[] = {
28  "RTEMS_SUCCESSFUL",
29  "RTEMS_TASK_EXITTED",
30  "RTEMS_MP_NOT_CONFIGURED",
31  "RTEMS_INVALID_NAME",
32  "RTEMS_INVALID_ID",
33  "RTEMS_TOO_MANY",
34  "RTEMS_TIMEOUT",
35  "RTEMS_OBJECT_WAS_DELETED",
36  "RTEMS_INVALID_SIZE",
37  "RTEMS_INVALID_ADDRESS",
38  "RTEMS_INVALID_NUMBER",
39  "RTEMS_NOT_DEFINED",
40  "RTEMS_RESOURCE_IN_USE",
41  "RTEMS_UNSATISFIED",
42  "RTEMS_INCORRECT_STATE",
43  "RTEMS_ALREADY_SUSPENDED",
44  "RTEMS_ILLEGAL_ON_SELF",
45  "RTEMS_ILLEGAL_ON_REMOTE_OBJECT",
46  "RTEMS_CALLED_FROM_ISR",
47  "RTEMS_INVALID_PRIORITY",
48  "RTEMS_INVALID_CLOCK",
49  "RTEMS_INVALID_NODE",
50  "RTEMS_NOT_CONFIGURED",
51  "RTEMS_NOT_OWNER_OF_RESOURCE",
52  "RTEMS_NOT_IMPLEMENTED",
53  "RTEMS_INTERNAL_ERROR",
54  "RTEMS_NO_MEMORY",
55  "RTEMS_IO_ERROR",
56  "RTEMS_PROXY_BLOCKING"
57};
58
59const char *rtems_status_text( rtems_status_code code )
60{
61  size_t i = code;
62  const char *text = "?";
63
64  if ( i < RTEMS_ARRAY_SIZE( status_code_text ) ) {
65    text = status_code_text [i];
66  }
67
68  return text;
69}
Note: See TracBrowser for help on using the repository browser.