libcamera: pipeline_handler: Split request queueing
In order to prepare to handle synchronization fences at Request queueing time, split the PipelineHandler::queueRequest() function in two, by creating a list of waiting requests and introducing the doQueueRequest() function that queues requests to the device in the order the pipeline has received them. Signed-off-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <memory>
|
||||
#include <queue>
|
||||
#include <set>
|
||||
#include <string>
|
||||
#include <sys/types.h>
|
||||
@@ -76,9 +77,14 @@ private:
|
||||
void mediaDeviceDisconnected(MediaDevice *media);
|
||||
virtual void disconnect();
|
||||
|
||||
void doQueueRequest(Request *request);
|
||||
void doQueueRequests();
|
||||
|
||||
std::vector<std::shared_ptr<MediaDevice>> mediaDevices_;
|
||||
std::vector<std::weak_ptr<Camera>> cameras_;
|
||||
|
||||
std::queue<Request *> waitingRequests_;
|
||||
|
||||
const char *name_;
|
||||
|
||||
friend class PipelineHandlerFactory;
|
||||
|
||||
@@ -58,6 +58,15 @@ TRACEPOINT_EVENT_INSTANCE(
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
request_device_queue,
|
||||
TP_ARGS(
|
||||
libcamera::Request *, req
|
||||
)
|
||||
)
|
||||
|
||||
TRACEPOINT_EVENT_INSTANCE(
|
||||
libcamera,
|
||||
request,
|
||||
|
||||
Reference in New Issue
Block a user