|
RocketLogger
1.1.4
|
Include dependency graph for sem.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Macros | |
| #define | _GNU_SOURCE |
Functions | |
| int | create_sem (key_t key, int num_sems) |
| int | remove_sem (int sem_id) |
| int | open_sem (key_t key, int num_sems) |
| int | wait_sem (int sem_id, int sem_num, int time_out) |
| int | set_sem (int sem_id, int sem_num, int val) |
| #define _GNU_SOURCE |
Copyright (c) 2016-2018, Swiss Federal Institute of Technology (ETH Zurich) All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
| int create_sem | ( | key_t | key, |
| int | num_sems | ||
| ) |
| int open_sem | ( | key_t | key, |
| int | num_sems | ||
| ) |
| int remove_sem | ( | int | sem_id | ) |
| int set_sem | ( | int | sem_id, |
| int | sem_num, | ||
| int | val | ||
| ) |
Set value to semaphore
| sem_id | ID of semaphore set |
| sem_num | Number of semaphore in set |
| val | Value to be set to semaphore |
Definition at line 124 of file sem.c.
References ERROR, FAILURE, NO_FLAG, rl_log(), SEM_SET_TIME_OUT, SUCCESS, and TIME_OUT.
Referenced by main(), print_data(), pru_sample(), and web_handle_data().
Here is the call graph for this function:| int wait_sem | ( | int | sem_id, |
| int | sem_num, | ||
| int | time_out | ||
| ) |
Wait on a semaphore until access granted
| sem_id | ID of semaphore set |
| sem_num | Number of semaphore in set |
| time_out | Maximum waiting time |
Definition at line 88 of file sem.c.
References ERROR, FAILURE, INFO, NO_FLAG, rl_log(), SUCCESS, TIME_OUT, and WARNING.
Referenced by main(), print_data(), and web_handle_data().
Here is the call graph for this function: