Changeset 6c06288 in rtems


Ignore:
Timestamp:
Jan 29, 2008, 9:52:21 PM (12 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.9, master
Children:
65450c14
Parents:
9252e55e
Message:

2008-01-29 Joel Sherrill <joel.sherrill@…>

  • itron/src/exd_tsk.c, itron/src/task.c, libmisc/capture/capture.c, libmisc/monitor/mon-config.c, libmisc/monitor/mon-driver.c, libmisc/monitor/mon-itask.c, libmisc/monitor/mon-monitor.c, libmisc/monitor/mon-mpci.c, libmisc/monitor/mon-object.c, libmisc/monitor/mon-symbols.c, posix/src/cancelrun.c, posix/src/pthreadexit.c, rtems/Makefile.am, rtems/preinstall.am, rtems/include/rtems.h, rtems/include/rtems/rtems/support.h, rtems/inline/rtems/rtems/tasks.inl, rtems/src/eventmp.c, rtems/src/msgmp.c, rtems/src/partmp.c, rtems/src/regionmp.c, rtems/src/rtemsobjectgetname.c, rtems/src/semmp.c, rtems/src/signalmp.c, rtems/src/taskdelete.c, rtems/src/taskmp.c, rtems/src/timerserver.c, score/Makefile.am, score/include/rtems/score/object.h, score/inline/rtems/score/object.inl, score/src/Unlimited.txt, score/src/objectgetnameasstring.c, score/src/threadqextractwithproxy.c: Add new Object Services collection. This changed the name of a few previously public but undocumented services and added a some new services.
  • rtems/include/rtems/rtems/object.h, rtems/src/rtemsbuildid.c, rtems/src/rtemsbuildname.c, rtems/src/rtemsobjectapimaximumclass.c, rtems/src/rtemsobjectapiminimumclass.c, rtems/src/rtemsobjectgetapiclassname.c, rtems/src/rtemsobjectgetapiname.c, rtems/src/rtemsobjectgetclassicname.c, rtems/src/rtemsobjectgetclassinfo.c, rtems/src/rtemsobjectidapimaximum.c, rtems/src/rtemsobjectidapiminimum.c, rtems/src/rtemsobjectidgetapi.c, rtems/src/rtemsobjectidgetclass.c, rtems/src/rtemsobjectidgetindex.c, rtems/src/rtemsobjectidgetnode.c, rtems/src/rtemsobjectsetname.c, score/src/objectapimaximumclass.c, score/src/objectgetinfo.c, score/src/objectgetinfoid.c, score/src/objectsetname.c: New files.
  • rtems/src/rtemsidtoname.c: Removed.
Location:
cpukit
Files:
19 added
34 edited
1 moved

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    r9252e55e r6c06288  
     12008-01-29      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * itron/src/exd_tsk.c, itron/src/task.c, libmisc/capture/capture.c,
     4        libmisc/monitor/mon-config.c, libmisc/monitor/mon-driver.c,
     5        libmisc/monitor/mon-itask.c, libmisc/monitor/mon-monitor.c,
     6        libmisc/monitor/mon-mpci.c, libmisc/monitor/mon-object.c,
     7        libmisc/monitor/mon-symbols.c, posix/src/cancelrun.c,
     8        posix/src/pthreadexit.c, rtems/Makefile.am, rtems/preinstall.am,
     9        rtems/include/rtems.h, rtems/include/rtems/rtems/support.h,
     10        rtems/inline/rtems/rtems/tasks.inl, rtems/src/eventmp.c,
     11        rtems/src/msgmp.c, rtems/src/partmp.c, rtems/src/regionmp.c,
     12        rtems/src/rtemsobjectgetname.c, rtems/src/semmp.c,
     13        rtems/src/signalmp.c, rtems/src/taskdelete.c, rtems/src/taskmp.c,
     14        rtems/src/timerserver.c, score/Makefile.am,
     15        score/include/rtems/score/object.h,
     16        score/inline/rtems/score/object.inl, score/src/Unlimited.txt,
     17        score/src/objectgetnameasstring.c,
     18        score/src/threadqextractwithproxy.c: Add new Object Services
     19        collection. This changed the name of a few previously public but
     20        undocumented services and added a some new services.
     21        * rtems/include/rtems/rtems/object.h, rtems/src/rtemsbuildid.c,
     22        rtems/src/rtemsbuildname.c, rtems/src/rtemsobjectapimaximumclass.c,
     23        rtems/src/rtemsobjectapiminimumclass.c,
     24        rtems/src/rtemsobjectgetapiclassname.c,
     25        rtems/src/rtemsobjectgetapiname.c,
     26        rtems/src/rtemsobjectgetclassicname.c,
     27        rtems/src/rtemsobjectgetclassinfo.c,
     28        rtems/src/rtemsobjectidapimaximum.c,
     29        rtems/src/rtemsobjectidapiminimum.c, rtems/src/rtemsobjectidgetapi.c,
     30        rtems/src/rtemsobjectidgetclass.c, rtems/src/rtemsobjectidgetindex.c,
     31        rtems/src/rtemsobjectidgetnode.c, rtems/src/rtemsobjectsetname.c,
     32        score/src/objectapimaximumclass.c, score/src/objectgetinfo.c,
     33        score/src/objectgetinfoid.c, score/src/objectsetname.c: New files.
     34        * rtems/src/rtemsidtoname.c: Removed.
     35
    1362008-01-29      Jennifer Averett <jennifer.averett@OARcorp.com>
    237
  • cpukit/itron/src/exd_tsk.c

    r9252e55e r6c06288  
    11/*
    2  *  COPYRIGHT (c) 1989-1999.
     2 *  COPYRIGHT (c) 1989-2008.
    33 *  On-Line Applications Research Corporation (OAR).
    44 *
     
    3535  _Thread_Disable_dispatch();
    3636
    37   the_information = _Objects_Get_information( _Thread_Executing->Object.id );
     37  the_information = _Objects_Get_information_id( _Thread_Executing->Object.id );
    3838
    3939  /* This should never happen if _Thread_Get() works right */
  • cpukit/itron/src/task.c

    r9252e55e r6c06288  
    11/*
    2  *  COPYRIGHT (c) 1989-1999.
     2 *  COPYRIGHT (c) 1989-2008.
    33 *  On-Line Applications Research Corporation (OAR).
    44 *
     
    9696  Objects_Information     *the_information;
    9797
    98   the_information = _Objects_Get_information( the_thread->Object.id );
     98  the_information = _Objects_Get_information_id( the_thread->Object.id );
    9999  if ( !the_information ) {
    100100    return E_OBJ;             /* XXX - should never happen */
  • cpukit/libmisc/capture/capture.c

    r9252e55e r6c06288  
    88  Chris Johns (ccj@acm.org)
    99
    10   COPYRIGHT (c) 1989-1998.
     10  COPYRIGHT (c) 1989-2008.
    1111  On-Line Applications Research Corporation (OAR).
    1212
     
    10561056  else
    10571057  {
    1058     capture_extension_index = rtems_get_index (capture_id);;
     1058    capture_extension_index = rtems_object_id_get_index (capture_id);;
    10591059  }
    10601060
  • cpukit/libmisc/monitor/mon-config.c

    r9252e55e r6c06288  
    6565{
    6666    rtems_configuration_table *c = _Configuration_Table;
    67     int n = rtems_get_index(*next_id);
     67    int n = rtems_object_id_get_index(*next_id);
    6868
    6969    if (n >= 1)
  • cpukit/libmisc/monitor/mon-driver.c

    r9252e55e r6c06288  
    6969{
    7070    rtems_configuration_table *c = _Configuration_Table;
    71     uint32_t   n = rtems_get_index(*next_id);
     71    uint32_t   n = rtems_object_id_get_index(*next_id);
    7272
    7373    if (n >= c->number_of_device_drivers)
  • cpukit/libmisc/monitor/mon-itask.c

    r9252e55e r6c06288  
    4646    rtems_configuration_table *c = _Configuration_Table;
    4747    rtems_initialization_tasks_table *itask;
    48     uint32_t   n = rtems_get_index(*next_id);
     48    uint32_t   n = rtems_object_id_get_index(*next_id);
    4949
    5050    if (n >= c->RTEMS_api_configuration->number_of_initialization_tasks)
  • cpukit/libmisc/monitor/mon-monitor.c

    r9252e55e r6c06288  
    605605    }
    606606
    607     rtems_monitor_node = rtems_get_node(rtems_monitor_task_id);
     607    rtems_monitor_node = rtems_object_id_get_node(rtems_monitor_task_id);
    608608    rtems_monitor_default_node = rtems_monitor_node;
    609609
  • cpukit/libmisc/monitor/mon-mpci.c

    r9252e55e r6c06288  
    7575{
    7676    rtems_configuration_table *c = _Configuration_Table;
    77     int n = rtems_get_index(*next_id);
     77    int n = rtems_object_id_get_index(*next_id);
    7878
    7979    if (n >= 1)
  • cpukit/libmisc/monitor/mon-object.c

    r9252e55e r6c06288  
    141141    uint32_t    node;
    142142
    143     node = rtems_get_node(id);
     143    node = rtems_object_id_get_node(id);
    144144    if (node == 0)
    145145    {
    146         if (rtems_get_class(id) != OBJECTS_CLASSIC_NO_CLASS)
    147             type = rtems_get_class(id);
    148 
    149         id = _Objects_Build_id(
    150           OBJECTS_CLASSIC_API, type, default_node, rtems_get_index(id));
     146        if (rtems_object_id_get_class(id) != OBJECTS_CLASSIC_NO_CLASS)
     147            type = rtems_object_id_get_class(id);
     148
     149        id = rtems_build_id(
     150          OBJECTS_CLASSIC_API,
     151          type,
     152          default_node,
     153          rtems_object_id_get_index(id)
     154        );
    151155    }
    152156    return id;
     
    190194    request.argument1 = (uint32_t  ) id;
    191195
    192     status = rtems_monitor_server_request(rtems_get_node(id), &request, &response);
     196    status = rtems_monitor_server_request(
     197      rtems_object_id_get_node(id), &request, &response);
    193198    if (status != RTEMS_SUCCESSFUL)
    194199        goto failed;
     
    371376            id = (rtems_id) strtoul(argv[arg], 0, 16);
    372377            id = rtems_monitor_id_fixup(id, default_node, type);
    373             type = (rtems_monitor_object_type_t) rtems_get_class(id);
     378            type = (rtems_monitor_object_type_t) rtems_object_id_get_class(id);
    374379
    375380            /*
     
    396401            rtems_monitor_object_dump_1(info, id, verbose);
    397402
    398             default_node = rtems_get_node(id);
     403            default_node = rtems_object_id_get_node(id);
    399404
    400405            last_type = type;
  • cpukit/libmisc/monitor/mon-symbols.c

    r9252e55e r6c06288  
    305305{
    306306    rtems_symbol_table_t *table;
    307     uint32_t   n = rtems_get_index(*next_id);
     307    uint32_t   n = rtems_object_id_get_index(*next_id);
    308308
    309309    table = *(rtems_symbol_table_t **) object_info;
  • cpukit/posix/src/cancelrun.c

    r9252e55e r6c06288  
    11/*
    2  *  COPYRIGHT (c) 1989-2007.
     2 *  COPYRIGHT (c) 1989-2008.
    33 *  On-Line Applications Research Corporation (OAR).
    44 *
     
    6363  the_thread->Wait.return_argument = PTHREAD_CANCELED;
    6464  _Thread_Close(
    65     _Objects_Get_information( the_thread->Object.id ),
     65    _Objects_Get_information_id( the_thread->Object.id ),
    6666    the_thread
    6767  );
  • cpukit/posix/src/pthreadexit.c

    r9252e55e r6c06288  
    44 *  NOTE: Key destructors are executed in the POSIX api delete extension.
    55 *
    6  *  COPYRIGHT (c) 1989-1999.
     6 *  COPYRIGHT (c) 1989-2008.
    77 *  On-Line Applications Research Corporation (OAR).
    88 *
     
    3232  Objects_Information     *the_information;
    3333
    34   the_information = _Objects_Get_information( _Thread_Executing->Object.id );
     34  the_information = _Objects_Get_information_id( _Thread_Executing->Object.id );
    3535
    3636  /*
  • cpukit/rtems/Makefile.am

    r9252e55e r6c06288  
    2020include_rtems_rtems_HEADERS = include/rtems/rtems/asr.h \
    2121    include/rtems/rtems/attr.h include/rtems/rtems/barrier.h \
    22     include/rtems/rtems/cache.h \
    23     include/rtems/rtems/clock.h include/rtems/rtems/config.h \
    24     include/rtems/rtems/dpmem.h include/rtems/rtems/event.h \
    25     include/rtems/rtems/eventset.h include/rtems/rtems/intr.h \
    26     include/rtems/rtems/message.h include/rtems/rtems/modes.h \
     22    include/rtems/rtems/cache.h include/rtems/rtems/clock.h \
     23    include/rtems/rtems/config.h include/rtems/rtems/dpmem.h \
     24    include/rtems/rtems/event.h include/rtems/rtems/eventset.h \
     25    include/rtems/rtems/intr.h include/rtems/rtems/message.h \
     26    include/rtems/rtems/modes.h include/rtems/rtems/object.h \
    2727    include/rtems/rtems/options.h include/rtems/rtems/part.h \
    2828    include/rtems/rtems/ratemon.h include/rtems/rtems/region.h \
     
    5353
    5454## src
    55 librtems_a_SOURCES = src/rtemsobjectgetname.c
     55librtems_a_SOURCES = src/rtemsbuildid.c src/rtemsbuildname.c \
     56    src/rtemsobjectgetname.c src/rtemsobjectsetname.c \
     57    src/rtemsobjectidapimaximum.c src/rtemsobjectidapiminimum.c \
     58    src/rtemsobjectidgetapi.c src/rtemsobjectidgetclass.c \
     59    src/rtemsobjectidgetindex.c src/rtemsobjectidgetnode.c \
     60    src/rtemsobjectapiminimumclass.c src/rtemsobjectapimaximumclass.c \
     61    src/rtemsobjectgetapiname.c src/rtemsobjectgetapiclassname.c \
     62    src/rtemsobjectgetclassinfo.c src/rtemsobjectgetclassicname.c
    5663
    5764## TASK_C_FILES
     
    125132    src/dpmeminternal2external.c src/dpmemdata.c
    126133
    127 librtems_a_SOURCES += src/attr.c src/rtemsidtoname.c
     134librtems_a_SOURCES += src/attr.c
    128135
    129136if HAS_MP
  • cpukit/rtems/include/rtems.h

    r9252e55e r6c06288  
    99 *  particular processor.
    1010 *
    11  *  COPYRIGHT (c) 1989-1999.
     11 *  COPYRIGHT (c) 1989-2008.
    1212 *  On-Line Applications Research Corporation (OAR).
    1313 *
     
    5757#include <rtems/rtems/signal.h>
    5858#include <rtems/rtems/event.h>
     59#include <rtems/rtems/object.h>
    5960#include <rtems/rtems/part.h>
    6061#include <rtems/rtems/region.h>
     
    120121#define RTEMS_MINIMUN_HETERO_CONVERSION  MP_PACKET_MINIMUN_HETERO_CONVERSION
    121122
    122 /*
    123  *  rtems_object_id_to_name
    124  *
    125  *  This directive returns the name associated with the specified
    126  *  object ID.
    127  *
    128  *  Input parameters:
    129  *    id   - object id
    130  *
    131  *  Output parameters:
    132  *    *name            - user defined object name
    133  *    RTEMS_SUCCESSFUL - if successful
    134  *    error code       - if unsuccessful
    135  */
    136 
    137 rtems_status_code rtems_object_id_to_name(
    138   rtems_id      id,
    139   rtems_name   *name
    140 );
    141 
    142 /*
    143  *  rtems_object_get_name
    144  *
    145  *  This directive returns the name associated with the specified
    146  *  object ID.
    147  *
    148  *  Input parameters:
    149  *    id   - object id
    150  *
    151  *  Output parameters:
    152  *    *name            - user defined object name
    153  *    name             - if successful
    154  *    NULL             - if unsuccessful
    155  */
    156 
    157 char *rtems_object_get_name(
    158   rtems_id       id,
    159   size_t         length,
    160   char          *name
    161 );
    162 
    163123#ifdef __cplusplus
    164124}
  • cpukit/rtems/include/rtems/rtems/support.h

    r9252e55e r6c06288  
    77 *  the RTEMS API.
    88 *
    9  *  COPYRIGHT (c) 1989-1999.
     9 *  COPYRIGHT (c) 1989-2008.
    1010 *  On-Line Applications Research Corporation (OAR).
    1111 *
     
    2525
    2626#include <rtems/rtems/types.h>
    27 
    28 /*
    29  *  rtems_build_name
    30  *
    31  *  DESCRIPTION:
    32  *
    33  *  This function returns an object name composed of the four characters
    34  *  C1, C2, C3, and C4.
    35  *
    36  *  NOTE:
    37  *
    38  *  This must be implemented as a macro for use in Configuration Tables.
    39  *
    40  */
    41 
    42 #define rtems_build_name( _C1, _C2, _C3, _C4 ) \
    43   ( (uint32_t  )(_C1) << 24 | (uint32_t  )(_C2) << 16 | (uint32_t  )(_C3) << 8 | (uint32_t  )(_C4) )
    44 
    45 /*
    46  *  rtems_get_class
    47  *
    48  *  DESCRIPTION:
    49  *
    50  *  This function returns the class portion of the ID.
    51  *
    52  */
    53 
    54 #define rtems_get_class( _id ) \
    55   _Objects_Get_class( _id )
    56 
    57 /*
    58  *  rtems_get_node
    59  *
    60  *  DESCRIPTION:
    61  *
    62  *  This function returns the node portion of the ID.
    63  *
    64  */
    65 
    66 #define rtems_get_node( _id ) \
    67   _Objects_Get_node( _id )
    68 
    69 /*
    70  *  rtems_get_index
    71  *
    72  *  DESCRIPTION:
    73  *
    74  *  This function returns the index portion of the ID.
    75  *
    76  */
    77 
    78 #define rtems_get_index( _id ) \
    79   _Objects_Get_index( _id )
    8027
    8128/*
  • cpukit/rtems/inline/rtems/rtems/tasks.inl

    r9252e55e r6c06288  
    77 *  routines in the with RTEMS Tasks Manager.
    88 *
    9  *  COPYRIGHT (c) 1989-1999.
     9 *  COPYRIGHT (c) 1989-2008.
    1010 *  On-Line Applications Research Corporation (OAR).
    1111 *
     
    5050{
    5151  _Objects_Free(
    52     _Objects_Get_information( the_task->Object.id ),
     52    _Objects_Get_information_id( the_task->Object.id ),
    5353    &the_task->Object
    5454  );
  • cpukit/rtems/preinstall.am

    r9252e55e r6c06288  
    7575        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/rtems/modes.h
    7676PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/rtems/modes.h
     77
     78$(PROJECT_INCLUDE)/rtems/rtems/object.h: include/rtems/rtems/object.h $(PROJECT_INCLUDE)/rtems/rtems/$(dirstamp)
     79        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/rtems/rtems/object.h
     80PREINSTALL_FILES += $(PROJECT_INCLUDE)/rtems/rtems/object.h
    7781
    7882$(PROJECT_INCLUDE)/rtems/rtems/options.h: include/rtems/rtems/options.h $(PROJECT_INCLUDE)/rtems/rtems/$(dirstamp)
  • cpukit/rtems/src/eventmp.c

    r9252e55e r6c06288  
    22 *  Multiprocessing Support for the Event Manager
    33 *
    4  *  COPYRIGHT (c) 1989-1999.
     4 *  COPYRIGHT (c) 1989-2008.
    55 *  On-Line Applications Research Corporation (OAR).
    66 *
     
    6464      return (rtems_status_code)
    6565        _MPCI_Send_request_packet(
    66           rtems_get_node( event_id ),
     66          _Objects_Get_node( event_id ),
    6767          &the_packet->Prefix,
    6868          STATES_READY
     
    109109
    110110      _MPCI_Send_response_packet(
    111         rtems_get_node( the_packet->Prefix.source_tid ),
     111        _Objects_Get_node( the_packet->Prefix.source_tid ),
    112112        &the_packet->Prefix
    113113      );
  • cpukit/rtems/src/msgmp.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-1999.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    6060
    6161      if ( operation == MESSAGE_QUEUE_MP_EXTRACT_PROXY )
    62          node = rtems_get_node( message_queue_id );
     62         node = _Objects_Get_node( message_queue_id );
    6363      else
    6464         node = MPCI_ALL_NODES;
     
    148148
    149149      return (rtems_status_code) _MPCI_Send_request_packet(
    150         rtems_get_node(message_queue_id),
     150        _Objects_Get_node(message_queue_id),
    151151        &the_packet->Prefix,
    152152        STATES_WAITING_FOR_MESSAGE
     
    173173
    174174      return (rtems_status_code) _MPCI_Send_request_packet(
    175         rtems_get_node(message_queue_id),
     175        _Objects_Get_node(message_queue_id),
    176176        &the_packet->Prefix,
    177177        STATES_WAITING_FOR_MESSAGE
     
    233233
    234234      _MPCI_Send_response_packet(
    235         rtems_get_node( the_packet->Prefix.source_tid ),
     235        _Objects_Get_node( the_packet->Prefix.source_tid ),
    236236        &the_packet->Prefix
    237237      );
  • cpukit/rtems/src/partmp.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-1999.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    5959
    6060      if ( operation == PARTITION_MP_EXTRACT_PROXY )
    61          node = rtems_get_node( partition_id );
     61         node = _Objects_Get_node( partition_id );
    6262      else
    6363         node = MPCI_ALL_NODES;
     
    103103      return
    104104        _MPCI_Send_request_packet(
    105           rtems_get_node( partition_id ),
     105          _Objects_Get_node( partition_id ),
    106106          &the_packet->Prefix,
    107107          STATES_READY      /* Not used */
     
    154154
    155155      _MPCI_Send_response_packet(
    156         rtems_get_node( the_packet->Prefix.source_tid ),
     156        _Objects_Get_node( the_packet->Prefix.source_tid ),
    157157        &the_packet->Prefix
    158158      );
  • cpukit/rtems/src/regionmp.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-1999.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    5959
    6060      if ( operation == REGION_MP_EXTRACT_PROXY )
    61          node = rtems_get_node( region_id );
     61         node = _Object_Get_node( region_id );
    6262      else
    6363         node = MPCI_ALL_NODES;
     
    110110
    111111      return (rtems_status_code) _MPCI_Send_request_packet(
    112           rtems_get_node( region_id ),
     112          _Object_Get_node( region_id ),
    113113          &the_packet->Prefix,
    114114          STATES_READY      /* Not used */
     
    160160
    161161      _MPCI_Send_response_packet(
    162         rtems_get_node( the_packet->Prefix.source_tid ),
     162        _Object_Get_node( the_packet->Prefix.source_tid ),
    163163        &the_packet->Prefix
    164164      );
  • cpukit/rtems/src/rtemsobjectgetclassicname.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-2003.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    2424/*PAGE
    2525 *
    26  *  rtems_object_id_to_name
     26 *  rtems_object_get_classic_name
    2727 *
    2828 *  This directive returns the name associated with the specified
     
    3838 */
    3939
    40 rtems_status_code rtems_object_id_to_name(
     40rtems_status_code rtems_object_get_classic_name(
    4141  rtems_id      id,
    4242  rtems_name   *name
     
    4444{
    4545  Objects_Name_or_id_lookup_errors  status;
     46  Objects_Name                      name_u;
    4647
    47   status = _Objects_Id_to_name( id, (Objects_Name *) name );
     48  if ( !name )
     49    return RTEMS_INVALID_ADDRESS;
    4850
     51  status = _Objects_Id_to_name( id, &name_u );
     52
     53  *name = name_u.name_u32;
    4954  return _Status_Object_name_errors_to_status[ status ];
    5055}
  • cpukit/rtems/src/rtemsobjectgetname.c

    r9252e55e r6c06288  
    22 *  RTEMS Object Helper -- Obtain Name of Object as String
    33 *
    4  *  COPYRIGHT (c) 1989-2007.
     4 *  COPYRIGHT (c) 1989-2008.
    55 *  On-Line Applications Research Corporation (OAR).
    66 *
     
    2020
    2121/*
    22  *  This method objects the name of an object and returns its name
     22 *  This method obtain the name of an object and returns its name
    2323 *  in the form of a C string.  It attempts to be careful about
    2424 *  overflowing the user's string and about returning unprintable characters.
    2525 */
    26 
    2726char *rtems_object_get_name(
    2827  Objects_Id     id,
  • cpukit/rtems/src/semmp.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-1999.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    6060
    6161      if ( operation == SEMAPHORE_MP_EXTRACT_PROXY )
    62          node = rtems_get_node( semaphore_id );
     62         node = _Objects_Get_node( semaphore_id );
    6363      else
    6464         node = MPCI_ALL_NODES;
     
    107107
    108108      return _MPCI_Send_request_packet(
    109           rtems_get_node( semaphore_id ),
     109          _Objects_Get_node( semaphore_id ),
    110110          &the_packet->Prefix,
    111111          STATES_WAITING_FOR_SEMAPHORE
     
    157157
    158158      _MPCI_Send_response_packet(
    159         rtems_get_node( the_packet->Prefix.source_tid ),
     159        _Objects_Get_node( the_packet->Prefix.source_tid ),
    160160        &the_packet->Prefix
    161161      );
  • cpukit/rtems/src/signalmp.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-1999.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    6565
    6666      return _MPCI_Send_request_packet(
    67         rtems_get_node( task_id ),
     67        _Objects_Get_node( task_id ),
    6868        &the_packet->Prefix,
    6969        STATES_READY   /* Not used */
     
    109109
    110110      _MPCI_Send_response_packet(
    111         rtems_get_node( the_packet->Prefix.source_tid ),
     111        _Objects_Get_node( the_packet->Prefix.source_tid ),
    112112        &the_packet->Prefix
    113113      );
  • cpukit/rtems/src/taskdelete.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-2007.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    6363
    6464    case OBJECTS_LOCAL:
    65       the_information = _Objects_Get_information( the_thread->Object.id );
     65      the_information = _Objects_Get_information_id( the_thread->Object.id );
    6666
    6767#if defined(RTEMS_DEBUG)
  • cpukit/rtems/src/taskmp.c

    r9252e55e r6c06288  
    33 *
    44 *
    5  *  COPYRIGHT (c) 1989-1999.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    107107
    108108      return _MPCI_Send_request_packet(
    109         rtems_get_node( task_id ),
     109        _Objects_Get_node( task_id ),
    110110        &the_packet->Prefix,
    111111        STATES_READY     /* Not used */
     
    161161
    162162      _MPCI_Send_response_packet(
    163         rtems_get_node( the_packet->Prefix.source_tid ),
     163        _Objects_Get_node( the_packet->Prefix.source_tid ),
    164164        &the_packet->Prefix
    165165      );
  • cpukit/rtems/src/timerserver.c

    r9252e55e r6c06288  
    33 *      the Timer Server Body and support routines
    44 *
    5  *  COPYRIGHT (c) 1989-2002.
     5 *  COPYRIGHT (c) 1989-2008.
    66 *  On-Line Applications Research Corporation (OAR).
    77 *
     
    189189
    190190  status = rtems_task_create(
    191     rtems_build_name('T','I','M','E'),           /* "TIME" */
     191    _Objects_Build_name('T','I','M','E'),           /* "TIME" */
    192192    _priority,            /* create with priority 1 since 0 is illegal */
    193193    stack_size,           /* let user specify stack size */
  • cpukit/score/Makefile.am

    r9252e55e r6c06288  
    118118    src/objectnametoid.c src/objectnametoidstring.c \
    119119    src/objectshrinkinformation.c src/objectgetnoprotection.c \
    120     src/objectidtoname.c src/objectgetnameasstring.c
     120    src/objectidtoname.c src/objectgetnameasstring.c src/objectsetname.c \
     121    src/objectgetinfo.c src/objectgetinfoid.c src/objectapimaximumclass.c
    121122
    122123## OBJECT_C_FILES only used by ITRON API
  • cpukit/score/include/rtems/score/object.h

    r9252e55e r6c06288  
    1010
    1111/*
    12  *  COPYRIGHT (c) 1989-2007.
     12 *  COPYRIGHT (c) 1989-2008.
    1313 *  On-Line Applications Research Corporation (OAR).
    1414 *
     
    499499
    500500/**
     501 *  This function returns the highest numeric value of a valid
     502 *  API for the specified @code{api}.
     503 *
     504 *  @param[in] api is the API of interest
     505 *
     506 *  @return A positive integer on success and -1 otherwise.
     507 */
     508int _Objects_API_maximum_class(
     509  uint32_t api
     510);
     511
     512/**
    501513 *  This function allocates a object control block from
    502514 *  the inactive chain of free object control blocks.
     
    535547  Objects_Control     *the_object
    536548);
     549
     550/**
     551 *  This macro is used to build a thirty-two bit style name from
     552 *  four characters.  The most significant byte will be the
     553 *  character @code{_C1}.
     554 *
     555 *  @param[in] _C1 is the first character of the name
     556 *  @param[in] _C2 is the second character of the name
     557 *  @param[in] _C3 is the third character of the name
     558 *  @param[in] _C4 is the fourth character of the name
     559 */
     560#define  _Objects_Build_name( _C1, _C2, _C3, _C4 ) \
     561  ( (uint32_t)(_C1) << 24 | \
     562    (uint32_t)(_C2) << 16 | \
     563    (uint32_t)(_C3) << 8 | \
     564    (uint32_t)(_C4) )
    537565
    538566/**
     
    678706 *  @note _Objects_Get returns with dispatching disabled for
    679707 *  local and remote objects.  _Objects_Get_isr_disable returns with
    680  *  dispatching disabled for remote objects and interrupts for local
     708 *  dispatchng disabled for remote objects and interrupts for local
    681709 *  objects.
    682710 */
     
    765793
    766794/**
     795 *  This function return the information structure given
     796 *  an the API and Class.  This can be done independent of
     797 *  the existence of any objects created by the API.
     798 *
     799 *  @param[in] api indicates the API for the information we want
     800 *  @param[in] api indicates the Class for the information we want
     801 *
     802 *
     803 *  @return This method returns a pointer to the Object Information Table
     804 *          for the class of objects which corresponds to this object ID.
     805 */
     806Objects_Information *_Objects_Get_information(
     807  Objects_APIs   api,
     808  uint32_t       class
     809);
     810
     811/**
     812 *  This function return the information structure given
     813 *  an id of an object.
     814 *
     815 *  @param[in] id is an object ID
     816 *
     817 *
     818 *  @return This method returns a pointer to the Object Information Table
     819 *          for the class of objects which corresponds to this object ID.
     820 */
     821Objects_Information *_Objects_Get_information_id(
     822  Objects_Id  id
     823);
     824
     825/**
    767826 *  This method objects the name of an object and returns its name
    768827 *  in the form of a C string.  It attempts to be careful about
     
    775834 *  @return This method returns @a name or NULL on error.
    776835 */
    777 
    778836char *_Objects_Get_name_as_string(
    779837  Objects_Id   id,
     
    782840);
    783841
     842/**
     843 *  This method sets the object name to either a copy of a string
     844 *  or up to the first four characters of the string based upon
     845 *  whether this object class uses strings for names.
     846 *
     847 *  @param[in] information points to the object information structure
     848 *  @param[in] the_object is the object to operate upon
     849 *  @param[in] name is a pointer to the name to use
     850 *
     851 *  @return If successful, TRUE is returned.  Otherwise FALSE is returned.
     852 */
     853boolean _Objects_Set_name(
     854  Objects_Information *information,
     855  Objects_Control     *the_object,
     856  const char          *name
     857);
     858
    784859/*
    785860 *  Pieces of object.inl are promoted out to the user
  • cpukit/score/inline/rtems/score/object.inl

    r9252e55e r6c06288  
    88 *  of the inlined routines in the Object Handler.
    99 *
    10  *  COPYRIGHT (c) 1989-2007.
     10 *  COPYRIGHT (c) 1989-2008.
    1111 *  On-Line Applications Research Corporation (OAR).
    1212 *
     
    245245
    246246/**
    247  *  This function return the information structure given
    248  *  an id of an object.
    249  *
    250  *  @param[in] id is an object ID
    251  *
    252  *
    253  *  @return This method returns a pointer to the Object Information Table
    254  *          for the class of objects which corresponds to this object ID.
    255  */
    256 RTEMS_INLINE_ROUTINE Objects_Information *_Objects_Get_information(
    257   Objects_Id  id
    258 )
    259 {
    260   Objects_APIs  the_api;
    261   uint16_t      the_class;
    262 
    263 
    264   the_class = _Objects_Get_class( id );
    265 
    266   if ( !_Objects_Is_class_valid( the_class ) )
    267     return NULL;
    268 
    269   the_api = _Objects_Get_API( id );
    270   return _Objects_Information_table[ the_api ][ the_class ];
    271 }
    272 
    273 /**
    274247 *  This function places the_object control pointer and object name
    275248 *  in the Local Pointer and Local Name Tables, respectively.
  • cpukit/score/src/Unlimited.txt

    r9252e55e r6c06288  
    231231  The last were inlined, how-ever now they are not as they are too
    232232  complex to implement as macros now.
    233 
    234 o Object Inline and Macro Changes
    235 
    236   The functions :
    237 
    238    _Object_Allocate, and
    239    _Object_Free
    240 
    241   are now not inlined. The function :
    242 
    243    _Objects_Get_local_object, and
    244    _Objects_Set_local_object
    245 
    246   have been added. There was no provided interface to allow an API to
    247   get/set an objects local pointer given an index. The POSIX code
    248   should be updated to use this interface.
    249 
    250   The function :
    251 
    252    _Objects_Get_information
    253 
    254   has been moved to be an inline function. It is used in the get
    255   object call which the API uses for every object reference.
    256233
    257234o Object Initialisation
  • cpukit/score/src/objectgetnameasstring.c

    r9252e55e r6c06288  
    11/*
    2  *  COPYRIGHT (c) 1989-2007.
     2 *  COPYRIGHT (c) 1989-2008.
    33 *  On-Line Applications Research Corporation (OAR).
    44 *
     
    4949    return NULL;
    5050
    51   information = _Objects_Get_information( id );
     51  information = _Objects_Get_information_id( id );
    5252  if ( !information )
    5353    return NULL;
  • cpukit/score/src/threadqextractwithproxy.c

    r9252e55e r6c06288  
    5252        Objects_Thread_queue_Extract_callout  proxy_extract_callout;
    5353
    54         the_information = _Objects_Get_information( the_thread->Wait.id );
     54        the_information = _Objects_Get_information_id( the_thread->Wait.id );
    5555        proxy_extract_callout =
    5656          (Objects_Thread_queue_Extract_callout) the_information->extract;
Note: See TracChangeset for help on using the changeset viewer.