Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1615803

Re: [PATCH v2 03/13] drm/meson: Add support for components

From Daniel Vetter <daniel@ffwll.ch>
Newsgroups linux.kernel
Subject Re: [PATCH v2 03/13] drm/meson: Add support for components
Date 2017-04-04 11:10 +0200
Message-ID <tssDn-2Qa-1@gated-at.bofh.it> (permalink)
References <tntTr-5b0-9@gated-at.bofh.it> <tntTt-5b0-63@gated-at.bofh.it> <tsstI-2xK-21@gated-at.bofh.it> <tssDn-2Qa-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Apr 04, 2017 at 11:08:26AM +0200, Neil Armstrong wrote:
> On 04/04/2017 10:59 AM, Daniel Vetter wrote:
> > On Tue, Mar 21, 2017 at 04:25:40PM +0100, Neil Armstrong wrote:
> >> +static int meson_drv_probe(struct platform_device *pdev)
> >> +{
> >> +	struct component_match *match = NULL;
> >> +	struct device_node *np = pdev->dev.of_node;
> >> +	struct device_node *ep, *remote;
> >> +	int count = 0;
> >> +
> >> +	for_each_endpoint_of_node(np, ep) {
> >> +		remote = of_graph_get_remote_port_parent(ep);
> >> +		if (!remote || !of_device_is_available(remote))
> >> +			continue;
> >> +
> >> +		count += meson_probe_remote(pdev, &match, np, remote);
> >> +	}
> >> +
> >> +	/* If some endpoints were found, initialize the nodes */
> >> +	if (count) {
> > 
> > What if you have more than 1 endpoint described, but module load order
> > conspires against you to only initialize 1 at first?
> 
> As I understood, the component_bind_all() will fail until all modules are loaded
> even in wrong order, no ?
> I tested with multiple combinations and it worked like a charm... maybe I missed
> something here !

I misread your code, looks all fine.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH v2 03/13] drm/meson: Add support for components Daniel Vetter <daniel@ffwll.ch> - 2017-04-04 11:00 +0200
  Re: [PATCH v2 03/13] drm/meson: Add support for components Daniel Vetter <daniel@ffwll.ch> - 2017-04-04 11:10 +0200
  Re: [PATCH v2 03/13] drm/meson: Add support for components Neil Armstrong <narmstrong@baylibre.com> - 2017-04-04 11:10 +0200

csiph-web