MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sys_print_debug

Function sys_print_debug

freebsd/mips/nlm/cms.c:473–493  ·  view source on GitHub ↗

* DEBUG support, XXX: static buffer, not locked */

Source from the content-addressed store, hash-verified

471 * DEBUG support, XXX: static buffer, not locked
472 */
473static int
474sys_print_debug(SYSCTL_HANDLER_ARGS)
475{
476 struct sbuf sb;
477 int error, i;
478
479 sbuf_new_for_sysctl(&sb, NULL, 64, req);
480 sbuf_printf(&sb,
481 "\nID vc0 vc1 vc2 vc3 loops\n");
482 for (i = 0; i < 32; i++) {
483 if ((xlp_hw_thread_mask & (1 << i)) == 0)
484 continue;
485 sbuf_printf(&sb, "%2d: %8d %8d %8d %8d %8d\n", i,
486 fmn_msgcount[i][0], fmn_msgcount[i][1],
487 fmn_msgcount[i][2], fmn_msgcount[i][3],
488 fmn_loops[i]);
489 }
490 error = sbuf_finish(&sb);
491 sbuf_delete(&sb);
492 return (error);
493}
494
495SYSCTL_PROC(_debug, OID_AUTO, msgring,
496 CTLTYPE_STRING | CTLFLAG_RD | CTLFLAG_NEEDGIANT, 0, 0,

Callers

nothing calls this directly

Calls 4

sbuf_new_for_sysctlFunction · 0.85
sbuf_printfFunction · 0.85
sbuf_finishFunction · 0.85
sbuf_deleteFunction · 0.85

Tested by

no test coverage detected