Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934753AbcCOMQC (ORCPT ); Tue, 15 Mar 2016 08:16:02 -0400 Received: from mail-io0-f195.google.com ([209.85.223.195]:36423 "EHLO mail-io0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932688AbcCOMPu (ORCPT ); Tue, 15 Mar 2016 08:15:50 -0400 MIME-Version: 1.0 In-Reply-To: <1458041620-27066-1-git-send-email-jonathanh@nvidia.com> References: <1458041620-27066-1-git-send-email-jonathanh@nvidia.com> Date: Tue, 15 Mar 2016 13:15:16 +0100 X-Google-Sender-Auth: ZGXdq5CXraZjC_4MPS0yYmqHm50 Message-ID: Subject: Re: [PATCH V4] PM / clk: Add support for obtaining clocks from device-tree From: Geert Uytterhoeven To: Jon Hunter Cc: "Rafael J. Wysocki" , Linux PM list , "linux-kernel@vger.kernel.org" , linux-tegra@vger.kernel.org, "devicetree@vger.kernel.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1203 Lines: 28 On Tue, Mar 15, 2016 at 12:33 PM, Jon Hunter wrote: > The PM clocks framework requires clients to pass either a con-id or a > valid clk pointer in order to add a clock to a device. Add a new > function of_pm_clk_add_clks() to allows device clocks to be retrieved > from device-tree and populated for a given device. Note that it is > not necessary to make the compilation of this new function dependent > upon CONFIG_OF because there are stubs functions for the device-tree > APIs used. > > In order to handle errors encountered when adding clocks from > device-tree, add a function pm_clk_remove_clk() to remove any clocks > (using a pointer to the clk structure) that have been added > successfully before the error occurred. > > Signed-off-by: Jon Hunter Acked-by: Geert Uytterhoeven Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds