From 500e99174aeb3741023ec1a217c4ad5614511eef Mon Sep 17 00:00:00 2001 From: Kieran Bingham Date: Wed, 24 Mar 2021 09:37:20 +0000 Subject: ipa: ipu3: Do not set controls during configure The configure operation is synchronous and should not send events back to the pipeline handler. If information needs to be returned from configure it should be handled through the interface directly. Move the initial call to setControls() out of configure() and into the start() method which is called after the IPA running_ state is updated. Reviewed-by: Laurent Pinchart Signed-off-by: Kieran Bingham --- src/ipa/ipu3/ipu3.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/ipa/ipu3') diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp index a5c5e029..34a907f2 100644 --- a/src/ipa/ipu3/ipu3.cpp +++ b/src/ipa/ipu3/ipu3.cpp @@ -32,7 +32,7 @@ public: { return 0; } - int start() override { return 0; } + int start() override; void stop() override {} void configure(const std::map &entityControls, @@ -63,6 +63,13 @@ private: uint32_t maxGain_; }; +int IPAIPU3::start() +{ + setControls(0); + + return 0; +} + void IPAIPU3::configure(const std::map &entityControls, [[maybe_unused]] const Size &bdsOutputSize) { @@ -90,8 +97,6 @@ void IPAIPU3::configure(const std::map &entityControls minGain_ = std::max(itGain->second.min().get(), 1); maxGain_ = itGain->second.max().get(); gain_ = maxGain_; - - setControls(0); } void IPAIPU3::mapBuffers(const std::vector &buffers) -- cgit v1.2.1