linux-aspeed.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com>
To: linux-aspeed@lists.ozlabs.org
Subject: Linux-aspeed Digest, Vol 12, Issue 9
Date: Mon, 21 May 2018 09:18:13 -0700	[thread overview]
Message-ID: <2d3a39ca-a1be-4fee-767f-1b9ad95f0b09@linux.intel.com> (raw)
In-Reply-To: <mailman.7.1526695202.29810.linux-aspeed@lists.ozlabs.org>

Hi Lei,

On 5/18/2018 7:00 PM, linux-aspeed-request at lists.ozlabs.org wrote:
> Date: Fri, 18 May 2018 16:57:02 +0800
> From: Lei YU <mine260309@gmail.com>
> To: Michael Turquette <mturquette@baylibre.com>, Stephen Boyd
> 	<sboyd@kernel.org>, Joel Stanley <joel@jms.id.au>, Andrew Jeffery
> 	<andrew@aj.id.au>, Rob Herring <robh+dt@kernel.org>, Mark Rutland
> 	<mark.rutland@arm.com>, Lei YU <mine260309@gmail.com>,
> 	linux-clk at vger.kernel.org, linux-arm-kernel at lists.infradead.org,
> 	linux-aspeed at lists.ozlabs.org, linux-kernel at vger.kernel.org,
> 	devicetree at vger.kernel.org
> Subject: [PATCH] clk: aspeed: Add 24MHz fixed clock
> Message-ID: <1526633822-17138-1-git-send-email-mine260309@gmail.com>
> 
> Add a 24MHz fixed clock.
> This clock will be used for certain devices, e.g. pwm.
> 
> Signed-off-by: Lei YU <mine260309@gmail.com>
> ---
>   drivers/clk/clk-aspeed.c                 | 9 ++++++++-
>   include/dt-bindings/clock/aspeed-clock.h | 1 +
>   2 files changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/clk/clk-aspeed.c b/drivers/clk/clk-aspeed.c
> index 5eb50c3..4664088 100644
> --- a/drivers/clk/clk-aspeed.c
> +++ b/drivers/clk/clk-aspeed.c
> @@ -14,7 +14,7 @@
>   
>   #include <dt-bindings/clock/aspeed-clock.h>
>   
> -#define ASPEED_NUM_CLKS		35
> +#define ASPEED_NUM_CLKS		36
>   
>   #define ASPEED_RESET_CTRL	0x04
>   #define ASPEED_CLK_SELECTION	0x08
> @@ -474,6 +474,13 @@ static int aspeed_clk_probe(struct platform_device *pdev)
>   		return PTR_ERR(hw);
>   	aspeed_clk_data->hws[ASPEED_CLK_BCLK] = hw;
>   
> +	/* Fixed 24MHz clock */
> +	hw = clk_hw_register_fixed_rate(NULL, "fixed-24m", "clkin",
> +					0, 24000000);
> +	if (IS_ERR(hw))
> +		return PTR_ERR(hw);
> +	aspeed_clk_data->hws[ASPEED_CLK_24M] = hw;
> +

According to the datasheet, CLKIN could be a 25MHz too. How can this
change handle the case?

>   	/*
>   	 * TODO: There are a number of clocks that not included in this driver
>   	 * as more information is required:
> diff --git a/include/dt-bindings/clock/aspeed-clock.h b/include/dt-bindings/clock/aspeed-clock.h
> index d3558d8..ff29d8e 100644
> --- a/include/dt-bindings/clock/aspeed-clock.h
> +++ b/include/dt-bindings/clock/aspeed-clock.h
> @@ -38,6 +38,7 @@
>   #define ASPEED_CLK_MAC			32
>   #define ASPEED_CLK_BCLK			33
>   #define ASPEED_CLK_MPLL			34
> +#define ASPEED_CLK_24M			35
>   
>   #define ASPEED_RESET_XDMA		0
>   #define ASPEED_RESET_MCTP		1
> 

           reply	other threads:[~2018-05-21 16:18 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <mailman.7.1526695202.29810.linux-aspeed@lists.ozlabs.org>]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2d3a39ca-a1be-4fee-767f-1b9ad95f0b09@linux.intel.com \
    --to=jae.hyun.yoo@linux.intel.com \
    --cc=linux-aspeed@lists.ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).