From patchwork Thu Oct 4 00:33:12 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hilman X-Patchwork-Id: 1544021 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id A6FF13FD56 for ; Thu, 4 Oct 2012 00:33:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964872Ab2JDAdN (ORCPT ); Wed, 3 Oct 2012 20:33:13 -0400 Received: from mail-pb0-f46.google.com ([209.85.160.46]:45191 "EHLO mail-pb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964795Ab2JDAdM (ORCPT ); Wed, 3 Oct 2012 20:33:12 -0400 Received: by mail-pb0-f46.google.com with SMTP id rr4so17004pbb.19 for ; Wed, 03 Oct 2012 17:33:11 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:organization:references:date:in-reply-to :message-id:user-agent:mime-version:content-type:x-gm-message-state; bh=G9ucF4BXTFVCqOofWWtCcd40aVxV06F5SGS5sht+z10=; b=pVHLz8w90BvN0bKYmkzKoYCNvd0IN1EMtSC8gpJ9LZkeILpqAKwFGQQaBHFE7g1bVq xgfVMWwAHxZYNUYR0TIiZ5CphvVS2YcBNSHVAGchFrdKh1fR2sR57gJnf1j5PR6TzeLB xHl2IJtfJXa3OzIxBPdiK0Hhfwk1WPRKLqAv1D7idX/lldo5z4GK092gdCvUkfKn0/X1 QihMTRFTCHW0fmfzLnaZt2u6jU8K8HVXa4T9Ol744t9Of1UQXV4mOX8MTumsYqubMGYz ZV4eisICUgLD95WxUlOUH0iR8Prq1WXQSIKaknU55mAIaqOam7FG1WE0n5FnkgGsRlic tHUA== Received: by 10.66.73.226 with SMTP id o2mr8773308pav.83.1349310790984; Wed, 03 Oct 2012 17:33:10 -0700 (PDT) Received: from localhost (c-24-19-7-36.hsd1.wa.comcast.net. [24.19.7.36]) by mx.google.com with ESMTPS id it6sm3377991pbc.14.2012.10.03.17.33.09 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 03 Oct 2012 17:33:10 -0700 (PDT) From: Kevin Hilman To: Tony Lindgren Cc: jean.pihet@newoldbits.com, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Anton Vorontsov , J Keerthy , Jean Pihet Subject: Re: [PATCH 1/2] ARM: OMAP: hwmod: align the SmartReflex fck names Organization: Deep Root Systems, LLC References: <1349279277-7634-1-git-send-email-j-pihet@ti.com> <1349279277-7634-2-git-send-email-j-pihet@ti.com> <20121003170059.GD4840@atomide.com> Date: Wed, 03 Oct 2012 17:33:12 -0700 In-Reply-To: <20121003170059.GD4840@atomide.com> (Tony Lindgren's message of "Wed, 3 Oct 2012 10:00:59 -0700") Message-ID: <87ehlfvzxz.fsf@deeprootsystems.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) MIME-Version: 1.0 X-Gm-Message-State: ALoCoQlrVhMs6IjCFZ9+XHE6J24VpUYh0qDvbGkWta2mfSmqKGT07/Fz0QXQRuZVFXNLuUMHq7i6 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org Tony Lindgren writes: > * jean.pihet@newoldbits.com [121003 08:48]: >> @@ -1036,8 +1036,8 @@ static struct omap_clk am33xx_clks[] = { >> CLK("davinci-mcasp.1", NULL, &mcasp1_fck, CK_AM33XX), >> CLK("NULL", "mmc2_fck", &mmc2_fck, CK_AM33XX), >> CLK(NULL, "mmu_fck", &mmu_fck, CK_AM33XX), >> - CLK(NULL, "smartreflex0_fck", &smartreflex0_fck, CK_AM33XX), >> - CLK(NULL, "smartreflex1_fck", &smartreflex1_fck, CK_AM33XX), >> + CLK(NULL, "smartreflex.0", &smartreflex_mpu_fck, CK_AM33XX), >> + CLK(NULL, "smartreflex.1", &smartreflex_core_fck, CK_AM33XX), >> CLK(NULL, "timer1_fck", &timer1_fck, CK_AM33XX), >> CLK(NULL, "timer2_fck", &timer2_fck, CK_AM33XX), >> CLK(NULL, "timer3_fck", &timer3_fck, CK_AM33XX), > > I think this should be something like this instead: > > CLK("smartreflex.0", "fck", &smartreflex_mpu_fck, CK_AM33XX), > CLK("smartreflex.1", "fck", &smartreflex_core_fck, CK_AM33XX), > > Where the first one is the dev name, the second one is the > alias you want to use in the client driver? Actually, the omap_device creation will create this kind of alias for you, with the device name populated etc, so adding device names here isn't necessary. For omap_devices where drivers are always using clk_get(dev, ...), the name in the initial clkdev table here really doesn't matter. However, for core code that needs to do a clk_get(NULL, "name"), then this name matters. In chatting with Paul offline, he mentioned part of the CCF conversion will be using clk_get(NULL, ...) on the main_clk listed in each hwmod. For that reason, it's important that this string match the name in the hwmod. I belive the patch below should make this compatible with any future use. Jean, can you fold this into $SUBJECT patch? Thanks, Kevin --- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/arch/arm/mach-omap2/clock33xx_data.c b/arch/arm/mach-omap2/clock33xx_data.c index 6de3dc7..8a16504 100644 --- a/arch/arm/mach-omap2/clock33xx_data.c +++ b/arch/arm/mach-omap2/clock33xx_data.c @@ -1034,8 +1034,8 @@ static struct omap_clk am33xx_clks[] = { CLK("davinci-mcasp.1", NULL, &mcasp1_fck, CK_AM33XX), CLK("NULL", "mmc2_fck", &mmc2_fck, CK_AM33XX), CLK(NULL, "mmu_fck", &mmu_fck, CK_AM33XX), - CLK(NULL, "smartreflex.0", &smartreflex_mpu_fck, CK_AM33XX), - CLK(NULL, "smartreflex.1", &smartreflex_core_fck, CK_AM33XX), + CLK(NULL, "smartreflex_mpu_fck", &smartreflex_mpu_fck, CK_AM33XX), + CLK(NULL, "smartreflex_core_fck", &smartreflex_core_fck, CK_AM33XX), CLK(NULL, "timer1_fck", &timer1_fck, CK_AM33XX), CLK(NULL, "timer2_fck", &timer2_fck, CK_AM33XX), CLK(NULL, "timer3_fck", &timer3_fck, CK_AM33XX), diff --git a/arch/arm/mach-omap2/clock3xxx_data.c b/arch/arm/mach-omap2/clock3xxx_data.c index a197cf2..191d261 100644 --- a/arch/arm/mach-omap2/clock3xxx_data.c +++ b/arch/arm/mach-omap2/clock3xxx_data.c @@ -3447,8 +3447,8 @@ static struct omap_clk omap3xxx_clks[] = { CLK(NULL, "atclk_fck", &atclk_fck, CK_3XXX), CLK(NULL, "traceclk_src_fck", &traceclk_src_fck, CK_3XXX), CLK(NULL, "traceclk_fck", &traceclk_fck, CK_3XXX), - CLK(NULL, "smartreflex.0", &smartreflex_mpu_iva_fck, CK_34XX | CK_36XX), - CLK(NULL, "smartreflex.1", &smartreflex_core_fck, CK_34XX | CK_36XX), + CLK(NULL, "smartreflex_mpu_iva_fck", &smartreflex_mpu_iva_fck, CK_34XX | CK_36XX), + CLK(NULL, "smartreflex_core_fck", &smartreflex_core_fck, CK_34XX | CK_36XX), CLK(NULL, "sr_l4_ick", &sr_l4_ick, CK_34XX | CK_36XX), CLK(NULL, "secure_32k_fck", &secure_32k_fck, CK_3XXX), CLK(NULL, "gpt12_fck", &gpt12_fck, CK_3XXX), diff --git a/arch/arm/mach-omap2/clock44xx_data.c b/arch/arm/mach-omap2/clock44xx_data.c index 9cc1112..19e0c1e 100644 --- a/arch/arm/mach-omap2/clock44xx_data.c +++ b/arch/arm/mach-omap2/clock44xx_data.c @@ -3224,8 +3224,8 @@ static struct omap_clk omap44xx_clks[] = { CLK(NULL, "slimbus2_fclk_0", &slimbus2_fclk_0, CK_443X), CLK(NULL, "slimbus2_slimbus_clk", &slimbus2_slimbus_clk, CK_443X), CLK(NULL, "slimbus2_fck", &slimbus2_fck, CK_443X), - CLK(NULL, "smartreflex.0", &smartreflex_core_fck, CK_443X), - CLK(NULL, "smartreflex.1", &smartreflex_iva_fck, CK_443X), + CLK(NULL, "smartreflex_core_fck", &smartreflex_core_fck, CK_443X), + CLK(NULL, "smartreflex_mpu_fck", &smartreflex_iva_fck, CK_443X), CLK(NULL, "smartreflex.2", &smartreflex_mpu_fck, CK_443X), CLK(NULL, "timer1_fck", &timer1_fck, CK_443X), CLK(NULL, "timer10_fck", &timer10_fck, CK_443X),