From: Soren Brinkmann <soren.brinkmann@xilinx.com>
To: Mike Turquette <mturquette@linaro.org>,
"Rafael J. Wysocki" <rjw@rjwysocki.net>,
Viresh Kumar <viresh.kumar@linaro.org>
Cc: "Russell King" <linux@arm.linux.org.uk>,
"Michal Simek" <michal.simek@xilinx.com>,
"Nicolas Ferre" <nicolas.ferre@atmel.com>,
"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>,
linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
cpufreq@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
"Soren Brinkmann" <soren.brinkmann@xilinx.com>,
netdev@vger.kernel.org
Subject: [PATCH 3/4] net: macb: Use clk_find_nearest_rate() API
Date: Mon, 30 Jun 2014 09:56:35 -0700 [thread overview]
Message-ID: <1404147396-8041-4-git-send-email-soren.brinkmann@xilinx.com> (raw)
In-Reply-To: <1404147396-8041-1-git-send-email-soren.brinkmann@xilinx.com>
The Ethernet clock has to match the specified frequencies as accurately
as possible. clk_round_rate() does not specify how rounding is
implemented. Hence use clk_find_nearest_rate().
Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
---
drivers/net/ethernet/cadence/macb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c
index e9daa072ebb4..7b7f5eb1b341 100644
--- a/drivers/net/ethernet/cadence/macb.c
+++ b/drivers/net/ethernet/cadence/macb.c
@@ -223,7 +223,7 @@ static void macb_set_tx_clk(struct clk *clk, int speed, struct net_device *dev)
return;
}
- rate_rounded = clk_round_rate(clk, rate);
+ rate_rounded = clk_find_nearest_rate(clk, rate);
if (rate_rounded < 0)
return;
--
2.0.1.1.gfbfc394
next prev parent reply other threads:[~2014-06-30 16:56 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-30 16:56 [PATCH 0/4] Introduce clk_find_nearest_rate() Soren Brinkmann
2014-06-30 16:56 ` [PATCH 1/4] clk: Introduce 'clk_find_nearest_rate()' Soren Brinkmann
2014-06-30 19:27 ` Boris BREZILLON
2014-07-01 0:12 ` Sören Brinkmann
2014-07-01 6:32 ` Boris BREZILLON
2014-07-01 7:18 ` Boris BREZILLON
2014-07-01 8:23 ` Uwe Kleine-König
2014-07-01 17:52 ` Sören Brinkmann
2014-06-30 16:56 ` [PATCH 2/4] cpufreq: cpu0: Use clk_find_nearest_rate() Soren Brinkmann
2014-06-30 16:56 ` Soren Brinkmann [this message]
2014-06-30 16:56 ` [PATCH 4/4] ARM: zynq: dt: Use properly rounded frequencies in OPPs Soren Brinkmann
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=1404147396-8041-4-git-send-email-soren.brinkmann@xilinx.com \
--to=soren.brinkmann@xilinx.com \
--cc=cpufreq@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=michal.simek@xilinx.com \
--cc=mturquette@linaro.org \
--cc=netdev@vger.kernel.org \
--cc=nicolas.ferre@atmel.com \
--cc=rjw@rjwysocki.net \
--cc=u.kleine-koenig@pengutronix.de \
--cc=viresh.kumar@linaro.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 read-only IMAP folder(s) and NNTP newsgroup(s).