From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rui Miguel Silva Subject: [PATCH 06/15] media: staging/imx: add imx7 capture subsystem Date: Thu, 19 Apr 2018 11:18:03 +0100 Message-ID: <20180419101812.30688-7-rui.silva@linaro.org> References: <20180419101812.30688-1-rui.silva@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20180419101812.30688-1-rui.silva@linaro.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: driverdev-devel-bounces@linuxdriverproject.org Sender: "devel" To: mchehab@kernel.org, sakari.ailus@linux.intel.com, Steve Longerbeam , Philipp Zabel , Rob Herring Cc: devel@driverdev.osuosl.org, devicetree@vger.kernel.org, Greg Kroah-Hartman , Ryan Harkin , Rui Miguel Silva , Fabio Estevam , Shawn Guo , linux-media@vger.kernel.org List-Id: devicetree@vger.kernel.org Add imx7 capture subsystem to imx-media core to allow the use some of the existing modules for i.MX5/6 with i.MX7 SoC. Since i.MX7 does not have an IPU set the no_ipu_present flag to differentiate some runtime behaviors. Signed-off-by: Rui Miguel Silva --- drivers/staging/media/imx/imx-media-dev.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/staging/media/imx/imx-media-dev.c b/drivers/staging/media/imx/imx-media-dev.c index a8afe0ec4134..967d172f1447 100644 --- a/drivers/staging/media/imx/imx-media-dev.c +++ b/drivers/staging/media/imx/imx-media-dev.c @@ -484,6 +484,9 @@ static int imx_media_probe(struct platform_device *pdev) goto notifier_cleanup; } + if (of_device_is_compatible(node, "fsl,imx7-capture-subsystem")) + imxmd->no_ipu_present = true; + if (!imxmd->no_ipu_present) { ret = imx_media_add_internal_subdevs(imxmd); if (ret) { @@ -541,6 +544,7 @@ static int imx_media_remove(struct platform_device *pdev) static const struct of_device_id imx_media_dt_ids[] = { { .compatible = "fsl,imx-capture-subsystem" }, + { .compatible = "fsl,imx7-capture-subsystem" }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, imx_media_dt_ids); -- 2.17.0