mirror of
https://github.com/ebrandi/FDD-book.git
synced 2026-12-06 00:23:30 +00:00
21 lines
386 B
D
21 lines
386 B
D
|
|
#!/usr/sbin/dtrace -s
|
||
|
|
/*
|
||
|
|
* trace-ioctls.d - print each bugdemo command as it starts and ends.
|
||
|
|
*
|
||
|
|
* Usage:
|
||
|
|
* # dtrace -s trace-ioctls.d
|
||
|
|
*/
|
||
|
|
|
||
|
|
#pragma D option quiet
|
||
|
|
|
||
|
|
sdt:bugdemo::cmd-start
|
||
|
|
{
|
||
|
|
printf("%Y %s:%d start op=%d\n", walltimestamp, execname, pid, arg1);
|
||
|
|
}
|
||
|
|
|
||
|
|
sdt:bugdemo::cmd-done
|
||
|
|
{
|
||
|
|
printf("%Y %s:%d done op=%d rv=%d\n",
|
||
|
|
walltimestamp, execname, pid, arg1, arg2);
|
||
|
|
}
|