linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kuninori Morimoto <kuninori.morimoto.gx@gmail.com>
To: Simon <horms@verge.net.au>, broonie@kernel.org
Cc: Magnus <magnus.damm@gmail.com>,
	linux-sh@vger.kernel.org,
	Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>,
	alsa-devel@alsa-project.org
Subject: [PATCH 3/7] ARM: shmobile: bockw: remove old style audio clock
Date: Mon, 14 Apr 2014 00:56:57 +0000	[thread overview]
Message-ID: <87ob0420fc.wl%kuninori.morimoto.gx@gmail.com> (raw)
In-Reply-To: <87sipg20h1.wl%kuninori.morimoto.gx@gmail.com>

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Current audio clock didn't have dependency to device/driver,
but, it was not good design for DT support.
To avoid branch merge conflict issue,
it is using this load map, and this patch is 3) part.
 1) add new style clock in platform
 2) add new style clock method in driver
 3) remove old tyle clock from platform

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/mach-shmobile/board-bockw.c |   10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-shmobile/board-bockw.c b/arch/arm/mach-shmobile/board-bockw.c
index b4122f8..1aca107 100644
--- a/arch/arm/mach-shmobile/board-bockw.c
+++ b/arch/arm/mach-shmobile/board-bockw.c
@@ -591,6 +591,7 @@ static void __init bockw_init(void)
 {
 	void __iomem *base;
 	struct clk *clk;
+	struct platform_device *pdev;
 	int i;
 
 	r8a7778_clock_init();
@@ -673,9 +674,6 @@ static void __init bockw_init(void)
 	}
 
 	/* for Audio */
-	clk = clk_get(NULL, "audio_clk_b");
-	clk_set_rate(clk, 24576000);
-	clk_put(clk);
 	rsnd_codec_power(5, 1); /* enable ak4642 */
 
 	platform_device_register_simple(
@@ -684,11 +682,15 @@ static void __init bockw_init(void)
 	platform_device_register_simple(
 		"ak4554-adc-dac", 1, NULL, 0);
 
-	platform_device_register_resndata(
+	pdev = platform_device_register_resndata(
 		&platform_bus, "rcar_sound", -1,
 		rsnd_resources, ARRAY_SIZE(rsnd_resources),
 		&rsnd_info, sizeof(rsnd_info));
 
+	clk = clk_get(&pdev->dev, "clk_b");
+	clk_set_rate(clk, 24576000);
+	clk_put(clk);
+
 	for (i = 0; i < ARRAY_SIZE(rsnd_card_info); i++) {
 		struct platform_device_info cardinfo = {
 			.parent         = &platform_bus,
-- 
1.7.9.5


  parent reply	other threads:[~2014-04-14  0:56 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-14  0:55 [PATCH 0/7] ARM: shmobile: swtich audio settings to new style, and remove compatibility code from dr Kuninori Morimoto
2014-04-14  0:56 ` [PATCH 1/7] ARM: shmobile: r8a7778: remove old style audio clock Kuninori Morimoto
2014-04-14  0:56 ` [PATCH 2/7] ARM: shmobile: r8a7790: " Kuninori Morimoto
2014-04-14  0:56 ` Kuninori Morimoto [this message]
2014-04-14  0:57 ` [PATCH 4/7] ARM: shmobile: bockw: switch to use dai info for R-Car sound Kuninori Morimoto
2014-04-14  0:57 ` [PATCH 5/7] ARM: shmobile: lager: " Kuninori Morimoto
2014-04-14  0:57 ` [PATCH 6/7] ASoC: rsnd: remove old clock style support Kuninori Morimoto
2014-04-14  0:57 ` [PATCH 7/7] ASoC: rsnd: remove compatibility code Kuninori Morimoto
2014-04-14 19:03   ` Mark Brown
2014-05-08  0:15     ` Kuninori Morimoto
2014-05-08  5:28       ` Mark Brown
2014-04-14  3:56 ` [PATCH 0/7] ARM: shmobile: swtich audio settings to new style, and remove compatibility code fro Simon Horman
2014-04-14 19:01   ` Mark Brown
2014-04-14 22:46     ` Simon Horman

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=87ob0420fc.wl%kuninori.morimoto.gx@gmail.com \
    --to=kuninori.morimoto.gx@gmail.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=horms@verge.net.au \
    --cc=kuninori.morimoto.gx@renesas.com \
    --cc=linux-sh@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    /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).