2 * Library function used by system profiling.
4 * The variables and functions in this file are used by the procentry/
5 * procentry syslib functions when linked with userspace processes. For
6 * kernel processes, the same variables and function are defined
7 * elsewhere. This enables different functionality and variable sizes,
8 * which is needed is a few cases.
11 * 14 Aug, 2006 Created (Rogier Meurs)
16 #include <minix/profile.h>
17 #include <minix/syslib.h>
19 /* A regular sized table is declared for the userspace processes. */
20 struct cprof_tbl_s cprof_tbl
[CPROF_TABLE_SIZE_OTHER
];
22 /* Function that returns table size. */
23 int profile_get_tbl_size(void)
25 return CPROF_TABLE_SIZE_OTHER
;
28 /* Function that returns on which execution of procentry to announce. */
29 int profile_get_announce(void)
31 return CPROF_ANNOUNCE_OTHER
;
35 * Userspace processes announce their control struct and table locations
36 * to the kernel through this function.
38 void profile_register(ctl_ptr
, tbl_ptr
)
42 sys_profbuf(ctl_ptr
, tbl_ptr
);