[IMPROVE] get pid/tid for message probe generate
[platform/core/system/swap-probe.git] / probe_userfunc / libdauserfunc.c
index 7b5bed8..cc6e95b 100755 (executable)
@@ -89,7 +89,7 @@ pthread_mutex_t profil_log_mutex;
 typedef struct sample_info_t {
        unsigned long time;
        void *pc;
-       int bt_size;
+       size_t bt_size;
        void *bt_array[MAX_STACK_DEPTH];
 } sample_info;
 
@@ -220,7 +220,7 @@ int profil_backtrace_symbols(log_t *log, int bufsize, int index)
 }
 #endif
 
-void *profil_log_func(void *data)
+void *profil_log_func(void __unused * data)
 {
        probeBlockStart();
 
@@ -352,7 +352,7 @@ void mcount(void)
 }
 
 #elif defined(__arm__)
-void mcount_internal(u_long frompc, u_long selfpc)
+void mcount_internal(u_long __unused frompc, u_long __unused selfpc)
 {
        return;
 }
@@ -419,7 +419,7 @@ static inline void profil_count(void *pc)
 }
 
 #if defined(__i386__)
-static void profil_counter(int signo, const struct sigcontext scp)
+static void profil_counter(int __unused signo, const struct sigcontext scp)
 {
        profil_count((void *) GET_PC(scp));
 
@@ -429,7 +429,8 @@ static void profil_counter(int signo, const struct sigcontext scp)
        asm volatile("");
 }
 #elif defined(__arm__)
-static void profil_counter(int signr, siginfo_t *si, struct ucontext *uctx)
+static void profil_counter(int __unused signr, siginfo_t __unused * si,
+                          struct ucontext *uctx)
 {
        profil_count((void *) GET_PC(uctx));
 
@@ -538,4 +539,3 @@ void _mcleanup(void)
        profil_thread_on = 0;
        return;
 }
-