title: What is the difference between "Linux Kernel API", "System Calls", "System Interfaces" and "GNU C Library"?
body: <p>After try to implement a <code>System Call</code>, I totally confused about Linux :D</p>
  
  <p>What is the difference between <code>Linux Kernel API</code>, <code>System Calls</code>, <code>System Interfaces</code> and <code>GNU C Library</code>?</p>
  
  <p>I found these links for each item:</p>
  
  <p><strong>The Linux Kernel API</strong></p>
  
  <p><a href="https://www.kernel.org/doc/htmldocs/kernel-api.html" rel="nofollow">https://www.kernel.org/doc/htmldocs/kernel-api.html</a></p>
  
  <p><strong>Linux System Calls</strong></p>
  
  <p><a href="http://syscalls.kernelgrok.com/" rel="nofollow">http://syscalls.kernelgrok.com/</a></p>
  
  <p><a href="http://lxr.free-electrons.com/source/arch/x86/syscalls/syscall_32.tbl" rel="nofollow">http://lxr.free-electrons.com/source/arch/x86/syscalls/syscall_32.tbl</a></p>
  
  <p><strong>System Interfaces</strong></p>
  
  <p><a href="http://pubs.opengroup.org/onlinepubs/9699919799/idx/functions.html" rel="nofollow">http://pubs.opengroup.org/onlinepubs/9699919799/idx/functions.html</a></p>
  
  <p><strong>The GNU C Library</strong></p>
  
  <p><a href="http://www.gnu.org/software/libc/manual/html_node/index.html" rel="nofollow">http://www.gnu.org/software/libc/manual/html_node/index.html</a></p>
  
  <p>I confused about these functions.</p>
  
  <p>For example <code>sprintf</code> exists in <code>Linux Kernel API</code>, but <code>System Interfaces</code> functions list contains this function too. Some functions should not use in Kernel mode (eg. <code>printf</code>). Many functions do the same task with different names (eg. <code>sys_open</code> and <code>open</code>), and so on...</p>
  
  <p>My question is:</p>
  
  <p>What is the difference between <code>Linux Kernel API</code>, <code>System Calls</code>, <code>System Interfaces</code> and <code>GNU C Library</code>?
  Which function should I use, Which function I should not use?</p>
  
  <p>Oh! I forgot the <code>C standard library</code> :)</p>