lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 13 Jul 2016 12:11:34 -0700
From:	Bjorn Andersson <bjorn.andersson@...aro.org>
To:	Lee Jones <lee.jones@...aro.org>
Cc:	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	kernel@...inux.com, maxime.coquelin@...com, ohad@...ery.com,
	linux-remoteproc@...r.kernel.org,
	Ludovic Barre <ludovic.barre@...com>
Subject: Re: [PATCH 2/5] remoteproc: core: Add rproc OF look-up functions

On Thu 05 May 06:29 PDT 2016, Lee Jones wrote:

Lee,

I ran into this topic again while looking into some unrelated things.

> diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c
> +struct rproc *of_rproc_byindex(struct device_node *np, int index)
> +{
> +	struct rproc *rproc;
> +	struct device_node *rproc_node;
> +	struct platform_device *pdev;
> +	struct klist_iter i;
> +
> +	if (index < 0)
> +		return ERR_PTR(-EINVAL);
> +
> +	rproc_node = of_parse_phandle(np, "rprocs", index);
> +	if (!rproc_node)

As I stated before I would like for you to use the existing rproc_list,
as done in rproc_get_by_phandle() today.

But as you resend this patch, could you please make this check fallback
to also checking for "ti,rproc", then simply drop the existing
rproc_get_by_phandle() and change the call to
of_rproc_byindex(dev->of_node, 0) in wkup_m3_ipc.c?

That way we're backwards compatible with the TI wakeup M3, without
having to maintain the then non-standard generic rproc phandle resolver.

> +		return ERR_PTR(-ENODEV);
> +
> +	pdev = of_find_device_by_node(rproc_node);
> +	if (!pdev)
> +		return ERR_PTR(-ENODEV);
> +
> +	klist_iter_init(&rprocs, &i);
> +	while ((rproc = next_rproc(&i)) != NULL)
> +		if (rproc->dev.parent == &pdev->dev)
> +			break;
> +	klist_iter_exit(&i);
> +
> +	return rproc;
> +}
> +EXPORT_SYMBOL(of_rproc_byindex);

Regards,
Bjorn

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ