linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: t.figa@samsung.com (Tomasz Figa)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH V2 04/10] clk/samsung: add support for multiple clock providers
Date: Thu, 23 Jan 2014 19:24:01 +0100	[thread overview]
Message-ID: <52E15E41.7020600@samsung.com> (raw)
In-Reply-To: <1389099548-14649-5-git-send-email-rahul.sharma@samsung.com>

Hi Rahul,

The patch looks mostly fine now, but I still have one inline comment.

On 07.01.2014 13:59, Rahul Sharma wrote:
> Samsung CCF helper functions do not provide support to
> register multiple Clock Providers for a given SoC. Due to
> this limitation SoC platforms are not able to use these
> helpers for registering multiple clock providers and are
> forced to bypass this layer.
>
> This layer is modified accordingly to enable the support.
>
> Clock file for exynos4, exynos5250, exynos5420, exynos5440
[snip]
>   /* setup the essentials required to support clock lookup using ccf */
> -void __init samsung_clk_init(struct device_node *np, void __iomem *base,
> -			     unsigned long nr_clks)
> +struct samsung_clk_provider *__init samsung_clk_init(struct device_node *np,
> +			void __iomem *base, unsigned long nr_clks)
>   {
> -	reg_base = base;
> +	struct samsung_clk_provider *ctx;
> +	struct clk **clk_table;
> +	int ret;
> +
> +	ctx = kzalloc(sizeof(struct samsung_clk_provider), GFP_KERNEL);
> +	if (!ctx)
> +		panic("could not allocate clock provider context.\n");
>
>   	clk_table = kzalloc(sizeof(struct clk *) * nr_clks, GFP_KERNEL);
>   	if (!clk_table)
>   		panic("could not allocate clock lookup table\n");
>
> +	ctx->reg_base = base;
> +	ctx->clk_data.clks = clk_table;
> +	ctx->clk_data.clk_num = nr_clks;
> +	ctx->lock = __SPIN_LOCK_UNLOCKED(lock);

spin_lock_init(&ctx->lock);

Best regards,
Tomasz

  reply	other threads:[~2014-01-23 18:24 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-07 12:58 [PATCH V2 00/10] exynos: add basic support for exynos5260 SoC Rahul Sharma
2014-01-07 12:58 ` [PATCH V2 01/10] clk/exynos5410: move suspend/resume handling to SoC driver Rahul Sharma
2014-01-23 18:19   ` Tomasz Figa
2014-01-07 12:59 ` [PATCH V2 02/10] ARM: EXYNOS: initial board support for exynos5260 SoC Rahul Sharma
2014-01-07 13:24   ` Arnd Bergmann
2014-01-08  5:32     ` Rahul Sharma
2014-01-07 12:59 ` [PATCH V2 03/10] pinctrl: exynos: add exynos5260 SoC specific data Rahul Sharma
2014-01-07 13:31   ` Arnd Bergmann
2014-01-23 18:38     ` Tomasz Figa
2014-01-07 12:59 ` [PATCH V2 04/10] clk/samsung: add support for multiple clock providers Rahul Sharma
2014-01-23 18:24   ` Tomasz Figa [this message]
2014-01-07 12:59 ` [PATCH V2 05/10] clk/samsung: add support for pll2550xx Rahul Sharma
2014-01-23 18:40   ` Tomasz Figa
2014-01-07 12:59 ` [PATCH V2 06/10] clk/samsung: add support for pll2650xx Rahul Sharma
2014-01-23 18:46   ` Tomasz Figa
2014-01-07 12:59 ` [PATCH V2 07/10] clk/exynos5260: add macros and documentation for exynos5260 Rahul Sharma
2014-01-07 12:59 ` [PATCH V2 08/10] clk/exynos5260: add clock file " Rahul Sharma
2014-01-07 12:59 ` [PATCH V2 09/10] ARM: dts: add dts files for exynos5260 SoC Rahul Sharma
2014-01-07 12:59 ` [PATCH V2 10/10] ARM: dts: add dts files for xyref5260 board Rahul Sharma

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=52E15E41.7020600@samsung.com \
    --to=t.figa@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.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).