* vim:expandtab:shiftwidth=8:tabstop=8:
*
* Compile with:
- * cc -I../../portals/include -o fio fio.c -L../../portals/linux/utils -lptlctl
+ * cc -I../../portals/include -o fio fio.c -L../../portals/linux/utils -lptlctl
*/
#ifndef __LTRACE_H_
#define __LTRACE_H_
#include <unistd.h>
#include <sys/time.h>
#include <portals/types.h>
-#include <portals/ptlctl.h>
#include <linux/kp30.h>
+#include <portals/ptlctl.h>
#include <linux/limits.h>
#include <asm/page.h>
#include <linux/version.h>
argv[0] = "debug_kernel";
argv[1] = fname;
argv[2] = "1";
-
+
fprintf(stderr, "[ptlctl] %s %s %s\n", argv[0], argv[1], argv[2]);
-
+
return jt_dbg_debug_kernel(3, argv);
}
static inline int ltrace_clear()
{
char* argv[1];
-
+
argv[0] = "clear";
-
+
fprintf(stderr, "[ptlctl] %s\n", argv[0]);
-
+
return jt_dbg_clear_debug_buf(1, argv);
}
{
char* argv[2];
char mark_buf[PATH_MAX];
-
+
snprintf(mark_buf, PATH_MAX, "====%d=%s", indent_level, text);
-
+
argv[0] = "mark";
argv[1] = mark_buf;
return jt_dbg_mark_debug_buf(2, argv);
char* argv[2];
argv[0] = "list";
argv[1] = "applymasks";
-
+
fprintf(stderr, "[ptlctl] %s %s\n", argv[0], argv[1]);
-
+
return jt_dbg_list(2, argv);
}
#ifdef PORTALS_DEV_ID
rc = register_ioc_dev(PORTALS_DEV_ID, PORTALS_DEV_PATH);
#endif
- ltrace_filter("class");
- ltrace_filter("socknal");
- ltrace_filter("qswnal");
- ltrace_filter("gmnal");
- ltrace_filter("portals");
-
- ltrace_show("all_types");
- ltrace_filter("trace");
- ltrace_filter("malloc");
- ltrace_filter("net");
- ltrace_filter("page");
- ltrace_filter("other");
- ltrace_filter("info");
+ ltrace_filter("class");
+ ltrace_filter("nal");
+ ltrace_filter("portals");
+
+ ltrace_show("all_types");
+ ltrace_filter("trace");
+ ltrace_filter("malloc");
+ ltrace_filter("net");
+ ltrace_filter("page");
+ ltrace_filter("other");
+ ltrace_filter("info");
ltrace_applymasks();
return rc;
struct timezone tz;
int nob;
int underuml = !not_uml();
-
+
gettimeofday(&tv, &tz);
nob = snprintf(cmdbuf, LTRACE_MAX_NOB, "ps --no-headers -eo \"");
"(%s:%d:%s() %d+%lu): ",
"lltrace.h", __LINE__, __FUNCTION__, 0, 0L);
}
-
+
nob += snprintf(cmdbuf+nob, LTRACE_MAX_NOB, " %%p %%c\" >> %s", fname);
system(cmdbuf);
}