---
name: "rt_task_make_periodic"
section: "2"
platform: "linux"
package: "rtlinux-doc"
version: "1.0-2"
release: "Debian 3.0 (Woody)"
platforms: ["linux"]
url: "https://new.carta.tech/rt_task_make_periodic"
---

# rt\_task\_make\_periodic(2)

mark a real-time task for execution

## NAME

rt\_task\_make\_periodic - mark a real-time task for execution

## SYNOPSIS

```
#define MODULE
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/version.h>
#include <linux/errno.h>
#include <linux/rt_sched.h>
```

**int rt\_task\_make\_periodic(RT\_TASK \*** *task***, RTIME** *start\_time***, RTIME** *period***);**

## DESCRIPTION

**rt\_task\_make\_periodic** marks a task, previously created with a call to  **rt\_task\_init**, as ready for execution.  The task will run at intervals specified by *period*; i.e., it will be marked for execution every *period* real-time clock ticks.  The desired start time is specified by *start\_time*; the first execution of the task will occur *start\_time* clock ticks from the current time.  If immediate execution is desired, the return value of  **rt\_get\_time** can be used for *start\_time*.

## RETURN VALUE

On success, 0 is returned.  On failure, a negative value is returned as described below.

## ERRORS

- **-EINVAL**

  *task* does not refer to a valid RT\_TASK structure.

## SEE ALSO

[**rt\_get\_time**(2)](/rt_get_time/2.md), [**rt\_task\_delete**(2)](/rt_task_delete/2.md), [**rt\_task\_init**(2)](/rt_task_init/2.md), [**rt\_task\_suspend**(2)](/rt_task_suspend/2.md), [**rt\_task\_wait**(2)](/rt_task_wait/2.md)

## AUTHOR

This manual page was written by Jerry Epplin.

Copyright (C) 1997 Jerry Epplin, placed under the GNU General Public License, see the file copyright for details.
