Newer
Older
UbixOS / doc / html / dd / df2 / vfs_8c.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.16"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>UbixOS: fs/vfs/vfs.c File Reference</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtreedata.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(initResizable);
/* @license-end */</script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">UbixOS
   &#160;<span id="projectnumber">2.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.16 -->
<script type="text/javascript" src="../../menudata.js"></script>
<script type="text/javascript" src="../../menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('../../',false,false,'search.php','Search');
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('dd/df2/vfs_8c.html','../../');});
/* @license-end */
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">vfs.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><code>#include &lt;<a class="el" href="../../db/da9/include_2vfs_2vfs_8h_source.html">vfs/vfs.h</a>&gt;</code><br />
<code>#include &lt;<a class="el" href="../../d2/d48/vitals_8h_source.html">ubixos/vitals.h</a>&gt;</code><br />
<code>#include &lt;<a class="el" href="../../d4/d03/kmalloc_8h_source.html">lib/kmalloc.h</a>&gt;</code><br />
<code>#include &lt;<a class="el" href="../../da/d28/kprintf_8h_source.html">lib/kprintf.h</a>&gt;</code><br />
<code>#include &lt;<a class="el" href="../../da/d66/string_8h_source.html">string.h</a>&gt;</code><br />
<code>#include &lt;<a class="el" href="../../d3/df4/descrip_8h_source.html">sys/descrip.h</a>&gt;</code><br />
</div><div class="textblock"><div class="dynheader">
Include dependency graph for vfs.c:</div>
<div class="dyncontent">
<div class="center"><img src="../../d0/d95/vfs_8c__incl.png" border="0" usemap="#fs_2vfs_2vfs_8c" alt=""/></div>
<map name="fs_2vfs_2vfs_8c" id="fs_2vfs_2vfs_8c">
<area shape="rect" title=" " alt="" coords="1447,5,1529,32"/>
<area shape="rect" href="../../db/da9/include_2vfs_2vfs_8h.html" title=" " alt="" coords="1144,155,1211,181"/>
<area shape="rect" href="../../da/d28/kprintf_8h.html" title=" " alt="" coords="5,827,91,853"/>
<area shape="rect" href="../../d2/d48/vitals_8h.html" title=" " alt="" coords="628,80,732,107"/>
<area shape="rect" href="../../d4/d03/kmalloc_8h.html" title=" " alt="" coords="1761,155,1855,181"/>
<area shape="rect" href="../../da/d66/string_8h.html" title=" " alt="" coords="1863,752,1929,779"/>
<area shape="rect" href="../../d3/df4/descrip_8h.html" title=" " alt="" coords="1519,453,1619,480"/>
<area shape="rect" href="../../d0/d27/include_2sys_2types_8h.html" title=" " alt="" coords="1136,901,1227,928"/>
<area shape="rect" href="../../d6/db4/include_2vfs_2file_8h.html" title=" " alt="" coords="1143,603,1211,629"/>
<area shape="rect" href="../../db/dd5/thread_8h.html" title=" " alt="" coords="1482,677,1577,704"/>
<area shape="rect" href="../../d1/df2/wait_8h.html" title=" " alt="" coords="876,752,975,779"/>
<area shape="rect" href="../../d2/d29/mount_8h.html" title=" " alt="" coords="831,677,919,704"/>
<area shape="rect" href="../../d3/d7e/sysproto__posix_8h.html" title=" " alt="" coords="1347,528,1493,555"/>
<area shape="rect" href="../../d7/d97/net_8h.html" title=" " alt="" coords="933,229,1006,256"/>
<area shape="rect" href="../../d0/d6f/__types_8h.html" title=" " alt="" coords="1269,1125,1366,1152"/>
<area shape="rect" href="../../d9/dab/select_8h.html" title=" " alt="" coords="1135,976,1228,1003"/>
<area shape="rect" href="../../d6/d92/cdefs_8h.html" title=" " alt="" coords="889,1051,978,1077"/>
<area shape="rect" href="../../d6/d30/__timespec_8h.html" title=" " alt="" coords="1307,1051,1426,1077"/>
<area shape="rect" href="../../df/dc5/__timeval_8h.html" title=" " alt="" coords="1002,1051,1107,1077"/>
<area shape="rect" href="../../d6/da4/__sigset_8h.html" title=" " alt="" coords="1131,1051,1231,1077"/>
<area shape="rect" href="../../d1/de9/dirCache_8h.html" title=" " alt="" coords="825,827,948,853"/>
<area shape="rect" href="../../d3/d73/inode_8h.html" title=" " alt="" coords="1145,677,1228,704"/>
<area shape="rect" href="../../df/d42/ufs_8h.html" title=" " alt="" coords="999,752,1070,779"/>
<area shape="rect" href="../../d7/d0b/trap_8h.html" title=" " alt="" coords="1436,752,1516,779"/>
<area shape="rect" href="../../df/d92/sys_2signal_8h.html" title=" " alt="" coords="1591,752,1683,779"/>
<area shape="rect" href="../../d8/d01/resource_8h.html" title=" " alt="" coords="1746,976,1854,1003"/>
<area shape="rect" href="../../d6/d35/i386_2cpu_8h.html" title=" " alt="" coords="1339,827,1421,853"/>
<area shape="rect" href="../../d1/d7d/pipe__fs_8h.html" title=" " alt="" coords="1324,752,1412,779"/>
<area shape="rect" href="../../d8/dff/msdos__fs_8h.html" title=" " alt="" coords="1197,752,1299,779"/>
<area shape="rect" href="../../d4/d7e/include_2sys_2device_8h.html" title=" " alt="" coords="973,827,1067,853"/>
<area shape="rect" href="../../d9/d69/netif_8h.html" title=" " alt="" coords="733,304,811,331"/>
<area shape="rect" href="../../dc/dba/opt_8h.html" title=" " alt="" coords="514,603,587,629"/>
<area shape="rect" href="../../d6/d40/err_8h.html" title=" " alt="" coords="885,528,955,555"/>
<area shape="rect" href="../../de/df7/ip__addr_8h.html" title=" " alt="" coords="449,379,546,405"/>
<area shape="rect" href="../../d4/da4/def_8h.html" title=" " alt="" coords="260,528,332,555"/>
<area shape="rect" href="../../d0/d35/pbuf_8h.html" title=" " alt="" coords="733,453,811,480"/>
<area shape="rect" href="../../d9/d9b/stats_8h.html" title=" " alt="" coords="625,453,709,480"/>
<area shape="rect" href="../../d2/d78/lwipopts_8h.html" title=" " alt="" coords="602,677,705,704"/>
<area shape="rect" href="../../db/d16/debug_8h.html" title=" " alt="" coords="487,677,577,704"/>
<area shape="rect" href="../../d2/d2d/arch_8h.html" title=" " alt="" coords="492,752,572,779"/>
<area shape="rect" href="../../dc/df0/cc_8h.html" title=" " alt="" coords="483,827,581,853"/>
<area shape="rect" href="../../d1/d2d/stdarg_8h.html" title=" " alt="" coords="13,901,83,928"/>
<area shape="rect" href="../../d1/da8/ip4__addr_8h.html" title=" " alt="" coords="445,453,549,480"/>
<area shape="rect" href="../../d3/d7d/ip6__addr_8h.html" title=" " alt="" coords="317,453,421,480"/>
<area shape="rect" href="../../d9/d9a/mem_8h.html" title=" " alt="" coords="509,528,593,555"/>
<area shape="rect" href="../../df/dff/memp_8h.html" title=" " alt="" coords="617,528,708,555"/>
<area shape="rect" href="../../df/d63/spinlock_8h.html" title=" " alt="" coords="67,229,189,256"/>
<area shape="rect" href="../../d6/d90/strings_8h.html" title=" " alt="" coords="1860,827,1932,853"/>
<area shape="rect" href="../../d2/d1b/stat_8h.html" title=" " alt="" coords="1657,603,1732,629"/>
<area shape="rect" href="../../d7/d9f/fcntl_8h.html" title=" " alt="" coords="1568,528,1651,555"/>
</map>
</div>
</div>
<p><a href="../../dd/df2/vfs_8c_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:aca585ca14c08d6c1a07e1b886fc9749a"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../dd/df2/vfs_8c.html#aca585ca14c08d6c1a07e1b886fc9749a">vfs_init</a> ()</td></tr>
<tr class="separator:aca585ca14c08d6c1a07e1b886fc9749a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac49aa10a62b250834a055476c849b7b3"><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="../../de/dfb/structfileSystem.html">fileSystem</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../dd/df2/vfs_8c.html#ac49aa10a62b250834a055476c849b7b3">vfsFindFS</a> (int vfsType)</td></tr>
<tr class="separator:ac49aa10a62b250834a055476c849b7b3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad8cb9693ae7b6b9fc419efc975778338"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../dd/df2/vfs_8c.html#ad8cb9693ae7b6b9fc419efc975778338">vfsRegisterFS</a> (struct <a class="el" href="../../de/dfb/structfileSystem.html">fileSystem</a> newFS)</td></tr>
<tr class="memdesc:ad8cb9693ae7b6b9fc419efc975778338"><td class="mdescLeft">&#160;</td><td class="mdescRight">register a file system  <a href="../../dd/df2/vfs_8c.html#ad8cb9693ae7b6b9fc419efc975778338">More...</a><br /></td></tr>
<tr class="separator:ad8cb9693ae7b6b9fc419efc975778338"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a id="aca585ca14c08d6c1a07e1b886fc9749a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aca585ca14c08d6c1a07e1b886fc9749a">&#9670;&nbsp;</a></span>vfs_init()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int vfs_init </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p class="definition">Definition at line <a class="el" href="../../dd/df2/vfs_8c_source.html#l00046">46</a> of file <a class="el" href="../../dd/df2/vfs_8c_source.html">vfs.c</a>.</p>

<p class="reference">References <a class="el" href="../../d2/d48/vitals_8h_source.html#l00044">vitalsStruct::fileSystems</a>, <a class="el" href="../../df/d87/kprintf_8c_source.html#l00259">kprintf()</a>, and <a class="el" href="../../d2/d4e/vitals_8c_source.html#l00035">systemVitals</a>.</p>
<div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="../../dd/df2/vfs_8c_aca585ca14c08d6c1a07e1b886fc9749a_cgraph.png" border="0" usemap="#dd/df2/vfs_8c_aca585ca14c08d6c1a07e1b886fc9749a_cgraph" alt=""/></div>
<map name="dd/df2/vfs_8c_aca585ca14c08d6c1a07e1b886fc9749a_cgraph" id="dd/df2/vfs_8c_aca585ca14c08d6c1a07e1b886fc9749a_cgraph">
<area shape="rect" title=" " alt="" coords="5,132,67,159"/>
<area shape="rect" href="../../da/d28/kprintf_8h.html#a20b56810edb62a6fe59917015c30848f" title=" " alt="" coords="115,132,172,159"/>
<area shape="rect" href="../../dd/d78/video_8h.html#a5429378b96a24fadfd2d1f8d777eb95a" title=" " alt="" coords="226,81,281,108"/>
<area shape="rect" href="../../df/d87/kprintf_8c.html#a3093cdac4668a4ccffdd7f77270888b7" title=" " alt="" coords="222,132,285,159"/>
<area shape="rect" href="../../da/d28/kprintf_8h.html#a3b4a66bf1f6583e65660f281b6014aa1" title=" " alt="" coords="220,183,287,209"/>
<area shape="rect" href="../../dc/dac/io_8h.html#a77b934268de1b3ecdcf3f275413b3108" title="input one byte from specified port" alt="" coords="339,5,420,32"/>
<area shape="rect" href="../../dc/dac/io_8h.html#a8acc1a06073db2e7b92ffbd00fbd0cf1" title="outputut one byte to specified port" alt="" coords="335,56,424,83"/>
<area shape="rect" href="../../dd/d71/tty_8h.html#a4f96ccac7e60296ef496008d8cbed0ff" title=" " alt="" coords="347,107,411,133"/>
<area shape="rect" href="../../dd/d71/tty_8h.html#ad96f57a7c113d3cfa76ee5fed6de33c0" title=" " alt="" coords="345,157,414,184"/>
<area shape="rect" href="../../dc/d88/armv6_2spinlock_8c.html#a71f03d2ba55111c715b6068254847a53" title=" " alt="" coords="472,157,547,184"/>
<area shape="rect" href="../../d3/d02/armv6_2sched_8c.html#a08933fe6d593a1c78b9080359f15a0b7" title=" " alt="" coords="595,132,686,159"/>
<area shape="rect" href="../../dc/d88/armv6_2spinlock_8c.html#a740766af5da58616f700fffab6768a78" title=" " alt="" coords="595,183,687,209"/>
</map>
</div>

</div>
</div>
<a id="ac49aa10a62b250834a055476c849b7b3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac49aa10a62b250834a055476c849b7b3">&#9670;&nbsp;</a></span>vfsFindFS()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">struct <a class="el" href="../../de/dfb/structfileSystem.html">fileSystem</a>* vfsFindFS </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>vfsType</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p class="definition">Definition at line <a class="el" href="../../dd/df2/vfs_8c_source.html#l00057">57</a> of file <a class="el" href="../../dd/df2/vfs_8c_source.html">vfs.c</a>.</p>

<p class="reference">References <a class="el" href="../../d2/d48/vitals_8h_source.html#l00044">vitalsStruct::fileSystems</a>, <a class="el" href="../../db/da9/include_2vfs_2vfs_8h_source.html#l00061">fileSystem::next</a>, <a class="el" href="../../d2/d4e/vitals_8c_source.html#l00035">systemVitals</a>, and <a class="el" href="../../db/da9/include_2vfs_2vfs_8h_source.html#l00070">fileSystem::vfsType</a>.</p>

<p class="reference">Referenced by <a class="el" href="../../dc/d92/mount_8c_source.html#l00045">vfs_mount()</a>.</p>

</div>
</div>
<a id="ad8cb9693ae7b6b9fc419efc975778338"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad8cb9693ae7b6b9fc419efc975778338">&#9670;&nbsp;</a></span>vfsRegisterFS()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int vfsRegisterFS </td>
          <td>(</td>
          <td class="paramtype">struct <a class="el" href="../../de/dfb/structfileSystem.html">fileSystem</a>&#160;</td>
          <td class="paramname"><em>newFS</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>register a file system </p>
<p>This registers a new filesystem into the vfs which is referenced when trying to mount a device</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">newFS</td><td>pointer to <a class="el" href="../../de/dfb/structfileSystem.html" title="filesSystem Structure">fileSystem</a> structure </td></tr>
  </table>
  </dd>
</dl>

<p class="definition">Definition at line <a class="el" href="../../dd/df2/vfs_8c_source.html#l00079">79</a> of file <a class="el" href="../../dd/df2/vfs_8c_source.html">vfs.c</a>.</p>

<p class="reference">Referenced by <a class="el" href="../../d3/d2e/fat_8c_source.html#l00180">fat_init()</a>.</p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="../../dir_97b3d2b63ac216821c2d7a22ee0ab2b0.html">fs</a></li><li class="navelem"><a class="el" href="../../dir_b092b79bda96b86d6b47a2d4ae880533.html">vfs</a></li><li class="navelem"><a class="el" href="../../dd/df2/vfs_8c.html">vfs.c</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.16 </li>
  </ul>
</div>
</body>
</html>