Warning: main() [function.main]: open_basedir restriction in effect. File(/var/data/www/ods/ods.com.ua/htdocs/htdig/header.php) is not within the allowed path(s): (/home/ods/:/tmp:/usr/local/lib/php/) in /home/ods/domains/ods.com.ua/public_html/win/eng/unix/lpg/node49.html on line 4
Warning: main(/var/data/www/ods/ods.com.ua/htdocs/htdig/header.php) [function.main]: failed to open stream: Operation not permitted in /home/ods/domains/ods.com.ua/public_html/win/eng/unix/lpg/node49.html on line 4
Warning: main() [function.include]: Failed opening '/var/data/www/ods/ods.com.ua/htdocs/htdig/header.php' for inclusion (include_path='.:/usr/local/lib/php/') in /home/ods/domains/ods.com.ua/public_html/win/eng/unix/lpg/node49.html on line 4
next up previous contents
Next: Kernel sem structure
Up: Internal Data Structures
Previous: Internal Data Structures
As with message queues, the kernel maintains a special internal data structure for each semaphore
set which exists within its addressing space. This structure is of type semid_ds, and
is defined in linux/sem.h as follows:
/* One semid data structure for each
set of semaphores in the system. */
struct semid_ds {
struct ipc_perm sem_perm; /* permissions .. see ipc.h */
time_t sem_otime; /* last semop time */
time_t sem_ctime; /* last change time */
struct sem *sem_base; /* ptr to first semaphore in array */
struct wait_queue *eventn;
struct wait_queue *eventz;
struct sem_undo *undo; /* undo requests on this array */
ushort sem_nsems; /* no. of semaphores in array */
};
As with message queues, operations on this structure are performed by a special system call, and
should not be tinkered with directly. Here are descriptions of the more pertinent fields:
- sem_perm
-
This is an instance of the ipc_perm structure, which is defined
for us in linux/ipc.h. This holds the permission information for
the semaphore set, including the access permissions, and information
about the creator of the set (uid, etc).
- sem_otime
-
Time of the last semop() operation (more on this in a moment)
- sem_ctime
-
Time of the last change to this structure (mode change, etc)
- sem_base
-
Pointer to the first semaphore in the array (see next structure)
- sem_undo
-
Number of undo requests in this array (more on this in a moment)
- sem_nsems
-
Number of semaphores in the semaphore set (the array)
Converted on:
Fri Mar 29 14:43:04 EST 1996
Warning: main() [function.main]: open_basedir restriction in effect. File(/var/data/www/ods/ods.com.ua/htdocs/include/footer.php) is not within the allowed path(s): (/home/ods/:/tmp:/usr/local/lib/php/) in /home/ods/domains/ods.com.ua/public_html/win/eng/unix/lpg/node49.html on line 74
Warning: main(/var/data/www/ods/ods.com.ua/htdocs/include/footer.php) [function.main]: failed to open stream: Operation not permitted in /home/ods/domains/ods.com.ua/public_html/win/eng/unix/lpg/node49.html on line 74
Warning: main() [function.include]: Failed opening '/var/data/www/ods/ods.com.ua/htdocs/include/footer.php' for inclusion (include_path='.:/usr/local/lib/php/') in /home/ods/domains/ods.com.ua/public_html/win/eng/unix/lpg/node49.html on line 74