1 #include <lib.h> 2 #include <string.h> 3 #include <minix/gcov.h> 4 5 int 6 gcov_flush_svr(const char * label, char * buff, size_t buff_sz) 7 { 8 message m; 9 10 memset(&m, 0, sizeof(m)); 11 m.m_lc_vfs_gcov.label = (vir_bytes)label; 12 m.m_lc_vfs_gcov.labellen = strlen(label) + 1; 13 m.m_lc_vfs_gcov.buf = (vir_bytes)buff; 14 m.m_lc_vfs_gcov.buflen = buff_sz; 15 16 /* 17 * Make the call to VFS. VFS will call the gcov library, buffer the 18 * stdio requests, and copy the buffer to us. 19 */ 20 return _syscall(VFS_PROC_NR, VFS_GCOV_FLUSH, &m); 21 } 22