Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756783AbcKXE56 (ORCPT ); Wed, 23 Nov 2016 23:57:58 -0500 Received: from relmlor2.renesas.com ([210.160.252.172]:42607 "EHLO relmlie1.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1756706AbcKXE5z (ORCPT ); Wed, 23 Nov 2016 23:57:55 -0500 X-IronPort-AV: E=Sophos;i="5.31,690,1473087600"; d="scan'";a="226836228" Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=kuninori.morimoto.gx@renesas.com; Message-ID: <87y409cw71.wl%kuninori.morimoto.gx@renesas.com> From: Kuninori Morimoto To: Stephen Boyd , Rob Herring , Linux-ALSA , Linux-DT , Michael Turquette , Russell King , Linux-Kernel , Mark Brown , , Linux-ARM Subject: Re: [alsa-devel] [PATCH v2] clkdev: add devm_of_clk_get() In-Reply-To: <87a8cpejn5.wl%kuninori.morimoto.gx@renesas.com> References: <87wpl2yyuw.wl%kuninori.morimoto.gx@renesas.com> <146785219147.73491.2827268663638530377@resonance> <87ziptixv7.wl%kuninori.morimoto.gx@renesas.com> <20160707122636.GP1041@n2100.armlinux.org.uk> <8760shgfzu.wl%kuninori.morimoto.gx@renesas.com> <146794140875.73491.7115209079607438738@resonance> <871t34hlin.wl%kuninori.morimoto.gx@renesas.com> <878twndi54.wl%kuninori.morimoto.gx@renesas.com> <8737isvwc6.wl%kuninori.morimoto.gx@renesas.com> <20161123191037.GE25626@codeaurora.org> <87a8cpejn5.wl%kuninori.morimoto.gx@renesas.com> User-Agent: Wanderlust/2.15.9 Emacs/24.3 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset="US-ASCII" Date: Thu, 24 Nov 2016 04:57:43 +0000 X-Originating-IP: [211.11.155.144] X-ClientProxiedBy: OS2PR01CA0098.jpnprd01.prod.outlook.com (10.174.152.144) To HK2PR0601MB1444.apcprd06.prod.outlook.com (10.165.182.150) X-MS-Office365-Filtering-Correlation-Id: c4b76c08-0e59-4c41-64e7-08d414266da0 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001);SRVR:HK2PR0601MB1444; X-Microsoft-Exchange-Diagnostics: 1;HK2PR0601MB1444;3:BXvr3kdC4Fbu/SvvKmi05lGKgz+CCKIRx/74M3NovDOptul3OIz76LOTrAuxVTj96p++sxW+2F8sw5rx8VZbv7Py7WyoFLtQyPkMmaHIzVq8ppt1DAPybDK2ll9Gyg3Bf0MaFxeB/ISJ2NJ7osu/bCr6BAmuw2Yx8c0Gs5VxKMBKhoVynq3pxkfF1BHFyw//Uj7c7Mxopr0kR29RVOeebX+rfeSOeyNDiHKGJmS78N0+LNZ2ySplGOkxvDYgW/sBgBLq53xeO0u1Q0SH4R85jg== X-Microsoft-Exchange-Diagnostics: 1;HK2PR0601MB1444;25:pO8QLlzgxuRlU5+VL/Ohcm0TqHJgZ06L5qLDsF1KzOammEx9qxiFO9jxHRieHmxLCcltqkePHbyd75wy2DZRr10yrpdNXrcYTe0zqgfoParhuydWwZh8U1lTsJvHhIbtC84I5iDTAD+aEapP90p+iWeMpLiHXXXq1WPCFu8P8Q11NZ5G5jU0dplgxvkYko0iyvu1ZUTRD++XzeZgn3OyenHd9C4Cl5bYaIOrR48BCj51AnQYgtZZ/kUphHsxlO7YF7Q6YNTQ7pNMrIhzTumYahqRpYMBvOy2hQ8v7EhUFSep2vPbVgThYLCmc3zDrgzrhQsSTbvfr06nQ09lN6rZwWRv9VFwzM5zJiRlNNQEBtBizTMmkZSENHt4HOaysSX09+NpL6Arx6nsGFU9S3oR4Us1ef5AalzNSG8tLxNQuwBdq0ZtZ4aYF5jGFDKZfT9k0n2SEc4SRgqESUJsIwo3X0nt4mRO1A3x/AgFcOPdfxvBjkfdBQEwOwuizxuxbcZdHQWuN6DNgmfSEuzuNUzGeIjTZ3x0iVuzPs25i6nzkQNKmAZSVHHg9bVA/7NY0cG8rtDltZUgJ5pwxt/Voq35dJIfJns5c9f9EQbdC4Pl6n+K0ywwjaCL0qrkvAEEnATh8n94ABAhlZUgnU8T3iIYqTqq3EZ3G8dHoLvaZmf30Ei7YG+VlifiQHFT6TdSDHj9F/ER8l8Zl6W7TEMICVT8Zr0+N+vNAHyxbP8vViXgLaDChk+vBW/bM5FZGfAymj78 X-Microsoft-Exchange-Diagnostics: 1;HK2PR0601MB1444;31:3NKkWXLH8kOj585B8GHC62evqOec/N3MYCiVvfbP6Zi/L9DWVA9G83gOnJkLAD00aB5hSQeuOghqL9Do45S86rRaAnY8Xm9Oogn063kE+UId21yunoWNuPl1aykpthTeojXuWFTA0+F05hHTB5e83Dho5hXtr2Q7KqNUJoto9gUUJbUecplEAHMDmeCkKSV0/TvpUhcCu1JdT9/nITc2nqneXFAiqXBHlpKrtl4sIF2kRS3hNInao37+YT0niC4+bywn+tGkUXPXNLvCqOb7fQ==;20:077tcSQhpHMKntCZKNR99VZjhixbNnfHkzLe+ytmAdtqHBtOlxlsH5d19nuBaPCUtLAxsc5dyAHLvd5seSAQICfETeUY9unEwJrFXSPD7/c+BEynyv8NFFSaSRSCPWijbRVmJJC57pIl6x2pESBLrrxOyakgMGnCbQTU+fspo5Ay4Doz7UsgJtt9GuhJtuTZKl5lnkbfupczi/fcWHoK/ygHHa+c0YnfaGISvJF5dH9tnOUv1GO1pSMZeCduhblmYViLMffjWPSuJWkvkpApmZWl+G/FbJNSTaiGX+SgJN0FUdPk2ikbx1HkBiF1nG5WHcUGnUYl2/66NF65Ksmd5ogF+f27/gf1Uv132PnpRsaNP7gsHR0nFNcJ1x/8trtxmMXSoC3A0T3ThbkbhKX2Mv/bulRYT2R26/fBhHAONXs7wZ1XPUKOrXTCJMOydeOegbzVuSXyCkGdj/9Bzjw6K//OhaYGqVyjGAA00WuGHQPJ1ZT2vpgkx6SYEDM092DR X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6045199)(6060326)(6040307)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046)(6055026)(6041248)(6061324)(6072148);SRVR:HK2PR0601MB1444;BCL:0;PCL:0;RULEID:;SRVR:HK2PR0601MB1444; X-Microsoft-Exchange-Diagnostics: 1;HK2PR0601MB1444;4:chWQnt6nEq7FJRFbOmxy4P81s6vLJiHuHrOKzPazUPkV0flUTbAv3Thp2u6BC6kQ3Igz3uoavQjYZPHYbsRhGSigdOiZG56vnI1QmxH5b/z6WykLyvkWCwRPhZrjqQqABTLDQ+R00S8QVfp2jUdO+8DFbFyXHwqRWd1NEh5dQoh5aUmNAVtGIZ+4RYoTiCoFJA6+iVNy+ZcHekATGMBKE+tk2K0O4mfQ0t9SCyLOBaf5jPCtx9m+RSvRrlFJd408Qa5q93AfSFayKlLR7WGixW0PEYlpYxgt2TyG3kSFW9eN+9ai347gTD4tZiR7CY1jsyJVgRnuYHjLMMFloE2xr62fnALs7tf/2s6hhkLZ3xh8gduhHsX2UjWIzyaYaVEioIVR+ocMdYSYvb3MRKeq/hNu/h+LmQ8MvvZBgob1JR0hSLdWTV6Mzl6aSMzmA0BMrEj+BrXVrpoGkoGtJ+0NhZEGAuLlkfcvxYdO+GyA3i+Jb8ZVeFQCT1+SGXkNaqlAtEQ5NAVbHOcbrGGwWNRC0A== X-Forefront-PRVS: 0136C1DDA4 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(4630300001)(6009001)(7916002)(199003)(189002)(53416004)(92566002)(77096005)(6116002)(83506001)(23726003)(3846002)(46406003)(2906002)(189998001)(36756003)(42186005)(4001350100001)(97736004)(107886002)(38730400001)(5001770100001)(229853002)(47776003)(68736007)(86362001)(7416002)(66066001)(105586002)(106356001)(69596002)(50466002)(33646002)(101416001)(305945005)(5660300001)(76176999)(50986999)(2950100002)(54356999)(81166006)(8676002)(81156014)(7846002)(7736002)(93886004)(921003)(21314002)(1121003)(16060500001);DIR:OUT;SFP:1102;SCL:1;SRVR:HK2PR0601MB1444;H:morimoto-PC.renesas.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;HK2PR0601MB1444;23:DZzWOU8eRlJ9jU5/jUQ08jy5yFKiR30DVFmJ00/?= =?us-ascii?Q?cJvHLiES9QoO9Xo9LBLrl59DSqRSgUTkiRkTrDt6aKg4ccZ4zQHLTULHww4T?= =?us-ascii?Q?vcSph6jMxV6I2fYIETaOcV7Rj4o4EU6y9+3H1mEBuOpXfDf01wmPwyhxcXsr?= =?us-ascii?Q?8rbnTzRANoBPTG8yZ/jAI3u97o0uoxnXn+6iCsiGrCVxBobP6a4l2QYdMZV5?= =?us-ascii?Q?UBOZE8mgUX1eFxYYy9GSuo+er6s/6nUWGHBPVOogBPCfMakR07ViteU2OJQ+?= =?us-ascii?Q?a+qklDF3ts1/1WMog2j71KLWDG6O0kh2c7R2dPzzsR7QeaFusP5l7QxUCC+i?= =?us-ascii?Q?RrD+XAYGs+7dG2Zsi1GiZcu33DJMvQXlAaVW76YgO2jA86h92rQI7tQfAaQX?= =?us-ascii?Q?LtrZBRCBi0ei0TVmbdzKwP11wXyqFFjVbmq/a1sAeXDxDSXgsnmiZ8wphgp1?= =?us-ascii?Q?9XRGuWaZWntcIvch/9xbwnPScrj9TAuziP0ANGfDYs+t52iddEYAxC7Z7r7f?= =?us-ascii?Q?kMTrxS/tk6Xs1uahBZL9gS2TZ5JRhlPtm1e6pXBgaQV3C3GvpFWbWse1DLtq?= =?us-ascii?Q?RjCsG1Rn7cSVx/xqBRH9COKUX3HdPElrXeeV8BiPGDFiYDL50dzPXwnSlCrM?= =?us-ascii?Q?kdnpzhCZ8ljS741jIQWvUlOH3Gkv9BwraYr4IWubGVVO+/xcuzjL5sObrA+g?= =?us-ascii?Q?JzvGSSCt/qfK2af70WMzp7qQkzXnpv1NM9sScojY4zY30PLIMcBxDplZLY8N?= =?us-ascii?Q?bPTC3FQHonvCm5nm5ds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N7Gv/LoGcxvMDSQdrpwKslnzPjfWk5cD/7CMfxGluK79+WdZZf;5:EQE9bzgCRmP5a8iBRR/vlbyCT5822hwbpb77cIcuRMYS9vr7946wjztfyDe3sm3vWxtbubOqChkEio3r+L00IVZXIPLe93pMtmbSEDjwmIB0niXuisUudAJ6ybEtd1wOes4DrKtk1ekA7PUO9r4lVA==;24:ReppjmEGj5U/qoG71G3IW+N/PQ3NPXx9sFB4IGQ3M43v95iZKcIsOHdBNIxPnOtrByPDtUsUO8AqvLQw+f5mEnN+Lei9RQqldrkUJM0QAII= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;HK2PR0601MB1444;7:rt6G5azGqVMBXKfYGFe+0swOYqt9OQKCgEQvN9WeyrDyyS+dQ1smUSIw2Seysg9nJWpGl6kRG5zWIPJPTE/F+QuwHuxH6Pwl9gT79qSI9da5c4nbDAvwIOSuTKmPygoSt16xO4JbWTpz+sUmOS0N4R9/FY0CIT/TrE8hVdyogieYOm4bnaSWMhDbeEwZJsfleBP17gIlLwOtY77kDfC7r5CruKBuF5WUAUzwL9Eza1dty8aCFut728vWp9qZxTcJ6FK2m2QYryLoVGy4XLqLZKyeMgC/XUXYIsNTe1PaqhJ9nuNNVVmvuYz7qBbUIGh2kc5wgAT33JsLmm3pQRdqt0elQx4nGwopPKwV4r/fxmJUH50cUi2Z7aSYTyvN4pCAeyucbEQ384fKd7Hvlits8ry07HfYqiGXmrdmArQYTPbcxBnvG9UgDFB7ef7UR+wxNtOiOxG7GnBgHHJeCMkqQA==;20:WuNYNeHLjbXq0x/6rnzsfNF/gCyR6JR6PBzQ/35sLwnE3JU+zDFQFvjmdUAWDnikBSTVjjZogKH1EjyHwMBwzH6HOMg3yIIb5k78lk9kdoVB2b9tS/sbM8c+TjkkR2kYemT/db2xp5oVF5ZS9aJyFZm+x5ATlA5z/wS61xAbvho= X-OriginatorOrg: renesas.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Nov 2016 04:57:43.7085 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: HK2PR0601MB1444 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1258 Lines: 41 Hi Stephen, again > > I've seen bindings that have the 'clocks' property at the top > > level and the appropriate 'clock-names' property to relate the > > clocks to a subnode. > > > > sound_soc { > > clocks = <&xxx>, <&xxx>; > > clock-names = "cpu", "codec"; > > ... > > cpu { > > ... > > }; > > codec { > > ... > > }; > > }; > > > > Then the subnodes call clk_get() with the top level device and > > the name of their node and things match up. I suppose this > > binding is finalized though, so we can't really do that? > > > > I see that the gpio framework has a similar design called > > devm_get_gpiod_from_child(), so how about we add a > > devm_get_clk_from_child() API? That would more closely match the > > intent here, which is to restrict the clk_get() operation to > > child nodes of the device passed as the first argument. > > > > struct clk *devm_get_clk_from_child(struct device *dev, > > const char *con_id, > > struct device_node *child); Thanks, but, my point is that Linux already have "of_clk_get()", but we don't have its devm_ version. The point is that of_clk_get() can get clock from "device_node". Why having devm_ version become so problem ? Best regards --- Kuninori Morimoto