From 0fbd07881ae72d7b94862e62679cf830b3383801 Mon Sep 17 00:00:00 2001 From: Yuvaramachandran Gurusamy <123441336+yuvaramachandran-gurusamy@users.noreply.github.com> Date: Thu, 11 Sep 2025 19:46:46 +0530 Subject: [PATCH 1/2] RDKEMW-7967: Adding retry logic for dsFPInit (#144) * RDKEMW-7967: Adding retry logic for dsFPInit Signed-off-by: yuvaramachandran_gurusamy --- ds/frontPanelConfig.cpp | 26 +++++++++++++++++++++++--- ds/include/frontPanelConfig.hpp | 1 + 2 files changed, 24 insertions(+), 3 deletions(-) diff --git a/ds/frontPanelConfig.cpp b/ds/frontPanelConfig.cpp index e20b0321..e8c932b2 100644 --- a/ds/frontPanelConfig.cpp +++ b/ds/frontPanelConfig.cpp @@ -34,6 +34,7 @@ #include +#include #include "dsError.h" #include "dsUtl.h" #include "frontPanelConfig.hpp" @@ -54,8 +55,7 @@ namespace device { */ FrontPanelConfig::FrontPanelConfig() { - dsFPInit(); - load(); + m_isFPInitialized = false; } @@ -68,6 +68,7 @@ FrontPanelConfig::FrontPanelConfig() FrontPanelConfig::~FrontPanelConfig() { //dsFPTerm(); + m_isFPInitialized = false; } @@ -82,10 +83,29 @@ FrontPanelConfig::~FrontPanelConfig() FrontPanelConfig & FrontPanelConfig::getInstance() { static FrontPanelConfig _singleton; + if (!_singleton.m_isFPInitialized) + { + dsError_t errorCode = dsERR_NONE; + unsigned int retryCount = 1; + do + { + errorCode = dsFPInit(); + if (dsERR_NONE == errorCode) + { + _singleton.load(); + _singleton.m_isFPInitialized = true; + INT_INFO("dsFPInit success\n"); + } + else{ + INT_ERROR("dsFPInit failed with error[%d]. Retrying... (%d/20)\n", errorCode, retryCount); + usleep(50000); // Sleep for 50ms before retrying + } + } + while ((!_singleton.m_isFPInitialized) && (retryCount++ < 20)); + } return _singleton; } - /** * @fn FrontPanelConfig::getIndicator(const string &name) * @brief This API gets the FrontPanelndicator instance corresponding to the name parameter returned by the get supported frontpanel indicator device. diff --git a/ds/include/frontPanelConfig.hpp b/ds/include/frontPanelConfig.hpp index 7592a632..77c243ba 100644 --- a/ds/include/frontPanelConfig.hpp +++ b/ds/include/frontPanelConfig.hpp @@ -58,6 +58,7 @@ class FrontPanelConfig { std::vector _indicators; //!< Container to hold all the FrontPanelIndicator instances. std::vector _textDisplays; //!< Container to hold all the FrontPanelTextDisplay instances. std::vector _colors; //!< Container to hold all the Color instances. + bool m_isFPInitialized; FrontPanelConfig(); virtual ~FrontPanelConfig(); From 8c82428087b9221d7d46af2baef470c541cb3827 Mon Sep 17 00:00:00 2001 From: apatel859 Date: Wed, 17 Sep 2025 01:45:32 +0000 Subject: [PATCH 2/2] 1.0.20 release change log updates --- CHANGELOG.md | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 37340e5b..2f9145d3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,10 +4,19 @@ All notable changes to this project will be documented in this file. Dates are d Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog). +#### [1.0.20](https://github.com/rdkcentral/devicesettings/compare/1.0.19...1.0.20) + +- RDKEMW-7967: Adding retry logic for dsFPInit [`#144`](https://github.com/rdkcentral/devicesettings/pull/144) +- RDKEMW-6149: Implementation of IARM libds event notification APIs [`#121`](https://github.com/rdkcentral/devicesettings/pull/121) +- Merge tag '1.0.19' into develop [`07e4869`](https://github.com/rdkcentral/devicesettings/commit/07e486905ceda01173cd74ab46de5e40b0391577) + #### [1.0.19](https://github.com/rdkcentral/devicesettings/compare/1.0.18...1.0.19) +> 2 September 2025 + - RDKEMW-7503: Volume level failed to persist post reboot (#119) [`#131`](https://github.com/rdkcentral/devicesettings/pull/131) - RDKEMW-6595: Fix coverity issue in devicesettings [`#87`](https://github.com/rdkcentral/devicesettings/pull/87) +- 1.0.19 release change log updates [`4d4e4bf`](https://github.com/rdkcentral/devicesettings/commit/4d4e4bf96c7fcd4c1f3ea8307e06040bd0d4a3d1) - Merge tag '1.0.18' into develop [`11fc3d8`](https://github.com/rdkcentral/devicesettings/commit/11fc3d8b43bb6120192c05087befdfa9e5d67059) #### [1.0.18](https://github.com/rdkcentral/devicesettings/compare/1.0.17...1.0.18) @@ -60,10 +69,16 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog). - 1.0.13 release change log updates [`46313cd`](https://github.com/rdkcentral/devicesettings/commit/46313cdef42716cfec368f6dd8a71508dd9773ba) - RDKEMW-4128 Coverity Integration [`d6306c5`](https://github.com/rdkcentral/devicesettings/commit/d6306c5712f7212794cd29994dd1dda5091bf81d) -#### [1.0.12](https://github.com/rdkcentral/devicesettings/compare/1.0.12-hotfix.2...1.0.12) +#### [1.0.12](https://github.com/rdkcentral/devicesettings/compare/1.0.12-hotfix.3...1.0.12) > 11 June 2025 +#### [1.0.12-hotfix.3](https://github.com/rdkcentral/devicesettings/compare/1.0.12-hotfix.2...1.0.12-hotfix.3) + +> 11 September 2025 + +- RDKEMW-7967: Adding retry logic for dsFPInit [`#144`](https://github.com/rdkcentral/devicesettings/pull/144) + #### [1.0.12-hotfix.2](https://github.com/rdkcentral/devicesettings/compare/1.0.12-hotfix.1...1.0.12-hotfix.2) > 27 August 2025