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  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Fri, 24 Feb 2012 14:55:15 +0400
From:	Sergei Shtylyov <sshtylyov@...sta.com>
To:	John Crispin <blogic@...nwrt.org>
CC:	Ralf Baechle <ralf@...ux-mips.org>, linux-mips@...ux-mips.org,
	netdev@...r.kernel.org
Subject: Re: [PATCH V2 11/14] NET: MIPS: lantiq: convert etop driver to clkdev
 api

Hello.

On 23-02-2012 20:03, John Crispin wrote:

> Update from old pmu_{dis,en}able() to ckldev api.

> Signed-off-by: John Crispin<blogic@...nwrt.org>
> Cc: netdev@...r.kernel.org
[...]

> diff --git a/drivers/net/ethernet/lantiq_etop.c b/drivers/net/ethernet/lantiq_etop.c
> index e5ec8b1..6b2e4b4 100644
> --- a/drivers/net/ethernet/lantiq_etop.c
> +++ b/drivers/net/ethernet/lantiq_etop.c
[...]
> @@ -886,6 +903,22 @@ ltq_etop_probe(struct platform_device *pdev)
>   	priv->pdev = pdev;
>   	priv->pldata = dev_get_platdata(&pdev->dev);
>   	priv->netdev = dev;
> +
> +	priv->clk_ppe = clk_get(&pdev->dev, NULL);
> +	if (!priv->clk_ppe)
> +		return -ENOENT;
> +	if (ltq_has_gbit()) {
> +		priv->clk_switch = clk_get(&pdev->dev, "switch");
> +		if (!priv->clk_switch)

    clk_get() doesn't retirn NULL, it returns error code.

> +			return -ENOENT;
> +	}
> +	if (ltq_is_ase()) {
> +		priv->clk_ephy = clk_get(&pdev->dev, "ephy");
> +		priv->clk_ephycgu = clk_get(&pdev->dev, "ephycgu");
> +		if (!priv->clk_ephy || !priv->clk_ephycgu)

    Same here.

WBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists