summaryrefslogtreecommitdiff
path: root/src/libcamera/pipeline/ipu3/cio2.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libcamera/pipeline/ipu3/cio2.cpp')
-rw-r--r--src/libcamera/pipeline/ipu3/cio2.cpp18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/libcamera/pipeline/ipu3/cio2.cpp b/src/libcamera/pipeline/ipu3/cio2.cpp
index c7fabb98..0ef3bc04 100644
--- a/src/libcamera/pipeline/ipu3/cio2.cpp
+++ b/src/libcamera/pipeline/ipu3/cio2.cpp
@@ -238,15 +238,27 @@ int CIO2Device::start()
availableBuffers_.push(buffer.get());
ret = output_->streamOn();
- if (ret)
+ if (ret) {
freeBuffers();
+ return ret;
+ }
- return ret;
+ ret = csi2_->setFrameStartEnabled(true);
+ if (ret) {
+ stop();
+ return ret;
+ }
+
+ return 0;
}
int CIO2Device::stop()
{
- int ret = output_->streamOff();
+ int ret;
+
+ csi2_->setFrameStartEnabled(false);
+
+ ret = output_->streamOff();
freeBuffers();