<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>UbixOS V2: src/sys/include/ubixos/spinlock.h File Reference</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> <link href="tabs.css" rel="stylesheet" type="text/css"> </head><body> <!-- Generated by Doxygen 1.4.7 --> <div class="tabs"> <ul> <li><a href="main.html"><span>Main Page</span></a></li> <li><a href="classes.html"><span>Data Structures</span></a></li> <li id="current"><a href="files.html"><span>Files</span></a></li> <li><a href="dirs.html"><span>Directories</span></a></li> <li> <form action="search.php" method="get"> <table cellspacing="0" cellpadding="0" border="0"> <tr> <td><label> <u>S</u>earch for </label></td> <td><input type="text" name="query" value="" size="20" accesskey="s"/></td> </tr> </table> </form> </li> </ul></div> <div class="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul></div> <div class="nav"> <a class="el" href="dir_897b6a2d7bab147dd1db58381aad3984.html">src</a> » <a class="el" href="dir_832905b1f7f5feaf61a306b40c0ac817.html">sys</a> » <a class="el" href="dir_caf4200c438ae9601464168e21e8e4d8.html">include</a> » <a class="el" href="dir_9854bc9d2b9a2a73f32c73e97d31d0f7.html">ubixos</a></div> <h1>spinlock.h File Reference</h1><code>#include <<a class="el" href="types_8h-source.html">ubixos/types.h</a>></code><br> <p> <a href="spinlock_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0"> <tr><td></td></tr> <tr><td colspan="2"><br><h2>Defines</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#0fe85a4f3642683148b25916d6c5eafd">SPIN_LOCK_INITIALIZER</a> 0</td></tr> <tr><td colspan="2"><br><h2>Typedefs</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">typedef volatile int </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a></td></tr> <tr><td colspan="2"><br><h2>Functions</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#2cd9a4502680fb8e7f0fe6b029e558b1">spinLock</a> (<a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> *)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#4a5b56fc59f6a63a4d6cfac573889789">spinLock_scheduler</a> (<a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> *)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#7092f143f66f5cab13a9d49ed42ab4d3">spinLockInit</a> (<a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> *)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#cba75fe5ed894dc88030f7458b114a94">spinLockLocked</a> (<a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> *)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#8f9173fadeddafa01754d6cbcc630198">spinTryLock</a> (<a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> *)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#dd996cbbb3b9826dd9c8cf02b66a4c65">spinUnlock</a> (<a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> *)</td></tr> <tr><td colspan="2"><br><h2>Variables</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="spinlock_8h.html#061103633079320d29a623d5758623b1">Master</a></td></tr> </table> <hr><h2>Define Documentation</h2> <a class="anchor" name="0fe85a4f3642683148b25916d6c5eafd"></a><!-- doxytag: member="spinlock.h::SPIN_LOCK_INITIALIZER" ref="0fe85a4f3642683148b25916d6c5eafd" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">#define SPIN_LOCK_INITIALIZER 0 </td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8h-source.html#l00035">35</a> of file <a class="el" href="spinlock_8h-source.html">spinlock.h</a>. <p> Referenced by <a class="el" href="spinlock_8c-source.html#l00033">spinLockInit()</a>. </div> </div><p> <hr><h2>Typedef Documentation</h2> <a class="anchor" name="a240e9404b4ede1e0d714610080d1176"></a><!-- doxytag: member="spinlock.h::spinLock_t" ref="a240e9404b4ede1e0d714610080d1176" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">typedef volatile int <a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> </td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8h-source.html#l00037">37</a> of file <a class="el" href="spinlock_8h-source.html">spinlock.h</a>. </div> </div><p> <hr><h2>Function Documentation</h2> <a class="anchor" name="2cd9a4502680fb8e7f0fe6b029e558b1"></a><!-- doxytag: member="spinlock.h::spinLock" ref="2cd9a4502680fb8e7f0fe6b029e558b1" args="(spinLock_t *)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void spinLock </td> <td>(</td> <td class="paramtype"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> * </td> <td class="paramname"> </td> <td> ) </td> <td width="100%"></td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8c-source.html#l00056">56</a> of file <a class="el" href="spinlock_8c-source.html">spinlock.c</a>. <p> References <a class="el" href="sched_8c-source.html#l00259">sched_yield()</a>, and <a class="el" href="spinlock_8c-source.html#l00048">spinTryLock()</a>. <p> Referenced by <a class="el" href="vmm__memory_8c-source.html#l00266">adjustCowCounter()</a>, <a class="el" href="smp_8c-source.html#l00182">cpuInfo()</a>, <a class="el" href="sys__arch_8c-source.html#l00135">current_thread()</a>, <a class="el" href="devfs_8c-source.html#l00178">devfs_makeNode()</a>, <a class="el" href="devfs_8c-source.html#l00071">devfs_open()</a>, <a class="el" href="device_8c-source.html#l00051">device_add()</a>, <a class="el" href="device_8c-source.html#l00086">device_find()</a>, <a class="el" href="device_8c-source.html#l00110">device_remove()</a>, <a class="el" href="file_8c-source.html#l00398">fclose()</a>, <a class="el" href="fdc_8c-source.html#l00303">fdcRead()</a>, <a class="el" href="file_8c-source.html#l00274">fopen()</a>, <a class="el" href="vmm__memory_8c-source.html#l00228">freePage()</a>, <a class="el" href="kmalloc_8c-source.html#l00067">getEmptyDesc()</a>, <a class="el" href="smp_8c-source.html#l00123">kernel_function()</a>, <a class="el" href="kmalloc_8c-source.html#l00351">kfree()</a>, <a class="el" href="kmalloc_8c-source.html#l00247">kmalloc()</a>, <a class="el" href="system_8c-source.html#l00069">mpi_createMbox()</a>, <a class="el" href="system_8c-source.html#l00234">mpi_destroyMbox()</a>, <a class="el" href="system_8c-source.html#l00189">mpi_fetchMessage()</a>, <a class="el" href="system_8c-source.html#l00143">mpi_postMessage()</a>, <a class="el" href="system_8c-source.html#l00108">mpi_spam()</a>, <a class="el" href="ne2k_8c-source.html#l00313">ne2kAllocBuffer()</a>, <a class="el" href="sched_8c-source.html#l00143">schedNewTask()</a>, <a class="el" href="smp_8c-source.html#l00161">smpInit()</a>, <a class="el" href="sys__arch_8c-source.html#l00172">sys_thread_new()</a>, <a class="el" href="tty_8c-source.html#l00118">tty_print()</a>, <a class="el" href="dirCache_8c-source.html#l00242">ubixfs_cacheAdd()</a>, <a class="el" href="dirCache_8c-source.html#l00055">ubixfs_cacheFind()</a>, <a class="el" href="paging_8c-source.html#l00401">vmm_getFreeMallocPage()</a>, <a class="el" href="pagefault_8c-source.html#l00053">vmm_pageFault()</a>, <a class="el" href="paging_8c-source.html#l00160">vmm_remapPage()</a>, <a class="el" href="copyvirtualspace_8c-source.html#l00053">vmmCopyVirtualSpace()</a>, <a class="el" href="vmm__memory_8c-source.html#l00186">vmmFindFreePage()</a>, <a class="el" href="vmm__memory_8c-source.html#l00296">vmmFreeProcessPages()</a>, <a class="el" href="paging_8c-source.html#l00253">vmmGetFreeKernelPage()</a>, <a class="el" href="getfreepage_8c-source.html#l00048">vmmGetFreePage()</a>, and <a class="el" href="getfreevirtualpage_8c-source.html#l00047">vmmGetFreeVirtualPage()</a>. </div> </div><p> <a class="anchor" name="4a5b56fc59f6a63a4d6cfac573889789"></a><!-- doxytag: member="spinlock.h::spinLock_scheduler" ref="4a5b56fc59f6a63a4d6cfac573889789" args="(spinLock_t *)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void spinLock_scheduler </td> <td>(</td> <td class="paramtype"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> * </td> <td class="paramname"> </td> <td> ) </td> <td width="100%"></td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8c-source.html#l00064">64</a> of file <a class="el" href="spinlock_8c-source.html">spinlock.c</a>. <p> References <a class="el" href="spinlock_8c-source.html#l00048">spinTryLock()</a>. </div> </div><p> <a class="anchor" name="7092f143f66f5cab13a9d49ed42ab4d3"></a><!-- doxytag: member="spinlock.h::spinLockInit" ref="7092f143f66f5cab13a9d49ed42ab4d3" args="(spinLock_t *)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void spinLockInit </td> <td>(</td> <td class="paramtype"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> * </td> <td class="paramname"> </td> <td> ) </td> <td width="100%"></td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8c-source.html#l00033">33</a> of file <a class="el" href="spinlock_8c-source.html">spinlock.c</a>. <p> References <a class="el" href="spinlock_8h-source.html#l00035">SPIN_LOCK_INITIALIZER</a>. </div> </div><p> <a class="anchor" name="cba75fe5ed894dc88030f7458b114a94"></a><!-- doxytag: member="spinlock.h::spinLockLocked" ref="cba75fe5ed894dc88030f7458b114a94" args="(spinLock_t *)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int spinLockLocked </td> <td>(</td> <td class="paramtype"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> * </td> <td class="paramname"> </td> <td> ) </td> <td width="100%"></td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8c-source.html#l00070">70</a> of file <a class="el" href="spinlock_8c-source.html">spinlock.c</a>. <p> Referenced by <a class="el" href="smp_8c-source.html#l00137">c_ap_boot()</a>. </div> </div><p> <a class="anchor" name="8f9173fadeddafa01754d6cbcc630198"></a><!-- doxytag: member="spinlock.h::spinTryLock" ref="8f9173fadeddafa01754d6cbcc630198" args="(spinLock_t *)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int spinTryLock </td> <td>(</td> <td class="paramtype"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> * </td> <td class="paramname"> </td> <td> ) </td> <td width="100%"></td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8c-source.html#l00048">48</a> of file <a class="el" href="spinlock_8c-source.html">spinlock.c</a>. <p> Referenced by <a class="el" href="atkbd_8c-source.html#l00216">keyboardHandler()</a>, <a class="el" href="sched_8c-source.html#l00084">sched()</a>, <a class="el" href="spinlock_8c-source.html#l00056">spinLock()</a>, and <a class="el" href="spinlock_8c-source.html#l00064">spinLock_scheduler()</a>. </div> </div><p> <a class="anchor" name="dd996cbbb3b9826dd9c8cf02b66a4c65"></a><!-- doxytag: member="spinlock.h::spinUnlock" ref="dd996cbbb3b9826dd9c8cf02b66a4c65" args="(spinLock_t *)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void spinUnlock </td> <td>(</td> <td class="paramtype"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> * </td> <td class="paramname"> </td> <td> ) </td> <td width="100%"></td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="spinlock_8c-source.html#l00037">37</a> of file <a class="el" href="spinlock_8c-source.html">spinlock.c</a>. <p> Referenced by <a class="el" href="vmm__memory_8c-source.html#l00266">adjustCowCounter()</a>, <a class="el" href="smp_8c-source.html#l00182">cpuInfo()</a>, <a class="el" href="sys__arch_8c-source.html#l00135">current_thread()</a>, <a class="el" href="devfs_8c-source.html#l00178">devfs_makeNode()</a>, <a class="el" href="devfs_8c-source.html#l00071">devfs_open()</a>, <a class="el" href="device_8c-source.html#l00051">device_add()</a>, <a class="el" href="device_8c-source.html#l00086">device_find()</a>, <a class="el" href="device_8c-source.html#l00110">device_remove()</a>, <a class="el" href="file_8c-source.html#l00398">fclose()</a>, <a class="el" href="fdc_8c-source.html#l00303">fdcRead()</a>, <a class="el" href="file_8c-source.html#l00274">fopen()</a>, <a class="el" href="vmm__memory_8c-source.html#l00228">freePage()</a>, <a class="el" href="kmalloc_8c-source.html#l00067">getEmptyDesc()</a>, <a class="el" href="smp_8c-source.html#l00123">kernel_function()</a>, <a class="el" href="atkbd_8c-source.html#l00216">keyboardHandler()</a>, <a class="el" href="kmalloc_8c-source.html#l00351">kfree()</a>, <a class="el" href="kmalloc_8c-source.html#l00247">kmalloc()</a>, <a class="el" href="system_8c-source.html#l00069">mpi_createMbox()</a>, <a class="el" href="system_8c-source.html#l00234">mpi_destroyMbox()</a>, <a class="el" href="system_8c-source.html#l00189">mpi_fetchMessage()</a>, <a class="el" href="system_8c-source.html#l00143">mpi_postMessage()</a>, <a class="el" href="system_8c-source.html#l00108">mpi_spam()</a>, <a class="el" href="ne2k_8c-source.html#l00313">ne2kAllocBuffer()</a>, <a class="el" href="sched_8c-source.html#l00143">schedNewTask()</a>, <a class="el" href="smp_8c-source.html#l00161">smpInit()</a>, <a class="el" href="sys__arch_8c-source.html#l00172">sys_thread_new()</a>, <a class="el" href="tty_8c-source.html#l00118">tty_print()</a>, <a class="el" href="dirCache_8c-source.html#l00242">ubixfs_cacheAdd()</a>, <a class="el" href="dirCache_8c-source.html#l00055">ubixfs_cacheFind()</a>, <a class="el" href="paging_8c-source.html#l00401">vmm_getFreeMallocPage()</a>, <a class="el" href="pagefault_8c-source.html#l00053">vmm_pageFault()</a>, <a class="el" href="paging_8c-source.html#l00160">vmm_remapPage()</a>, <a class="el" href="copyvirtualspace_8c-source.html#l00053">vmmCopyVirtualSpace()</a>, <a class="el" href="vmm__memory_8c-source.html#l00186">vmmFindFreePage()</a>, <a class="el" href="vmm__memory_8c-source.html#l00296">vmmFreeProcessPages()</a>, <a class="el" href="paging_8c-source.html#l00253">vmmGetFreeKernelPage()</a>, <a class="el" href="getfreepage_8c-source.html#l00048">vmmGetFreePage()</a>, and <a class="el" href="getfreevirtualpage_8c-source.html#l00047">vmmGetFreeVirtualPage()</a>. </div> </div><p> <hr><h2>Variable Documentation</h2> <a class="anchor" name="061103633079320d29a623d5758623b1"></a><!-- doxytag: member="spinlock.h::Master" ref="061103633079320d29a623d5758623b1" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="spinlock_8h.html#a240e9404b4ede1e0d714610080d1176">spinLock_t</a> <a class="el" href="syscall__new_8c.html#061103633079320d29a623d5758623b1">Master</a> </td> </tr> </table> </div> <div class="memdoc"> <p> <p> Definition at line <a class="el" href="syscall__new_8c-source.html#l00039">39</a> of file <a class="el" href="syscall__new_8c-source.html">syscall_new.c</a>. </div> </div><p> <hr size="1"><address style="align: right;"><small>Generated on Tue Dec 12 08:52:12 2006 for UbixOS V2 by <a href="http://www.doxygen.org/index.html"> <img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.7 </small></address> </body> </html>