Worker changes for VPD collection mode
This commit updates worker class to handle VPD collection mode. In PST
systems which are in non field mode, VPD collection can be from
hardware, file or in mixed mode. Hence, worker needs to have a parameter
to specify VPD collection mode, so that system VPD, FRUs VPD collection
flow can be redirected accordingly.
Change-Id: I18fa27c5839e1fba639265392c9c305a0e0f0142
Signed-off-by: Souvik Roy <souvikroyofficial10@gmail.com>
diff --git a/vpd-manager/src/worker.cpp b/vpd-manager/src/worker.cpp
index 373883b..be2f7d7 100644
--- a/vpd-manager/src/worker.cpp
+++ b/vpd-manager/src/worker.cpp
@@ -26,8 +26,10 @@
namespace vpd
{
-Worker::Worker(std::string pathToConfigJson, uint8_t i_maxThreadCount) :
- m_configJsonPath(pathToConfigJson), m_semaphore(i_maxThreadCount)
+Worker::Worker(std::string pathToConfigJson, uint8_t i_maxThreadCount,
+ types::VpdCollectionMode i_vpdCollectionMode) :
+ m_configJsonPath(pathToConfigJson), m_semaphore(i_maxThreadCount),
+ m_vpdCollectionMode(i_vpdCollectionMode)
{
// Implies the processing is based on some config JSON
if (!m_configJsonPath.empty())