<?xml version='1.0' encoding='UTF-8' standalone='no'?> <doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.8.16"> <compounddef id="sem_8h" kind="file" language="C++"> <compoundname>sem.h</compoundname> <includes refid="include_2sys_2types_8h" local="no">sys/types.h</includes> <includes refid="ubixos_2errno_8h" local="no">ubixos/errno.h</includes> <includes refid="ubthread_8h" local="no">ubixos/ubthread.h</includes> <includedby refid="sys__arch_8h" local="no">C:/Dev/git/UbixOS/sys/include/net/arch/sys_arch.h</includedby> <includedby refid="sem_8c" local="no">C:/Dev/git/UbixOS/sys/kernel/sem.c</includedby> <includedby refid="core_2init_8c" local="no">C:/Dev/git/UbixOS/sys/net/core/init.c</includedby> <includedby refid="net_2init_8c" local="no">C:/Dev/git/UbixOS/sys/net/net/init.c</includedby> <includedby refid="sys__arch_8c" local="no">C:/Dev/git/UbixOS/sys/net/net/sys_arch.c</includedby> <incdepgraph> <node id="23"> <label>ufs/ufs.h</label> <link refid="ufs_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="24" relation="include"> </childnode> </node> <node id="1"> <label>C:/Dev/git/UbixOS/sys/include/ubixos/sem.h</label> <link refid="sem_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="9" relation="include"> </childnode> <childnode refid="10" relation="include"> </childnode> </node> <node id="27"> <label>sys/tss.h</label> <link refid="tss_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="29"> <label>sys/io.h</label> <link refid="io_8h"/> </node> <node id="9"> <label>ubixos/errno.h</label> <link refid="ubixos_2errno_8h"/> </node> <node id="26"> <label>ubixos/tty.h</label> <link refid="tty_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="16"> <label>i386/cpu.h</label> <link refid="i386_2cpu_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="4"> <label>sys/select.h</label> <link refid="select_8h"/> <childnode refid="5" relation="include"> </childnode> <childnode refid="3" relation="include"> </childnode> <childnode refid="6" relation="include"> </childnode> <childnode refid="7" relation="include"> </childnode> <childnode refid="8" relation="include"> </childnode> </node> <node id="19"> <label>vfs/inode.h</label> <link refid="inode_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="20" relation="include"> </childnode> <childnode refid="21" relation="include"> </childnode> <childnode refid="22" relation="include"> </childnode> <childnode refid="23" relation="include"> </childnode> </node> <node id="10"> <label>ubixos/ubthread.h</label> <link refid="ubthread_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="11" relation="include"> </childnode> <childnode refid="28" relation="include"> </childnode> </node> <node id="8"> <label>sys/_sigset.h</label> <link refid="__sigset_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="25"> <label>vfs/mount.h</label> <link refid="mount_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="18"> <label>sys/resource.h</label> <link refid="resource_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="15"> <label>sys/trap.h</label> <link refid="trap_8h"/> <childnode refid="16" relation="include"> </childnode> </node> <node id="2"> <label>sys/types.h</label> <link refid="include_2sys_2types_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="4" relation="include"> </childnode> </node> <node id="12"> <label>vfs/file.h</label> <link refid="include_2vfs_2file_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="13" relation="include"> </childnode> <childnode refid="14" relation="include"> </childnode> <childnode refid="19" relation="include"> </childnode> <childnode refid="25" relation="include"> </childnode> <childnode refid="23" relation="include"> </childnode> </node> <node id="22"> <label>fs/msdos_fs.h</label> <link refid="msdos__fs_8h"/> </node> <node id="17"> <label>sys/signal.h</label> <link refid="sys_2signal_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="21"> <label>fs/pipe_fs.h</label> <link refid="pipe__fs_8h"/> </node> <node id="20"> <label>ubixos/wait.h</label> <link refid="wait_8h"/> </node> <node id="14"> <label>sys/thread.h</label> <link refid="thread_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="15" relation="include"> </childnode> <childnode refid="17" relation="include"> </childnode> <childnode refid="18" relation="include"> </childnode> </node> <node id="5"> <label>sys/cdefs.h</label> <link refid="cdefs_8h"/> </node> <node id="28"> <label>ubixos/time.h</label> <link refid="time_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="6" relation="include"> </childnode> <childnode refid="29" relation="include"> </childnode> </node> <node id="11"> <label>ubixos/sched.h</label> <link refid="sched_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="12" relation="include"> </childnode> <childnode refid="26" relation="include"> </childnode> <childnode refid="27" relation="include"> </childnode> <childnode refid="14" relation="include"> </childnode> </node> <node id="3"> <label>sys/_types.h</label> <link refid="__types_8h"/> </node> <node id="6"> <label>sys/_timespec.h</label> <link refid="__timespec_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="24"> <label>sys/device.h</label> <link refid="include_2sys_2device_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="13"> <label>ubixfs/dirCache.h</label> <link refid="dirCache_8h"/> <childnode refid="2" relation="include"> </childnode> </node> <node id="7"> <label>sys/_timeval.h</label> <link refid="__timeval_8h"/> <childnode refid="3" relation="include"> </childnode> </node> </incdepgraph> <invincdepgraph> <node id="19"> <label>C:/Dev/git/UbixOS/sys/net/net/udpecho.c</label> <link refid="udpecho_8c"/> </node> <node id="1"> <label>C:/Dev/git/UbixOS/sys/include/ubixos/sem.h</label> <link refid="sem_8h"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="20" relation="include"> </childnode> <childnode refid="12" relation="include"> </childnode> <childnode refid="10" relation="include"> </childnode> <childnode refid="18" relation="include"> </childnode> </node> <node id="14"> <label>C:/Dev/git/UbixOS/sys/net/core/mem.c</label> <link refid="mem_8c"/> </node> <node id="5"> <label>C:/Dev/git/UbixOS/sys/net/api/tcpip.c</label> <link refid="tcpip_8c"/> </node> <node id="3"> <label>C:/Dev/git/UbixOS/sys/include/net/sys.h</label> <link refid="sys_8h"/> <childnode refid="4" relation="include"> </childnode> <childnode refid="8" relation="include"> </childnode> <childnode refid="13" relation="include"> </childnode> <childnode refid="5" relation="include"> </childnode> <childnode refid="12" relation="include"> </childnode> <childnode refid="14" relation="include"> </childnode> <childnode refid="6" relation="include"> </childnode> <childnode refid="15" relation="include"> </childnode> <childnode refid="16" relation="include"> </childnode> <childnode refid="17" relation="include"> </childnode> <childnode refid="7" relation="include"> </childnode> <childnode refid="10" relation="include"> </childnode> <childnode refid="18" relation="include"> </childnode> <childnode refid="19" relation="include"> </childnode> </node> <node id="8"> <label>C:/Dev/git/UbixOS/sys/include/net/timeouts.h</label> <link refid="timeouts_8h"/> <childnode refid="4" relation="include"> </childnode> <childnode refid="9" relation="include"> </childnode> <childnode refid="12" relation="include"> </childnode> <childnode refid="6" relation="include"> </childnode> <childnode refid="7" relation="include"> </childnode> </node> <node id="18"> <label>C:/Dev/git/UbixOS/sys/net/net/sys_arch.c</label> <link refid="sys__arch_8c"/> </node> <node id="13"> <label>C:/Dev/git/UbixOS/sys/net/api/err.c</label> <link refid="err_8c"/> </node> <node id="4"> <label>C:/Dev/git/UbixOS/sys/include/net/priv/tcpip_priv.h</label> <link refid="tcpip__priv_8h"/> <childnode refid="5" relation="include"> </childnode> <childnode refid="6" relation="include"> </childnode> <childnode refid="7" relation="include"> </childnode> </node> <node id="20"> <label>C:/Dev/git/UbixOS/sys/kernel/sem.c</label> <link refid="sem_8c"/> </node> <node id="2"> <label>C:/Dev/git/UbixOS/sys/include/net/arch/sys_arch.h</label> <link refid="sys__arch_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="18" relation="include"> </childnode> </node> <node id="17"> <label>C:/Dev/git/UbixOS/sys/net/core/sys.c</label> <link refid="sys_8c"/> </node> <node id="12"> <label>C:/Dev/git/UbixOS/sys/net/core/init.c</label> <link refid="core_2init_8c"/> </node> <node id="9"> <label>C:/Dev/git/UbixOS/sys/include/net/tcpip.h</label> <link refid="tcpip_8h"/> <childnode refid="4" relation="include"> </childnode> <childnode refid="10" relation="include"> </childnode> <childnode refid="11" relation="include"> </childnode> </node> <node id="11"> <label>C:/Dev/git/UbixOS/sys/net/netif/ethernetif.c</label> <link refid="ethernetif_8c"/> </node> <node id="15"> <label>C:/Dev/git/UbixOS/sys/net/core/netif.c</label> <link refid="netif_8c"/> </node> <node id="6"> <label>C:/Dev/git/UbixOS/sys/net/core/memp.c</label> <link refid="memp_8c"/> </node> <node id="7"> <label>C:/Dev/git/UbixOS/sys/net/core/timeouts.c</label> <link refid="timeouts_8c"/> </node> <node id="16"> <label>C:/Dev/git/UbixOS/sys/net/core/pbuf.c</label> <link refid="pbuf_8c"/> </node> <node id="10"> <label>C:/Dev/git/UbixOS/sys/net/net/init.c</label> <link refid="net_2init_8c"/> </node> </invincdepgraph> <innerclass refid="structsys__sem" prot="public">sys_sem</innerclass> <sectiondef kind="typedef"> <memberdef kind="typedef" id="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" prot="public" static="no"> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <definition>typedef uint32_t semID_t</definition> <argsstring></argsstring> <name>semID_t</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="44" column="18" bodyfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" bodystart="44" bodyend="-1"/> </memberdef> <memberdef kind="typedef" id="sem_8h_1a900e36da93bb688c29fc8148f2f44e04" prot="public" static="no"> <type>struct <ref refid="structsys__sem" kindref="compound">sys_sem</ref></type> <definition>typedef struct sys_sem sys_sem_t</definition> <argsstring></argsstring> <name>sys_sem_t</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="82" column="20" bodyfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" bodystart="42" bodyend="-1"/> </memberdef> </sectiondef> <sectiondef kind="func"> <memberdef kind="function" id="sem_8h_1a31ab8f6dbb9646ed62f5e836b3639ad1" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_close</definition> <argsstring>(semID_t id)</argsstring> <name>sem_close</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref></type> <declname>id</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="47" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="36" bodyend="38" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="47" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1adcce987e1dbe6b3740a4b8f1a49c680f" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_destroy</definition> <argsstring>(sys_sem_t **)</argsstring> <name>sem_destroy</name> <param> <type><ref refid="sem_8h_1a900e36da93bb688c29fc8148f2f44e04" kindref="member">sys_sem_t</ref> **</type> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="56" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="87" bodyend="100" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="56" declcolumn="5"/> <references refid="structsys__sem_1aa758e52262d23c22a40204e410b5f8c4" compoundref="sem_8h" startline="38">sys_sem::cond</references> <references refid="sys_2errno_8h_1a2d1678d5a7cc8ce499643f3b8957def4" compoundref="sys_2errno_8h" startline="55">EINVAL</references> <references refid="ubixos_2errno_8h_1a019daba146137ec289f49606cc1552fc" compoundref="ubixos_2errno_8h" startline="36">ENOERR</references> <references refid="kmalloc_8h_1aaa9ed6886459604cf73ccdbf6410e487" compoundref="kmalloc_8c" startline="342" endline="382">kfree</references> <references refid="structsys__sem_1a52b664ee7d03d9bc83f26009a5fd27f1" compoundref="sem_8h" startline="39">sys_sem::mutex</references> <references refid="fat__string_8h_1a070d2ce7b6bb7e5c05602aa8c308d0c4" compoundref="fat__string_8h" startline="17">NULL</references> <references refid="ubthread_8h_1ae914fae69538736dc5e494c15ce93a17" compoundref="ubthread_8c" startline="71" endline="75">ubthread_cond_destroy</references> <references refid="ubthread_8h_1a278f5d5b1e11b6668b75da6a285442e4" compoundref="ubthread_8c" startline="77" endline="81">ubthread_mutex_destroy</references> <referencedby refid="group__sys__sem_1ga4d02e29e5dfa092559efc04dee985822" compoundref="sys__arch_8c" startline="75" endline="86">sys_sem_free</referencedby> </memberdef> <memberdef kind="function" id="sem_8h_1ab80213da2384984db11eeae2c92f8a72" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_getvalue</definition> <argsstring>(semID_t id, int *val)</argsstring> <name>sem_getvalue</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref></type> <declname>id</declname> </param> <param> <type>int *</type> <declname>val</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="55" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="83" bodyend="85" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="55" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1a741be298cbcc3eab1747e8b9b239d5f0" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_init</definition> <argsstring>(sys_sem_t **, uint8_t)</argsstring> <name>sem_init</name> <param> <type><ref refid="sem_8h_1a900e36da93bb688c29fc8148f2f44e04" kindref="member">sys_sem_t</ref> **</type> </param> <param> <type><ref refid="include_2sys_2types_8h_1a2aff71146ab4942b2b38860c749c4074" kindref="member">uint8_t</ref></type> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="52" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="56" bodyend="73" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="52" declcolumn="5"/> <references refid="structsys__sem_1aa758e52262d23c22a40204e410b5f8c4" compoundref="sem_8h" startline="38">sys_sem::cond</references> <references refid="ubixos_2errno_8h_1a019daba146137ec289f49606cc1552fc" compoundref="ubixos_2errno_8h" startline="36">ENOERR</references> <references refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" compoundref="kmalloc_8c" startline="241" endline="331">kmalloc</references> <references refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" compoundref="kprintf_8c" startline="259" endline="276">kprintf</references> <references refid="structsys__sem_1a52b664ee7d03d9bc83f26009a5fd27f1" compoundref="sem_8h" startline="39">sys_sem::mutex</references> <references refid="fat__string_8h_1a070d2ce7b6bb7e5c05602aa8c308d0c4" compoundref="fat__string_8h" startline="17">NULL</references> <references refid="structsys__sem_1ab9e4ecb1c4448468fb820025b7c773be" compoundref="sem_8h" startline="37">sys_sem::signaled</references> <references refid="ubthread_8h_1acbb7170a68758468ab5b02512a320112">ubthread_cond_init</references> <references refid="ubthread_8h_1ab6bfc2169b55532821582f24b68dc855">ubthread_mutex_init</references> <referencedby refid="group__sys__sem_1gadb68acad14b34550b9891bc11bbf4e63" compoundref="sys__arch_8c" startline="52" endline="72">sys_sem_new</referencedby> </memberdef> <memberdef kind="function" id="sem_8h_1a15c1835612c234029c20431e06a1917d" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_open</definition> <argsstring>(semID_t *id, const char *name, int oflag, mode_t mode, unsigned int value)</argsstring> <name>sem_open</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref> *</type> <declname>id</declname> </param> <param> <type><ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref> char *</type> <declname>name</declname> </param> <param> <type>int</type> <declname>oflag</declname> </param> <param> <type><ref refid="descrip_8h_1ae9f148ba55d84268ecb6f8031ab45076" kindref="member">mode_t</ref></type> <declname>mode</declname> </param> <param> <type>unsigned int</type> <declname>value</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="53" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="75" bodyend="77" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="53" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1a81988406ac7a65ee7d6782b97943320e" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_post</definition> <argsstring>(semID_t id)</argsstring> <name>sem_post</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref></type> <declname>id</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="48" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="40" bodyend="42" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="48" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1a225cd49daf55aa5df66d4382750abd41" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_timedwait</definition> <argsstring>(semID_t id, const struct timespec *)</argsstring> <name>sem_timedwait</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref></type> <declname>id</declname> </param> <param> <type><ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref> struct <ref refid="structtimespec" kindref="compound">timespec</ref> *</type> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="51" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="52" bodyend="54" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="51" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1a46c76cc20324278bddf93b50c6f7ae9f" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_trywait</definition> <argsstring>(semID_t id)</argsstring> <name>sem_trywait</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref></type> <declname>id</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="50" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="48" bodyend="50" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="50" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1a776256d1a473906f8b7490689bfcb75c" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_unlink</definition> <argsstring>(const char *name)</argsstring> <name>sem_unlink</name> <param> <type><ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref> char *</type> <declname>name</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="54" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="79" bodyend="81" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="54" declcolumn="5"/> </memberdef> <memberdef kind="function" id="sem_8h_1ac2e22218e6a5830f6bdfd727d0206798" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int sem_wait</definition> <argsstring>(semID_t id)</argsstring> <name>sem_wait</name> <param> <type><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref></type> <declname>id</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" line="49" column="5" bodyfile="C:/Dev/git/UbixOS/sys/kernel/sem.c" bodystart="44" bodyend="46" declfile="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h" declline="49" declcolumn="5"/> </memberdef> </sectiondef> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <programlisting> <codeline lineno="1"><highlight class="comment">/*-</highlight></codeline> <codeline lineno="2"><highlight class="comment"><sp/>*<sp/>Copyright<sp/>(c)<sp/>2002-2018<sp/>The<sp/>UbixOS<sp/>Project.</highlight></codeline> <codeline lineno="3"><highlight class="comment"><sp/>*<sp/>All<sp/>rights<sp/>reserved.</highlight></codeline> <codeline lineno="4"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="5"><highlight class="comment"><sp/>*<sp/>This<sp/>was<sp/>developed<sp/>by<sp/>Christopher<sp/>W.<sp/>Olsen<sp/>for<sp/>the<sp/>UbixOS<sp/>Project.</highlight></codeline> <codeline lineno="6"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="7"><highlight class="comment"><sp/>*<sp/>Redistribution<sp/>and<sp/>use<sp/>in<sp/>source<sp/>and<sp/>binary<sp/>forms,<sp/>with<sp/>or<sp/>without<sp/>modification,<sp/>are<sp/>permitted</highlight></codeline> <codeline lineno="8"><highlight class="comment"><sp/>*<sp/>provided<sp/>that<sp/>the<sp/>following<sp/>conditions<sp/>are<sp/>met:</highlight></codeline> <codeline lineno="9"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="10"><highlight class="comment"><sp/>*<sp/>1)<sp/>Redistributions<sp/>of<sp/>source<sp/>code<sp/>must<sp/>retain<sp/>the<sp/>above<sp/>copyright<sp/>notice,<sp/>this<sp/>list<sp/>of</highlight></codeline> <codeline lineno="11"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>conditions,<sp/>the<sp/>following<sp/>disclaimer<sp/>and<sp/>the<sp/>list<sp/>of<sp/>authors.</highlight></codeline> <codeline lineno="12"><highlight class="comment"><sp/>*<sp/>2)<sp/>Redistributions<sp/>in<sp/>binary<sp/>form<sp/>must<sp/>reproduce<sp/>the<sp/>above<sp/>copyright<sp/>notice,<sp/>this<sp/>list<sp/>of</highlight></codeline> <codeline lineno="13"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>conditions,<sp/>the<sp/>following<sp/>disclaimer<sp/>and<sp/>the<sp/>list<sp/>of<sp/>authors<sp/>in<sp/>the<sp/>documentation<sp/>and/or</highlight></codeline> <codeline lineno="14"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>other<sp/>materials<sp/>provided<sp/>with<sp/>the<sp/>distribution.</highlight></codeline> <codeline lineno="15"><highlight class="comment"><sp/>*<sp/>3)<sp/>Neither<sp/>the<sp/>name<sp/>of<sp/>the<sp/>UbixOS<sp/>Project<sp/>nor<sp/>the<sp/>names<sp/>of<sp/>its<sp/>contributors<sp/>may<sp/>be<sp/>used<sp/>to</highlight></codeline> <codeline lineno="16"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>endorse<sp/>or<sp/>promote<sp/>products<sp/>derived<sp/>from<sp/>this<sp/>software<sp/>without<sp/>specific<sp/>prior<sp/>written</highlight></codeline> <codeline lineno="17"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>permission.</highlight></codeline> <codeline lineno="18"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="19"><highlight class="comment"><sp/>*<sp/>THIS<sp/>SOFTWARE<sp/>IS<sp/>PROVIDED<sp/>BY<sp/>THE<sp/>AUTHOR<sp/>AND<sp/>CONTRIBUTORS<sp/>"AS<sp/>IS"<sp/>AND<sp/>ANY<sp/>EXPRESS<sp/>OR<sp/>IMPLIED</highlight></codeline> <codeline lineno="20"><highlight class="comment"><sp/>*<sp/>WARRANTIES,<sp/>INCLUDING,<sp/>BUT<sp/>NOT<sp/>LIMITED<sp/>TO,<sp/>THE<sp/>IMPLIED<sp/>WARRANTIES<sp/>OF<sp/>MERCHANTABILITY<sp/>AND<sp/>FITNESS</highlight></codeline> <codeline lineno="21"><highlight class="comment"><sp/>*<sp/>FOR<sp/>A<sp/>PARTICULAR<sp/>PURPOSE<sp/>ARE<sp/>DISCLAIMED.<sp/>IN<sp/>NO<sp/>EVENT<sp/>SHALL<sp/>THE<sp/>COPYRIGHT<sp/>OWNER<sp/>OR<sp/>CONTRIBUTORS</highlight></codeline> <codeline lineno="22"><highlight class="comment"><sp/>*<sp/>BE<sp/>LIABLE<sp/>FOR<sp/>ANY<sp/>DIRECT,<sp/>INDIRECT,<sp/>INCIDENTAL,<sp/>SPECIAL,<sp/>EXEMPLARY,<sp/>OR<sp/>CONSEQUENTIAL<sp/>DAMAGES</highlight></codeline> <codeline lineno="23"><highlight class="comment"><sp/>*<sp/>(INCLUDING,<sp/>BUT<sp/>NOT<sp/>LIMITED<sp/>TO,<sp/>PROCUREMENT<sp/>OF<sp/>SUBSTITUTE<sp/>GOODS<sp/>OR<sp/>SERVICES;<sp/>LOSS<sp/>OF<sp/>USE,<sp/>DATA,</highlight></codeline> <codeline lineno="24"><highlight class="comment"><sp/>*<sp/>OR<sp/>PROFITS;<sp/>OR<sp/>BUSINESS<sp/>INTERRUPTION)<sp/>HOWEVER<sp/>CAUSED<sp/>AND<sp/>ON<sp/>ANY<sp/>THEORY<sp/>OF<sp/>LIABILITY,<sp/>WHETHER<sp/>IN</highlight></codeline> <codeline lineno="25"><highlight class="comment"><sp/>*<sp/>CONTRACT,<sp/>STRICT<sp/>LIABILITY,<sp/>OR<sp/>TORT<sp/>(INCLUDING<sp/>NEGLIGENCE<sp/>OR<sp/>OTHERWISE)<sp/>ARISING<sp/>IN<sp/>ANY<sp/>WAY<sp/>OUT</highlight></codeline> <codeline lineno="26"><highlight class="comment"><sp/>*<sp/>OF<sp/>THE<sp/>USE<sp/>OF<sp/>THIS<sp/>SOFTWARE,<sp/>EVEN<sp/>IF<sp/>ADVISED<sp/>OF<sp/>THE<sp/>POSSIBILITY<sp/>OF<sp/>SUCH<sp/>DAMAGE.</highlight></codeline> <codeline lineno="27"><highlight class="comment"><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="28"><highlight class="normal"></highlight></codeline> <codeline lineno="29"><highlight class="normal"></highlight><highlight class="preprocessor">#ifndef<sp/>_UBIXOS_SEM_H</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="30"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>_UBIXOS_SEM_H</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="31"><highlight class="normal"></highlight></codeline> <codeline lineno="32"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="include_2sys_2types_8h" kindref="compound">sys/types.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="33"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="ubixos_2errno_8h" kindref="compound">ubixos/errno.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="34"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="ubthread_8h" kindref="compound">ubixos/ubthread.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="35"><highlight class="normal"></highlight></codeline> <codeline lineno="36" refid="structsys__sem" refkind="compound"><highlight class="normal"></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structsys__sem" kindref="compound">sys_sem</ref><sp/>{</highlight></codeline> <codeline lineno="37" refid="structsys__sem_1ab9e4ecb1c4448468fb820025b7c773be" refkind="member"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/><ref refid="structsys__sem_1ab9e4ecb1c4448468fb820025b7c773be" kindref="member">signaled</ref>;</highlight></codeline> <codeline lineno="38" refid="structsys__sem_1aa758e52262d23c22a40204e410b5f8c4" refkind="member"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structubthread__cond" kindref="compound">ubthread_cond_t</ref><sp/><ref refid="structsys__sem_1aa758e52262d23c22a40204e410b5f8c4" kindref="member">cond</ref>;</highlight></codeline> <codeline lineno="39" refid="structsys__sem_1a52b664ee7d03d9bc83f26009a5fd27f1" refkind="member"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structubthread__mutex" kindref="compound">ubthread_mutex_t</ref><sp/><ref refid="structsys__sem_1a52b664ee7d03d9bc83f26009a5fd27f1" kindref="member">mutex</ref>;</highlight></codeline> <codeline lineno="40"><highlight class="normal">};</highlight></codeline> <codeline lineno="41"><highlight class="normal"></highlight></codeline> <codeline lineno="42" refid="sem_8h_1a900e36da93bb688c29fc8148f2f44e04" refkind="member"><highlight class="normal"></highlight><highlight class="keyword">typedef</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structsys__sem" kindref="compound">sys_sem</ref><sp/><ref refid="structsys__sem" kindref="compound">sys_sem_t</ref>;</highlight></codeline> <codeline lineno="43"><highlight class="normal"></highlight></codeline> <codeline lineno="44" refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" refkind="member"><highlight class="normal"></highlight><highlight class="keyword">typedef</highlight><highlight class="normal"><sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/><ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref>;</highlight></codeline> <codeline lineno="45"><highlight class="normal"></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structtimespec" kindref="compound">timespec</ref>;</highlight></codeline> <codeline lineno="46"><highlight class="normal"></highlight></codeline> <codeline lineno="47"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a31ab8f6dbb9646ed62f5e836b3639ad1" kindref="member">sem_close</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/></highlight><highlight class="keywordtype">id</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="48"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a81988406ac7a65ee7d6782b97943320e" kindref="member">sem_post</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/></highlight><highlight class="keywordtype">id</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="49"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1ac2e22218e6a5830f6bdfd727d0206798" kindref="member">sem_wait</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/></highlight><highlight class="keywordtype">id</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="50"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a46c76cc20324278bddf93b50c6f7ae9f" kindref="member">sem_trywait</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/></highlight><highlight class="keywordtype">id</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="51"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a225cd49daf55aa5df66d4382750abd41" kindref="member">sem_timedwait</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/></highlight><highlight class="keywordtype">id</highlight><highlight class="normal">,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structtimespec" kindref="compound">timespec</ref><sp/>*);</highlight></codeline> <codeline lineno="52"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a741be298cbcc3eab1747e8b9b239d5f0" kindref="member">sem_init</ref>(<ref refid="structsys__sem" kindref="compound">sys_sem_t</ref><sp/>**,<sp/><ref refid="include_2sys_2types_8h_1a2aff71146ab4942b2b38860c749c4074" kindref="member">uint8_t</ref>);</highlight></codeline> <codeline lineno="53"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a15c1835612c234029c20431e06a1917d" kindref="member">sem_open</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/>*</highlight><highlight class="keywordtype">id</highlight><highlight class="normal">,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<ref refid="pci_8c_1a8f8f80d37794cde9472343e4487ba3eb" kindref="member">name</ref>,<sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>oflag,<sp/><ref refid="descrip_8h_1ae9f148ba55d84268ecb6f8031ab45076" kindref="member">mode_t</ref><sp/>mode,<sp/></highlight><highlight class="keywordtype">unsigned</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>value);</highlight></codeline> <codeline lineno="54"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1a776256d1a473906f8b7490689bfcb75c" kindref="member">sem_unlink</ref>(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<ref refid="pci_8c_1a8f8f80d37794cde9472343e4487ba3eb" kindref="member">name</ref>);</highlight></codeline> <codeline lineno="55"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1ab80213da2384984db11eeae2c92f8a72" kindref="member">sem_getvalue</ref>(<ref refid="sem_8h_1a9f436a6cc8070df1db63f5a75d4d0014" kindref="member">semID_t</ref><sp/></highlight><highlight class="keywordtype">id</highlight><highlight class="normal">,<sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>*val);</highlight></codeline> <codeline lineno="56"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="sem_8h_1adcce987e1dbe6b3740a4b8f1a49c680f" kindref="member">sem_destroy</ref>(<ref refid="structsys__sem" kindref="compound">sys_sem_t</ref><sp/>**);</highlight></codeline> <codeline lineno="57"><highlight class="normal"></highlight></codeline> <codeline lineno="58"><highlight class="normal"></highlight><highlight class="preprocessor">#endif<sp/></highlight><highlight class="comment">/*<sp/>END<sp/>_UBIXOS_SEM_H<sp/>*/</highlight><highlight class="preprocessor"></highlight></codeline> </programlisting> <location file="C:/Dev/git/UbixOS/sys/include/ubixos/sem.h"/> </compounddef> </doxygen>