title: How to script stap (systemtap) to see if some process has called specific kernel function?
body: <p>Using stap, I can write *.stp file to</p>
  
  <p>Either track a process's action like:</p>
  
  <pre><code>probe process("mytest").begin
  {
      printf("Caught mytest process")
  }
  </code></pre>
  
  <p>Or to track if a kernel function is called by any process:</p>
  
  <pre><code>probe kernel.function("do_exit").call #all processes
  {
      printf("called kernel/exit.c: do_exit\n")
  }
  </code></pre>
  
  <p>But my requirement is: to track the kernel function call from specific process names, like tracking "sys_open" called by "mytest" processes.</p>
  
  <p>How to write this .stp statement/function?
  Thanks!</p>