source: rtems/cpukit/posix/include/rtems/posix/time.h @ 812da54

4.104.114.84.95
Last change on this file since 812da54 was 812da54, checked in by Joel Sherrill <joel.sherrill@…>, on 04/02/07 at 18:23:59

2007-04-02 Joel Sherrill <joel@…>

  • itron/src/itrontime.c, libcsupport/src/gettod.c, posix/include/rtems/posix/time.h, posix/include/rtems/posix/timer.h, posix/src/clockgettime.c, posix/src/clocksettime.c, posix/src/nanosleep.c, posix/src/posixtimespecsubtract.c, posix/src/posixtimespectointerval.c, posix/src/ptimer1.c, posix/src/sleep.c, rtems/Makefile.am, rtems/include/rtems/rtems/clock.h, rtems/include/rtems/rtems/timer.h, rtems/include/rtems/rtems/types.h, rtems/src/clockget.c, rtems/src/clockset.c, rtems/src/clocktodtoseconds.c, rtems/src/clocktodvalidate.c, rtems/src/taskwakewhen.c, score/Makefile.am, score/include/rtems/score/tod.h, score/inline/rtems/score/tod.inl, score/src/coretod.c, score/src/coretodset.c: Convert from Classic API style TOD_Control as fundamental time structure to POSIX struct timespec. Add clock_get_uptime().
  • rtems/src/clockgetuptime.c, score/src/coretodget.c, score/src/coretodgetuptime.c: New files.
  • score/src/coretodtickle.c, score/src/coretodtoseconds.c, score/src/coretodvalidate.c: Removed.
  • Property mode set to 100644
File size: 1.0 KB
Line 
1/**
2 * @file rtems/posix/time.h
3 */
4
5/*
6 *
7 *
8 *  $Id$
9 */
10
11#ifndef _RTEMS_POSIX_TIME_H
12#define _RTEMS_POSIX_TIME_H
13
14#include <rtems/score/tod.h>
15
16/*
17 *  Seconds from January 1, 1970 to January 1, 1988.  Used to account for
18 *  differences between POSIX API and RTEMS core.
19 *
20 *  XXX probably able to be removed once core switches completely to timespec
21 *  XXX for current TOD.
22 */
23#define POSIX_TIME_SECONDS_1970_THROUGH_1988 TOD_SECONDS_1970_THROUGH_1988
24
25/*
26 *  _POSIX_Timespec_subtract
27 */
28
29void _POSIX_Timespec_subtract(
30  const struct timespec *the_start,
31  const struct timespec *end,
32  struct timespec *result
33);
34
35/*
36 *  _POSIX_Timespec_to_interval
37 */
38
39Watchdog_Interval _POSIX_Timespec_to_interval(
40  const struct timespec *time
41);
42
43/*
44 *  _POSIX_Interval_to_timespec
45 */
46
47void _POSIX_Interval_to_timespec(
48  Watchdog_Interval  ticks,
49  struct timespec   *time
50);
51
52/*
53 *  _POSIX_Absolute_timeout_to_ticks
54 */
55int _POSIX_Absolute_timeout_to_ticks(
56  const struct timespec *abstime,
57  Watchdog_Interval     *ticks_out
58);
59
60#endif
Note: See TracBrowser for help on using the repository browser.