xref: /minix3/minix/lib/libsys/sef_gcov.c (revision 3ac58492b3d3709bad0ae9c60a137f63a90960b7)
1433d6423SLionel Sambuc 
2433d6423SLionel Sambuc #include "syslib.h"
3433d6423SLionel Sambuc #include <assert.h>
4433d6423SLionel Sambuc #include <minix/sysutil.h>
5433d6423SLionel Sambuc #include <minix/gcov.h>
6433d6423SLionel Sambuc 
7dd096140SCristiano Giuffrida static sef_cb_gcov_t sef_cb_gcov = SEF_CB_GCOV_FLUSH_DEFAULT;
8433d6423SLionel Sambuc 
9*3ac58492SDavid van Moolenbroek int do_sef_gcov_request(message *);
10*3ac58492SDavid van Moolenbroek 
11433d6423SLionel Sambuc /*===========================================================================*
12433d6423SLionel Sambuc  *                            do_sef_gcov_request             		     *
13433d6423SLionel Sambuc  *===========================================================================*/
do_sef_gcov_request(message * m_ptr)14433d6423SLionel Sambuc int do_sef_gcov_request(message *m_ptr)
15433d6423SLionel Sambuc {
16433d6423SLionel Sambuc 	if(!sef_cb_gcov)
17433d6423SLionel Sambuc 		return ENOSYS;
18433d6423SLionel Sambuc 
19433d6423SLionel Sambuc 	sef_cb_gcov(m_ptr);
20433d6423SLionel Sambuc 
21433d6423SLionel Sambuc 	return OK;
22433d6423SLionel Sambuc }
23433d6423SLionel Sambuc 
24433d6423SLionel Sambuc /*===========================================================================*
25433d6423SLionel Sambuc  *                            sef_setcb_gcov             		     *
26433d6423SLionel Sambuc  *===========================================================================*/
sef_setcb_gcov(sef_cb_gcov_t cb)27433d6423SLionel Sambuc void sef_setcb_gcov(sef_cb_gcov_t cb)
28433d6423SLionel Sambuc {
29433d6423SLionel Sambuc 	sef_cb_gcov = cb;
30433d6423SLionel Sambuc }
31