mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: <Eugen.Hristev@microchip.com>
To: <luis.oliveira@synopsys.com>, <linux-media@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>
Cc: <joao.pinto@synopsys.com>, <festevam@gmail.com>,
	<mchehab@kernel.org>, <gregkh@linuxfoundation.org>,
	<davem@davemloft.net>, <akpm@linux-foundation.org>,
	<arnd@arndb.de>, <hans.verkuil@cisco.com>,
	<laurent.pinchart@ideasonboard.com>, <geert@linux-m68k.org>,
	<narmstrong@baylibre.com>, <p.zabel@pengutronix.de>,
	<treding@nvidia.com>, <maxime.ripard@bootlin.com>,
	<todor.tomov@linaro.org>
Subject: Re: [V3, 4/4] media: platform: dwc: Add MIPI CSI-2 controller driver
Date: Mon, 10 Dec 2018 12:39:52 +0000	[thread overview]
Message-ID: <ea589e15-a39d-84c0-f0ee-0f434273027b@microchip.com> (raw)
In-Reply-To: <1539953556-35762-5-git-send-email-lolivei@synopsys.com>



On 19.10.2018 15:52, Luis Oliveira wrote:
> Add the Synopsys MIPI CSI-2 controller driver. This
> controller driver is divided in platform dependent functions
> and core functions. It also includes a platform for future
> DesignWare drivers.
> 
> Signed-off-by: Luis Oliveira <lolivei@synopsys.com>
> ---
> Changelog
> v2-V3
> - exposed IPI settings to userspace
> - fixed headers
[...]

snip


> +
> +static int
> +dw_mipi_csi_parse_dt(struct platform_device *pdev, struct mipi_csi_dev *dev)
> +{
> +	struct device_node *node = pdev->dev.of_node;
> +	struct v4l2_fwnode_endpoint endpoint;

Hello Luis,

I believe you have to initialize "endpoint" here correctly, otherwise 
the parsing mechanism (fwnode_endpoint_parse) will consider you have a 
specific mbus type and fail to probe the endpoint: bail out with debug 
message "expecting bus type not found "

(namely, initialize to zero which is the UNKNOWN mbus type, or , to a 
specific mbus (from DT or whatever source))

Eugen


> +	int ret;
> +
> +	node = of_graph_get_next_endpoint(node, NULL);
> +	if (!node) {
> +		dev_err(&pdev->dev, "No port node at %s\n",
> +				pdev->dev.of_node->full_name);
> +		return -EINVAL;
> +	}
> +
> +	ret = v4l2_fwnode_endpoint_parse(of_fwnode_handle(node), &endpoint);
> +	if (ret)
> +		goto err;
> +
> +	dev->index = endpoint.base.port - 1;
> +	if (dev->index >= CSI_MAX_ENTITIES) {
> +		ret = -ENXIO;
> +		goto err;
> +	}
> +	dev->hw.num_lanes = endpoint.bus.mipi_csi2.num_data_lanes;
> +
> +err:
> +	of_node_put(node);
> +	return ret;
> +}
> +

snip

  parent reply	other threads:[~2018-12-10 12:39 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-19 12:52 [V3, 0/4] platform: dwc: Add of DesignWare MIPI CSI-2 Host Luis Oliveira
2018-10-19 12:52 ` [V3, 1/4] Documentation: dt-bindings: phy: Document the Synopsys MIPI DPHY Rx bindings Luis Oliveira
2018-10-24 17:36   ` Rob Herring
2018-11-13  8:58     ` Luis Oliveira
2018-11-13  9:30     ` Luis de Oliveira
2018-11-14 20:08   ` Laurent Pinchart
2018-10-19 12:52 ` [V3, 2/4] media: platform: dwc: Add DW MIPI DPHY Rx platform Luis Oliveira
2019-01-07 11:58   ` Sakari Ailus
2019-01-08  9:17     ` Luis de Oliveira
2018-10-19 12:52 ` [V3, 3/4] Documentation: dt-bindings: media: Document bindings for DW MIPI CSI-2 Host Luis Oliveira
2018-10-24 17:40   ` Rob Herring
2018-11-13 10:00     ` Luis de Oliveira
2018-11-14 20:16       ` Laurent Pinchart
2018-10-24 17:41   ` Rob Herring
2018-11-13 10:00     ` Luis de Oliveira
2019-01-11 15:29   ` Eugen.Hristev
2018-10-19 12:52 ` [V3, 4/4] media: platform: dwc: Add MIPI CSI-2 controller driver Luis Oliveira
2018-11-14 20:22   ` Laurent Pinchart
2019-01-10 17:00     ` Luis de Oliveira
2018-12-10 12:39   ` Eugen.Hristev [this message]
2019-01-10 16:11     ` Luis de Oliveira
2019-01-09 13:07   ` Eugen.Hristev
2019-01-10 16:18     ` Luis de Oliveira
2019-01-11  7:25       ` Eugen.Hristev
2019-01-11  8:11         ` Luis de Oliveira
2019-01-11  9:49           ` Eugen.Hristev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ea589e15-a39d-84c0-f0ee-0f434273027b@microchip.com \
    --to=eugen.hristev@microchip.com \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=festevam@gmail.com \
    --cc=geert@linux-m68k.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=hans.verkuil@cisco.com \
    --cc=joao.pinto@synopsys.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=luis.oliveira@synopsys.com \
    --cc=maxime.ripard@bootlin.com \
    --cc=mchehab@kernel.org \
    --cc=narmstrong@baylibre.com \
    --cc=p.zabel@pengutronix.de \
    --cc=todor.tomov@linaro.org \
    --cc=treding@nvidia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®