1 #include <sys/cdefs.h> 2 #include "namespace.h" 3 4 #ifdef __weak_alias 5 __weak_alias(sprofile, _sprofile) 6 #endif 7 8 #include <lib.h> 9 #include <string.h> 10 #include <minix/profile.h> 11 12 int sprofile(int action, 13 int size, 14 int freq, 15 int type, 16 void *ctl_ptr, 17 void *mem_ptr) 18 { 19 message m; 20 21 memset(&m, 0, sizeof(m)); 22 m.m_lc_pm_sprof.action = action; 23 m.m_lc_pm_sprof.mem_size = size; 24 m.m_lc_pm_sprof.freq = freq; 25 m.m_lc_pm_sprof.intr_type = type; 26 m.m_lc_pm_sprof.ctl_ptr = ctl_ptr; 27 m.m_lc_pm_sprof.mem_ptr = mem_ptr; 28 29 return _syscall(PM_PROC_NR, PM_SPROF, &m); 30 } 31 32