Changeset 31473b7 in rtems


Ignore:
Timestamp:
Nov 16, 1999, 4:03:21 PM (22 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
f4b76ab5
Parents:
165fe39
Message:

Works now.

Removed times() since the version in the C Library support code is
fine.

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • c/src/exec/libcsupport/src/utsname.c

    r165fe39 r31473b7  
    66#include <string.h>
    77
     8#include <errno.h>
    89#include <sys/utsname.h>
     10
    911
    1012#include <rtems/system.h>
    1113#include <rtems/score/object.h>
     14#include <rtems/sptables.h>
     15
     16#include <rtems/posix/seterr.h>
    1217
    1318/*PAGE
     
    2833  */
    2934
     35  if ( !name )
     36    set_errno_and_return_minus_one( EFAULT );
     37
    3038  strcpy( name->sysname, "RTEMS" );
    3139
    32   sprintf( name->nodename, "Node %d\n", _Objects_Local_node );
     40  sprintf( name->nodename, "Node %d", _Objects_Local_node );
    3341
    34   /* XXX release string is in BAD format for this routine!!! */
    35   strcpy( name->release, "4.0.0+" );
     42  strcpy( name->release, RTEMS_VERSION );
     43
     44  strcpy( name->version, "" );
    3645 
    37   /* XXX does this have any meaning for RTEMS */
    38    
    39   strcpy( name->release, "" );
    40 
    4146  sprintf( name->machine, "%s/%s", CPU_NAME, CPU_MODEL_NAME );
    4247
    4348  return 0;
    4449}
    45 
    46 /*PAGE
    47  *
    48  *  4.5.2 Get Process Times, P1003.1b-1993, p. 92
    49  */
    50 
    51 clock_t times(
    52   struct tms   *buffer
    53 )
    54 {
    55   return POSIX_NOT_IMPLEMENTED();
    56 }
  • c/src/exec/posix/src/utsname.c

    r165fe39 r31473b7  
    66#include <string.h>
    77
     8#include <errno.h>
    89#include <sys/utsname.h>
     10
    911
    1012#include <rtems/system.h>
    1113#include <rtems/score/object.h>
     14#include <rtems/sptables.h>
     15
     16#include <rtems/posix/seterr.h>
    1217
    1318/*PAGE
     
    2833  */
    2934
     35  if ( !name )
     36    set_errno_and_return_minus_one( EFAULT );
     37
    3038  strcpy( name->sysname, "RTEMS" );
    3139
    32   sprintf( name->nodename, "Node %d\n", _Objects_Local_node );
     40  sprintf( name->nodename, "Node %d", _Objects_Local_node );
    3341
    34   /* XXX release string is in BAD format for this routine!!! */
    35   strcpy( name->release, "4.0.0+" );
     42  strcpy( name->release, RTEMS_VERSION );
     43
     44  strcpy( name->version, "" );
    3645 
    37   /* XXX does this have any meaning for RTEMS */
    38    
    39   strcpy( name->release, "" );
    40 
    4146  sprintf( name->machine, "%s/%s", CPU_NAME, CPU_MODEL_NAME );
    4247
    4348  return 0;
    4449}
    45 
    46 /*PAGE
    47  *
    48  *  4.5.2 Get Process Times, P1003.1b-1993, p. 92
    49  */
    50 
    51 clock_t times(
    52   struct tms   *buffer
    53 )
    54 {
    55   return POSIX_NOT_IMPLEMENTED();
    56 }
  • c/src/lib/libc/utsname.c

    r165fe39 r31473b7  
    66#include <string.h>
    77
     8#include <errno.h>
    89#include <sys/utsname.h>
     10
    911
    1012#include <rtems/system.h>
    1113#include <rtems/score/object.h>
     14#include <rtems/sptables.h>
     15
     16#include <rtems/posix/seterr.h>
    1217
    1318/*PAGE
     
    2833  */
    2934
     35  if ( !name )
     36    set_errno_and_return_minus_one( EFAULT );
     37
    3038  strcpy( name->sysname, "RTEMS" );
    3139
    32   sprintf( name->nodename, "Node %d\n", _Objects_Local_node );
     40  sprintf( name->nodename, "Node %d", _Objects_Local_node );
    3341
    34   /* XXX release string is in BAD format for this routine!!! */
    35   strcpy( name->release, "4.0.0+" );
     42  strcpy( name->release, RTEMS_VERSION );
     43
     44  strcpy( name->version, "" );
    3645 
    37   /* XXX does this have any meaning for RTEMS */
    38    
    39   strcpy( name->release, "" );
    40 
    4146  sprintf( name->machine, "%s/%s", CPU_NAME, CPU_MODEL_NAME );
    4247
    4348  return 0;
    4449}
    45 
    46 /*PAGE
    47  *
    48  *  4.5.2 Get Process Times, P1003.1b-1993, p. 92
    49  */
    50 
    51 clock_t times(
    52   struct tms   *buffer
    53 )
    54 {
    55   return POSIX_NOT_IMPLEMENTED();
    56 }
  • cpukit/libcsupport/src/utsname.c

    r165fe39 r31473b7  
    66#include <string.h>
    77
     8#include <errno.h>
    89#include <sys/utsname.h>
     10
    911
    1012#include <rtems/system.h>
    1113#include <rtems/score/object.h>
     14#include <rtems/sptables.h>
     15
     16#include <rtems/posix/seterr.h>
    1217
    1318/*PAGE
     
    2833  */
    2934
     35  if ( !name )
     36    set_errno_and_return_minus_one( EFAULT );
     37
    3038  strcpy( name->sysname, "RTEMS" );
    3139
    32   sprintf( name->nodename, "Node %d\n", _Objects_Local_node );
     40  sprintf( name->nodename, "Node %d", _Objects_Local_node );
    3341
    34   /* XXX release string is in BAD format for this routine!!! */
    35   strcpy( name->release, "4.0.0+" );
     42  strcpy( name->release, RTEMS_VERSION );
     43
     44  strcpy( name->version, "" );
    3645 
    37   /* XXX does this have any meaning for RTEMS */
    38    
    39   strcpy( name->release, "" );
    40 
    4146  sprintf( name->machine, "%s/%s", CPU_NAME, CPU_MODEL_NAME );
    4247
    4348  return 0;
    4449}
    45 
    46 /*PAGE
    47  *
    48  *  4.5.2 Get Process Times, P1003.1b-1993, p. 92
    49  */
    50 
    51 clock_t times(
    52   struct tms   *buffer
    53 )
    54 {
    55   return POSIX_NOT_IMPLEMENTED();
    56 }
Note: See TracChangeset for help on using the changeset viewer.