Add default-monitor-time-sec 84/315184/5 accepted/tizen_unified accepted/tizen_unified_dev accepted/tizen_unified_toolchain accepted/tizen_unified_x accepted/tizen_unified_x_asan tizen accepted/tizen/unified/20240731.160054 accepted/tizen/unified/dev/20240805.054728 accepted/tizen/unified/toolchain/20240812.133542 accepted/tizen/unified/x/20240801.044312 accepted/tizen/unified/x/asan/20240813.232033
authorJaechul Lee <jcsing.lee@samsung.com>
Fri, 26 Jul 2024 07:33:54 +0000 (16:33 +0900)
committerjaechul lee <jcsing.lee@samsung.com>
Mon, 29 Jul 2024 09:40:08 +0000 (09:40 +0000)
[Version] 15.0-33
[Issue Type] Update

Change-Id: Iee3772aeb7c801613927d81f1d8041cb12435b22
Signed-off-by: Jaechul Lee <jcsing.lee@samsung.com>
src/daemon/daemon-conf.c
src/daemon/daemon-conf.h
src/daemon/main.c
src/pulsecore/core.c
src/pulsecore/core.h

index 7c6da82..c095ac0 100644 (file)
@@ -66,6 +66,9 @@ static const pa_daemon_conf default_conf = {
     .nice_level = -11,
     .realtime_scheduling = true,
     .realtime_priority = 5,  /* Half of JACK's default rtprio */
+#ifdef __TIZEN__
+    .default_monitor_time_sec = 3,
+#endif
 #ifdef TIZEN_EMPTY_POP
     .empty_pop_threshold = 60,
 #endif
@@ -590,6 +593,9 @@ int pa_daemon_conf_load(pa_daemon_conf *c, const char *filename) {
         { "exit-idle-time",             pa_config_parse_int,      &c->exit_idle_time, NULL },
         { "scache-idle-time",           pa_config_parse_int,      &c->scache_idle_time, NULL },
         { "realtime-priority",          parse_rtprio,             c, NULL },
+#ifdef __TIZEN__
+        { "default-monitor-time-sec",   pa_config_parse_int,     &c->default_monitor_time_sec, NULL },
+#endif
 #ifdef TIZEN_EMPTY_POP
         { "empty-pop-threshold",        pa_config_parse_unsigned, &c->empty_pop_threshold, NULL },
 #endif
@@ -804,6 +810,9 @@ char *pa_daemon_conf_dump(pa_daemon_conf *c) {
     pa_strbuf_printf(s, "nice-level = %i\n", c->nice_level);
     pa_strbuf_printf(s, "realtime-scheduling = %s\n", pa_yes_no(c->realtime_scheduling));
     pa_strbuf_printf(s, "realtime-priority = %i\n", c->realtime_priority);
+#ifdef __TIZEN__
+    pa_strbuf_printf(s, "default-monitor-time-sec= %s\n", c->default_monitor_time_sec);
+#endif
 #ifdef TIZEN_EMPTY_POP
     pa_strbuf_printf(s, "empty-pop-threshold = %u\n", c->empty_pop_threshold);
 #endif
index 3093d2b..6248c22 100644 (file)
@@ -92,6 +92,7 @@ typedef struct pa_daemon_conf {
     unsigned log_backtrace;
     char *config_file;
 #ifdef __TIZEN__
+    unsigned default_monitor_time_sec;
     unsigned empty_pop_threshold;
 #endif
 
index 72c4227..e2e75e7 100644 (file)
@@ -1265,6 +1265,9 @@ int main(int argc, char *argv[]) {
 #ifdef HAVE_DBUS
     c->server_type = conf->local_server_type;
 #endif
+#ifdef __TIZEN__
+    c->default_monitor_time_sec = conf->default_monitor_time_sec;
+#endif
 #ifdef TIZEN_EMPTY_POP
     c->empty_pop_threshold = conf->empty_pop_threshold;
 #endif
index 0dbfb37..307551a 100644 (file)
@@ -204,6 +204,9 @@ pa_core* pa_core_new(pa_mainloop_api *m, bool shared, bool enable_memfd, size_t
 #ifdef TIZEN_PCM_DUMP
     c->pcm_dump = 0;
 #endif
+#ifdef __TIZEN__
+    c->default_monitor_time_sec = 3;
+#endif
 #ifdef TIZEN_EMPTY_POP
     c->empty_pop_threshold = 60;  /* will be updated by pa_daemon_conf_load() */
 #endif
index 43f2e34..5af3641 100644 (file)
@@ -253,6 +253,7 @@ struct pa_core {
     pa_hook hooks[PA_CORE_HOOK_MAX];
 #ifdef __TIZEN__
     uint32_t pcm_dump;
+    unsigned default_monitor_time_sec;
     unsigned empty_pop_threshold;
 #endif
 };