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


Groups > linux.kernel > #1570818

Re: [PATCH v7 11/14] sata: ahci-da850: un-hardcode the MPY bits

From Sekhar Nori <nsekhar@ti.com>
Newsgroups linux.kernel
Subject Re: [PATCH v7 11/14] sata: ahci-da850: un-hardcode the MPY bits
Date 2017-01-31 16:20 +0100
Message-ID <t5InT-2gX-11@gated-at.bofh.it> (permalink)
References <t5h4l-2H9-3@gated-at.bofh.it> <t5h4n-2H9-61@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Monday 30 January 2017 03:32 PM, Bartosz Golaszewski wrote:

> +	/*
> +	 * The second clock used by ahci-da850 is the external REFCLK. If we
> +	 * didn't get it from ahci_platform_get_resources(), let's try to
> +	 * specify the con_id in clk_get().
> +	 */
> +	if (!hpriv->clks[1]) {
> +		clk = clk_get(dev, "refclk");
> +		if (IS_ERR(clk)) {
> +			dev_err(dev, "unable to obtain the reference clock");
> +			return -ENODEV;
> +		} else {
> +			hpriv->clks[1] = clk;
> +		}

This results in a checkpatch warning about the unneeded else. I fixed 
this locally to look like:

+        */
+       if (!hpriv->clks[1]) {
+               clk = clk_get(dev, "refclk");
+               if (IS_ERR(clk)) {
+                       dev_err(dev, "unable to obtain the reference clock");
+                       return -ENODEV;
+               }
+
+               hpriv->clks[1] = clk;
+       }

Thanks,
Sekhar

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


Thread

Re: [PATCH v7 11/14] sata: ahci-da850: un-hardcode the MPY bits Sekhar Nori <nsekhar@ti.com> - 2017-01-31 16:20 +0100

csiph-web