From patchwork Tue Mar 25 04:30:19 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 3885181 Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id B488A9F2B6 for ; Tue, 25 Mar 2014 04:30:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id AF7A42026C for ; Tue, 25 Mar 2014 04:30:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D37812020E for ; Tue, 25 Mar 2014 04:30:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750929AbaCYEaV (ORCPT ); Tue, 25 Mar 2014 00:30:21 -0400 Received: from mail-pa0-f46.google.com ([209.85.220.46]:35027 "EHLO mail-pa0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750834AbaCYEaU (ORCPT ); Tue, 25 Mar 2014 00:30:20 -0400 Received: by mail-pa0-f46.google.com with SMTP id kp14so6412787pab.33 for ; Mon, 24 Mar 2014 21:30:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:message-id:from:subject:user-agent:from:to:cc:in-reply-to :references:mime-version:content-type; bh=Tstlh2nF9+KhOzk2lUb6ffcgaDq9FzwW6/Pc9VM0Vok=; b=LB0uUD1caPn6mjYKgC5fACp7sGwFJ/lKHK7OkgAhT2BAOay723M31gzfbHXQQZ3ghF p8fxD5sN8ViPth/zlmkdks62MvD5UbK9S/6F/4jLB9daEP4DiYTdLGStnC9CvRk9ySoh vPonm4u9VfvAFJATiupMkpk2fywymr8N+9oLR7sT0K5C4veCqUnjIY5UVMZcYIiaF2gE N3UjUncrMy4fWzqv5dK5Sqd2frgTJLbfxcbhzsAti1Sdy1VKXpk6HfbLgGlqEwhPfVij YprdcI2D0IV0uUL6qqc3JbqjM0oN8l+WwneXVlBNWr/qwIAp6xB24PqNgFVhiQSmID86 objw== X-Received: by 10.68.110.165 with SMTP id ib5mr75931387pbb.61.1395721820298; Mon, 24 Mar 2014 21:30:20 -0700 (PDT) Received: from morimoto-dell.gmail.com (49.14.32.202.bf.2iij.net. [202.32.14.49]) by mx.google.com with ESMTPSA id x9sm38685216pbu.1.2014.03.24.21.30.18 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 24 Mar 2014 21:30:19 -0700 (PDT) Date: Mon, 24 Mar 2014 21:30:19 -0700 (PDT) Message-ID: <87d2hadhnr.wl%kuninori.morimoto.gx@gmail.com> From: Kuninori Morimoto Subject: [PATCH 4/6] ARM: shmobile: bockw: remove old style audio clock User-Agent: Wanderlust/2.14.0 Emacs/23.3 Mule/6.0 From: Kuninori Morimoto To: Simon Cc: Magnus , linux-sh@vger.kernel.org, Kuninori Morimoto In-Reply-To: <87ior2dhp9.wl%kuninori.morimoto.gx@gmail.com> References: <87ior2dhp9.wl%kuninori.morimoto.gx@gmail.com> MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Kuninori Morimoto 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 --- 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,