[libcamera-devel] [PATCH v2 15/25] libcamera: pipeline: rkisp1: Destroy frame information before completing request

Niklas Söderlund niklas.soderlund at ragnatech.se
Mon Dec 30 13:05:00 CET 2019


The FrameBuffer interface will allow reuse of FrameBuffers form the
request completion handler. For this reason the pipeline must destroy
its cached information freeing the statistics and parameters buffer used
to allow them to be reused directly.

Signed-off-by: Niklas Söderlund <niklas.soderlund at ragnatech.se>
---
 src/libcamera/pipeline/rkisp1/rkisp1.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp
index 46df871a51105ee4..9cd0ab3ad88b35cc 100644
--- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp
+++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp
@@ -989,9 +989,9 @@ void PipelineHandlerRkISP1::tryCompleteRequest(Request *request)
 	if (!info->paramDequeued)
 		return;
 
-	completeRequest(activeCamera_, request);
-
 	data->frameInfo_.destroy(info->frame);
+
+	completeRequest(activeCamera_, request);
 }
 
 void PipelineHandlerRkISP1::bufferReady(Buffer *buffer)
-- 
2.24.1



More information about the libcamera-devel mailing list