libcamera: camera_sensor: Prepare for multi-subdev camera sensors

While most camera sensors are exposed to userspace as a single subdev,
this is not always the case. A notable exception is the smiapp driver,
which exposes two or three subdevs. The subdev at the output of the
camera sensor will thus have more than one pad. Prepare for this by
removing the single-pad restriction, and locating the source pad
dynamically.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
This commit is contained in:
Laurent Pinchart
2020-05-02 16:12:35 +03:00
parent 3697c93a8d
commit 3d42c67aab
2 changed files with 16 additions and 9 deletions
+2
View File
@@ -70,6 +70,8 @@ protected:
private:
const MediaEntity *entity_;
std::unique_ptr<V4L2Subdevice> subdev_;
unsigned int pad_;
std::string model_;
std::vector<unsigned int> mbusCodes_;