diff --git a/Userland/Libraries/LibC/serenity.cpp b/Userland/Libraries/LibC/serenity.cpp index f3a0517e94..d91c8ceae8 100644 --- a/Userland/Libraries/LibC/serenity.cpp +++ b/Userland/Libraries/LibC/serenity.cpp @@ -62,6 +62,12 @@ int profiling_disable(pid_t pid) __RETURN_WITH_ERRNO(rc, rc, -1); } +int profiling_free_buffer(pid_t pid) +{ + int rc = syscall(SC_profiling_free_buffer, pid); + __RETURN_WITH_ERRNO(rc, rc, -1); +} + int futex(uint32_t* userspace_address, int futex_op, uint32_t value, const struct timespec* timeout, uint32_t* userspace_address2, uint32_t value3) { int rc; diff --git a/Userland/Libraries/LibC/serenity.h b/Userland/Libraries/LibC/serenity.h index 8a7f632a0b..80532970a0 100644 --- a/Userland/Libraries/LibC/serenity.h +++ b/Userland/Libraries/LibC/serenity.h @@ -39,6 +39,7 @@ int module_unload(const char* name, size_t name_length); int profiling_enable(pid_t); int profiling_disable(pid_t); +int profiling_free_buffer(pid_t); #define THREAD_PRIORITY_MIN 1 #define THREAD_PRIORITY_LOW 10