From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [RFC PATCHv3 1/2] ARM: socfpga: initial support for Altera's SOCFPGA platform
Date: Wed, 18 Jul 2012 07:27:31 +0000 [thread overview]
Message-ID: <201207180727.32041.arnd@arndb.de> (raw)
In-Reply-To: <1342572656-5205-2-git-send-email-dinguyen@altera.com>
On Wednesday 18 July 2012, dinguyen at altera.com wrote:
> +struct clk {
> + unsigned long rate;
> +};
> +
> +static struct clk apb_pclk = { .rate = 200000000};
> +static struct clk i2c_clk = { .rate = 100000000};
> +static struct clk spim_clk = { .rate = 100000000};
> +static struct clk mpu_pclk = { .rate = SOCFPGA_MPU_PERIHCLK_FREQ_HZ};
> +static struct clk l4_main_clk = { .rate = SOCFPGA_L4_MAIN_CLK};
> +
> +static struct clk_lookup lookups[] = {
> + { .clk = &apb_pclk, .con_id = "apb_pclk", },
I have one comment left: You still define "struct clk" privately here,
which means that any driver using clk_get and clk_get_rate will
access an invalid data structure and not get the rate you put in here.
I believe you just need to be using clk_register_fixed_rate()
rather than defining the clk structures statically.
Arnd
next prev parent reply other threads:[~2012-07-18 7:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-18 0:50 [RFC PATCHv3 0/2] arm: socfpga: Add initial support for Altera's SOCFPGA HW dinguyen at altera.com
2012-07-18 0:50 ` [RFC PATCHv3 1/2] ARM: socfpga: initial support for Altera's SOCFPGA platform dinguyen at altera.com
2012-07-18 7:14 ` Thomas Petazzoni
2012-07-18 10:04 ` Pavel Machek
2012-07-18 7:27 ` Arnd Bergmann [this message]
2012-07-18 0:50 ` [RFC PATCHv3 2/2] ARM: socfpga: Add DTS bindings for Altera's SOCFPGA dinguyen at altera.com
2012-07-18 7:16 ` Thomas Petazzoni
2012-07-18 10:13 ` Pavel Machek
2012-07-18 11:19 ` Thomas Petazzoni
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=201207180727.32041.arnd@arndb.de \
--to=arnd@arndb.de \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.