diff options
author | Rui Miguel Silva <rui.silva@linaro.org> | 2019-06-12 06:00:28 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2019-06-21 16:31:15 -0400 |
commit | e0c76a7d3428824c4f360982efcfa085d8d7fb85 (patch) | |
tree | 180f6c57166cbc6cab80eeed3d0ce2302a762b83 /drivers/staging | |
parent | 13d93380fca826e49c42e8d83fc8a077cabbe6b8 (diff) | |
download | linux-e0c76a7d3428824c4f360982efcfa085d8d7fb85.tar.bz2 |
media: imx7-media-csi: get csi upstream endpoint
When the upstream endpoint is neither a mux nor a CSI2 module, just get
the source pad directly upstream from the CSI.
Reported-by: Sebastien Szymanski <sebastien.szymanski@armadeus.com>
Signed-off-by: Rui Miguel Silva <rui.silva@linaro.org>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/media/imx/imx7-media-csi.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/staging/media/imx/imx7-media-csi.c b/drivers/staging/media/imx/imx7-media-csi.c index 9101566f3f67..f775870df7e0 100644 --- a/drivers/staging/media/imx/imx7-media-csi.c +++ b/drivers/staging/media/imx/imx7-media-csi.c @@ -442,6 +442,14 @@ static int imx7_csi_get_upstream_endpoint(struct imx7_csi *csi, src = &csi->src_sd->entity; + /* + * if the source is neither a mux or csi2 get the one directly upstream + * from this csi + */ + if (src->function != MEDIA_ENT_F_VID_IF_BRIDGE && + src->function != MEDIA_ENT_F_VID_MUX) + src = &csi->sd.entity; + skip_video_mux: /* get source pad of entity directly upstream from src */ pad = imx_media_pipeline_pad(src, 0, 0, true); |