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


Groups > linux.kernel > #1554151

Re: [PATCH v1 3/3] thermal: zx2967: add thermal driver for ZTE's zx2967 family

From Shawn Guo <shawnguo@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH v1 3/3] thermal: zx2967: add thermal driver for ZTE's zx2967 family
Date 2017-01-09 09:50 +0100
Message-ID <sXDOq-1PC-13@gated-at.bofh.it> (permalink)
References <sWRTs-4rO-9@gated-at.bofh.it> <sWRTs-4rO-7@gated-at.bofh.it> <sXyvo-6Sa-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, Jan 09, 2017 at 11:00:38AM +0800, Jun Nie wrote:
> >+static int zx2967_thermal_resume(struct device *dev)
> >+{
> >+	struct platform_device *pdev = to_platform_device(dev);
> >+	struct zx2967_thermal_priv *priv = platform_get_drvdata(pdev);
> >+	int error;
> >+
> >+	error = clk_prepare_enable(priv->clk_gate);
> >+	if (error)
> Use IS_ERR(ret) to check error.

No.  IS_ERR() checks on pointer, while clk_prepare_enable() returns
integer.

Shawn

> >+		return error;
> >+
> >+	error = clk_prepare_enable(priv->pclk);
> >+	if (error)
> Ditto.
> >+		return error;
> >+
> >+	dev_info(dev, "resumed\n");
> >+
> >+	return 0;
> >+}

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


Thread

[PATCH v1 3/3] thermal: zx2967: add thermal driver for ZTE's zx2967 family Baoyou Xie <baoyou.xie@linaro.org> - 2017-01-07 06:40 +0100
  Re: [PATCH v1 3/3] thermal: zx2967: add thermal driver for ZTE's  zx2967 family Shawn Guo <shawnguo@kernel.org> - 2017-01-09 04:10 +0100
  Re: [PATCH v1 3/3] thermal: zx2967: add thermal driver for ZTE's  zx2967 family Jun Nie <jun.nie@linaro.org> - 2017-01-09 04:10 +0100
    Re: [PATCH v1 3/3] thermal: zx2967: add thermal driver for ZTE's  zx2967 family Shawn Guo <shawnguo@kernel.org> - 2017-01-09 09:50 +0100

csiph-web