Skip to content

RDKEVD-8726: Audio Remains Muted and Volume Reports 0 After Standby Reboot When Panel Is Woken Up via FFV - #278

Open
yeshwanth-nagaswamy wants to merge 1 commit into
developfrom
feature/rdkevd-8726-mute
Open

RDKEVD-8726: Audio Remains Muted and Volume Reports 0 After Standby Reboot When Panel Is Woken Up via FFV#278
yeshwanth-nagaswamy wants to merge 1 commit into
developfrom
feature/rdkevd-8726-mute

Conversation

@yeshwanth-nagaswamy

Copy link
Copy Markdown
Contributor

@yeshwanth-nagaswamy
yeshwanth-nagaswamy requested a review from a team as a code owner August 10, 2026 07:29
Copilot AI lite review requested due to automatic review settings August 10, 2026 07:29

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR is scoped around adding diagnostic logging and adjusting log verbosity in the DeviceSettings audio and capability-loading paths, likely intended to help investigate RDKEVD-8726 (“Audio remains muted / volume reports 0 after standby reboot”).

Changes:

  • Added several new debug/trace logs in dsAudio.c around dsSetAudioLevel loading and ducking volume application.
  • Replaced DS logger macros (INT_*) with direct printf calls in capability loading and audio config code paths.
  • Changed DS logger defaults/mappings in dslogger.h (default log level and INT_INFO severity).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 6 comments.

File Description
rpc/srv/dsAudio.c Adds extra logging around audio level initialization and ducking volume application.
ds/manager.cpp Switches multiple log statements to printf in DL symbol loading and Manager lifecycle functions.
ds/include/dslogger.h Changes default DS log level and remaps INT_INFO to log at DEBUG severity.
ds/audioOutputPortConfig.cpp Adds printf diagnostics in supported-type enumeration and config dumping/loading paths.
Suppressed comments (17)

ds/manager.cpp:108

  • printf usage here is inconsistent with the rest of the module’s logging (which uses INT_* / ds_log) and can bypass log routing (e.g., DS_RegisterForLog). Prefer INT_INFO for these informational messages.
    printf("Entering capabilityType = 0x%08X", capabilityType);
    dlerror(); // clear old error
    pDLHandle = dlopen(RDK_DSHAL_NAME, RTLD_LAZY);
    
    if (nullptr == pDLHandle) {

ds/manager.cpp:193

  • This printf bypasses the DS logging infrastructure (INT_* / ds_log). Prefer INT_INFO so the message follows the normal logging path and formatting.
    printf("Exiting ...");

ds/manager.cpp:317

  • These printf calls bypass ds_log/INT_* and also omit newlines, which can make logs hard to correlate and may not flush promptly depending on stdout buffering. Prefer INT_INFO for consistent routing/formatting.
	printf("Exiting ... with thread id %lu",pthread_self());
}

void Manager::load()
{
    printf("Enter function");

ds/manager.cpp:346

  • This printf bypasses the DS logging infrastructure (INT_* / ds_log). Prefer INT_INFO so logs include standard metadata (file/line/function) and go through the registered log callback.
	printf("Entering ... count %d with thread id %lu",IsInitialized,pthread_self());

ds/manager.cpp:363

  • This printf bypasses the DS logging infrastructure (INT_* / ds_log). Prefer INT_INFO for consistent routing/formatting and to avoid stdout buffering issues.
	printf("Exiting ... with thread %lu",pthread_self());

ds/audioOutputPortConfig.cpp:121

  • dumpconfig() switched from INT_* logging to printf, which bypasses the DS logging callback/formatting and writes to stdout (often undesired on embedded targets). Keeping these on INT_* preserves consistent log routing and severity control.
    if (nullptr == config) {
        printf("\nAudio config is NULL");
        return;
    }
    if ( -1 == access("/opt/dsMgrDumpDeviceConfigs", F_OK) ) {

ds/audioOutputPortConfig.cpp:127

  • This debug output should go through the DS logger (INT_INFO) instead of stdout so it can be routed/filtered consistently (and includes file/line/function context).
    printf("\n\n=============== Starting to Dump Audio Configs ===============\n");

ds/audioOutputPortConfig.cpp:137

  • These printf statements should use INT_INFO so the output is consistent with other DS logs and can be redirected via DS_RegisterForLog.
            const dsAudioTypeConfig_t *typeCfg = &(config->pKConfigs[i]);
            printf("\ntypeCfg->typeId = %d", typeCfg->typeId);
            printf("\ntypeCfg->name = %s", typeCfg->name);
            printf("\ntypeCfg->numSupportedEncodings = %zu", typeCfg->numSupportedEncodings);
            printf("\ntypeCfg->numSupportedCompressions = %zu", typeCfg->numSupportedCompressions);

ds/audioOutputPortConfig.cpp:143

  • Use INT_ERROR here for consistency with the rest of the module’s logging (and to avoid writing to stdout).
        printf("\nkAudioConfigs is NULL");

ds/audioOutputPortConfig.cpp:152

  • Use INT_INFO here so the port dump follows normal DS logging routing/formatting.
            printf("\nportCfg->id.type = %d", portCfg->id.type);
            printf("\nportCfg->id.index = %d", portCfg->id.index);

ds/audioOutputPortConfig.cpp:157

  • Use INT_ERROR here for consistency with the rest of the module’s error logging (and to avoid writing to stdout).
        printf("\nkAudioPorts is NULL");

ds/audioOutputPortConfig.cpp:160

  • This completion message should use INT_INFO rather than printf so it follows standard DS logging behavior and can be filtered/routed.
    printf("\n\n=============== Dump Audio Configs done ===============\n");

ds/audioOutputPortConfig.cpp:168

  • This should use DS logging (INT_INFO) instead of printf to avoid stdout noise and keep consistent log routing/formatting.
    printf("\nEnter function");

ds/audioOutputPortConfig.cpp:192

  • This message should use INT_INFO rather than printf so it can be routed/filtered consistently via the DS logger.
        printf("\nUsing '%s' config", dynamicAudioConfigs ? "dynamic" : "static");

ds/audioOutputPortConfig.cpp:212

  • Prefer INT_INFO over printf so this diagnostic goes through the DS logger (and can be routed via DS_RegisterForLog).
        printf("\nAudio Config[%p] ConfigSize[%d] Ports[%p] PortSize[%d]",
                configuration.pKConfigs,
                configSize,
                configuration.pKPorts,
                portSize);

ds/audioOutputPortConfig.cpp:258

  • These status messages should go through INT_INFO/INT_ERROR (instead of stdout) to keep logging consistent and avoid mixing runtime logs with config dumps.
            printf("\nAudio Configs loaded successfully");
        }
        else {
            printf("\nAudio Configs loading failed");
        }

ds/audioOutputPortConfig.cpp:263

  • This function exit message should use INT_INFO (not printf) so it follows standard DS logging behavior.
    printf("\nExit function");

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread ds/include/dslogger.h
Comment on lines 48 to +52
#ifndef DS_LOG_LEVEL
#define DS_LOG_LEVEL ERROR_LEVEL
#define DS_LOG_LEVEL DEBUG_LEVEL
#endif

#define INT_INFO(FORMAT, ...) ds_log(INFO_LEVEL, fileName(__FILE__), __LINE__, __FUNCTION__, FORMAT, ##__VA_ARGS__ )
#define INT_INFO(FORMAT, ...) ds_log(DEBUG_LEVEL, fileName(__FILE__), __LINE__, __FUNCTION__, FORMAT, ##__VA_ARGS__ )
Comment thread ds/manager.cpp
Comment on lines 75 to +79
if ((nullptr == pDLHandle) || (nullptr == symbols)) {
INT_ERROR("Invalid DL Handle or symbolsPtr");
printf("Invalid DL Handle or symbolsPtr");
}
else {
INT_INFO("numberOfSymbols = %d",numberOfSymbols);
printf("numberOfSymbols = %d",numberOfSymbols);
Comment on lines 105 to 107
for (std::vector<AudioOutputPortType>::const_iterator it = _aPortTypes.begin(); it != _aPortTypes.end(); it++) {
printf("\nYESH: supportedTypes _aPortTypes *it %s enabled %d", it->toString().c_str(), it->isEnabled());
if (it->isEnabled()) {
Comment thread rpc/srv/dsAudio.c Outdated
Comment thread rpc/srv/dsAudio.c Outdated
Comment thread ds/include/dslogger.h
Comment on lines 48 to 50
#ifndef DS_LOG_LEVEL
#define DS_LOG_LEVEL ERROR_LEVEL
#define DS_LOG_LEVEL DEBUG_LEVEL
#endif
https://ccp.sys.comcast.net/browse/RDKEVD-6226

RDKEVD-8726:Audio Remains Muted and Volume Reports 0 After Standby Reboot When Panel Is Woken Up via FFV
https://ccp.sys.comcast.net/browse/RDKEVD-8726
Copilot AI review requested due to automatic review settings September 3, 2026 09:36

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

It introduces production-unfriendly debug/printf logging (including unprofessional markers) and alters logging severity semantics in a way that can disrupt log filtering and operational behavior.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Review details

Suppressed comments (5)

ds/include/dslogger.h:52

  • INT_INFO is currently logged with DEBUG_LEVEL, and DS_LOG_LEVEL defaults to DEBUG_LEVEL. This mislabels Info messages as Debug (and can break severity-based filtering in DS_RegisterForLog), while also enabling debug logging by default in all builds that don't override DS_LOG_LEVEL.
#ifndef DS_LOG_LEVEL
#define DS_LOG_LEVEL DEBUG_LEVEL
#endif

#define INT_INFO(FORMAT, ...)       ds_log(DEBUG_LEVEL, fileName(__FILE__), __LINE__, __FUNCTION__, FORMAT,  ##__VA_ARGS__ )

ds/manager.cpp:79

  • Using printf() here bypasses the dslogger callback/formatting, lacks newlines (likely to be buffered/concatenated), and can introduce build warnings/errors due to missing includes in this TU. Use the existing INT_* logging macros instead.
    if ((nullptr == pDLHandle) || (nullptr == symbols)) {
        printf("Invalid DL Handle or symbolsPtr");
    }
    else {
        printf("numberOfSymbols = %d",numberOfSymbols);

ds/manager.cpp:108

  • These printf() calls bypass the device settings logging framework and omit newlines, which can make logs hard to correlate and may be buffered/lost depending on stdout configuration. Prefer INT_INFO/INT_DEBUG so logs are routed consistently (and can be suppressed when needed).

This issue also appears on line 345 of the same file.

    printf("Entering capabilityType = 0x%08X", capabilityType);
    dlerror(); // clear old error
    pDLHandle = dlopen(RDK_DSHAL_NAME, RTLD_LAZY);
    
    if (nullptr == pDLHandle) {

ds/manager.cpp:349

  • This block introduces additional printf() logging (no newline, bypasses dslogger) and also reduces readability via one-line lock scope and unbraced if statements. Using INT_INFO and adding braces keeps logging consistent and makes the deinit sequencing easier to audit.
	{std::lock_guard<std::mutex> lock(gManagerInitMutex);
	printf("Entering ... count %d with thread id %lu",IsInitialized,pthread_self());
	if(IsInitialized>0)IsInitialized--;
	if (0 == IsInitialized) {	
	

ds/audioOutputPortConfig.cpp:123

  • Use the existing dslogger macros instead of printf() so this informational message can be filtered/suppressed consistently and include a terminating newline for readability.
    if ( -1 == access("/opt/dsMgrDumpDeviceConfigs", F_OK) ) {
        printf("\nDumping of Device configs is disabled");
        return;
  • Files reviewed: 6/6 changed files
  • Comments generated: 1
  • Review effort level: Lite

Comment on lines 117 to 120
if (nullptr == config) {
INT_ERROR("Audio config is NULL");
printf("\nAudio config is NULL");
return;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants