forked from Imagelibrary/rtems
created ptimer.c and moved the timer_* routines out of time.c into ptimer.c
This commit is contained in:
75
c/src/exec/posix/src/ptimer.c
Normal file
75
c/src/exec/posix/src/ptimer.c
Normal file
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <time.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include <rtems/system.h>
|
||||
#include <rtems/score/isr.h>
|
||||
#include <rtems/score/thread.h>
|
||||
#include <rtems/score/tod.h>
|
||||
|
||||
#include <rtems/posix/time.h>
|
||||
|
||||
/*
|
||||
* 14.2.2 Create a Per-Process Timer, P1003.1b-1993, p. 264
|
||||
*/
|
||||
|
||||
int timer_create(
|
||||
clockid_t clock_id,
|
||||
struct sigevent *evp,
|
||||
timer_t *timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.3 Delete a Per_process Timer, P1003.1b-1993, p. 266
|
||||
*/
|
||||
|
||||
int timer_delete(
|
||||
timer_t timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_settime(
|
||||
timer_t timerid,
|
||||
int flags,
|
||||
const struct itimerspec *value,
|
||||
struct itimerspec *ovalue
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_gettime(
|
||||
timer_t timerid,
|
||||
struct itimerspec *value
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_getoverrun(
|
||||
timer_t timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
@@ -11,14 +11,7 @@
|
||||
#include <rtems/score/thread.h>
|
||||
#include <rtems/score/tod.h>
|
||||
|
||||
/*
|
||||
* Seconds from January 1, 1970 to January 1, 1988. Used to account for
|
||||
* differences between POSIX API and RTEMS core.
|
||||
*/
|
||||
|
||||
#define POSIX_TIME_SECONDS_1970_THROUGH_1988 \
|
||||
(((1987 - 1970 + 1) * TOD_SECONDS_PER_NON_LEAP_YEAR) + \
|
||||
(4 * TOD_SECONDS_PER_DAY))
|
||||
#include <rtems/posix/time.h>
|
||||
|
||||
/*
|
||||
* _POSIX_Time_Spec_to_interval
|
||||
@@ -226,56 +219,6 @@ int clock_getres(
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.2 Create a Per-Process Timer, P1003.1b-1993, p. 264
|
||||
*/
|
||||
|
||||
int timer_create(
|
||||
clockid_t clock_id,
|
||||
struct sigevent *evp,
|
||||
timer_t *timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.3 Delete a Per_process Timer, P1003.1b-1993, p. 266
|
||||
*/
|
||||
|
||||
int timer_delete(
|
||||
timer_t timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_settime(
|
||||
timer_t timerid,
|
||||
int flags,
|
||||
const struct itimerspec *value,
|
||||
struct itimerspec *ovalue
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_gettime(
|
||||
timer_t timerid,
|
||||
struct itimerspec *value
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
75
cpukit/posix/src/ptimer.c
Normal file
75
cpukit/posix/src/ptimer.c
Normal file
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <time.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include <rtems/system.h>
|
||||
#include <rtems/score/isr.h>
|
||||
#include <rtems/score/thread.h>
|
||||
#include <rtems/score/tod.h>
|
||||
|
||||
#include <rtems/posix/time.h>
|
||||
|
||||
/*
|
||||
* 14.2.2 Create a Per-Process Timer, P1003.1b-1993, p. 264
|
||||
*/
|
||||
|
||||
int timer_create(
|
||||
clockid_t clock_id,
|
||||
struct sigevent *evp,
|
||||
timer_t *timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.3 Delete a Per_process Timer, P1003.1b-1993, p. 266
|
||||
*/
|
||||
|
||||
int timer_delete(
|
||||
timer_t timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_settime(
|
||||
timer_t timerid,
|
||||
int flags,
|
||||
const struct itimerspec *value,
|
||||
struct itimerspec *ovalue
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_gettime(
|
||||
timer_t timerid,
|
||||
struct itimerspec *value
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_getoverrun(
|
||||
timer_t timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
@@ -11,14 +11,7 @@
|
||||
#include <rtems/score/thread.h>
|
||||
#include <rtems/score/tod.h>
|
||||
|
||||
/*
|
||||
* Seconds from January 1, 1970 to January 1, 1988. Used to account for
|
||||
* differences between POSIX API and RTEMS core.
|
||||
*/
|
||||
|
||||
#define POSIX_TIME_SECONDS_1970_THROUGH_1988 \
|
||||
(((1987 - 1970 + 1) * TOD_SECONDS_PER_NON_LEAP_YEAR) + \
|
||||
(4 * TOD_SECONDS_PER_DAY))
|
||||
#include <rtems/posix/time.h>
|
||||
|
||||
/*
|
||||
* _POSIX_Time_Spec_to_interval
|
||||
@@ -226,56 +219,6 @@ int clock_getres(
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.2 Create a Per-Process Timer, P1003.1b-1993, p. 264
|
||||
*/
|
||||
|
||||
int timer_create(
|
||||
clockid_t clock_id,
|
||||
struct sigevent *evp,
|
||||
timer_t *timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.3 Delete a Per_process Timer, P1003.1b-1993, p. 266
|
||||
*/
|
||||
|
||||
int timer_delete(
|
||||
timer_t timerid
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_settime(
|
||||
timer_t timerid,
|
||||
int flags,
|
||||
const struct itimerspec *value,
|
||||
struct itimerspec *ovalue
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
int timer_gettime(
|
||||
timer_t timerid,
|
||||
struct itimerspec *value
|
||||
)
|
||||
{
|
||||
return POSIX_NOT_IMPLEMENTED();
|
||||
}
|
||||
|
||||
/*
|
||||
* 14.2.4 Per-Process Timers, P1003.1b-1993, p. 267
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user