From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 34E33C04AB3 for ; Mon, 27 May 2019 12:00:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 07A052146F for ; Mon, 27 May 2019 12:00:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726071AbfE0MAX (ORCPT ); Mon, 27 May 2019 08:00:23 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:39050 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726063AbfE0MAX (ORCPT ); Mon, 27 May 2019 08:00:23 -0400 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 36F511BECEA50A9CBE6B; Mon, 27 May 2019 20:00:18 +0800 (CST) Received: from [127.0.0.1] (10.177.19.180) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.439.0; Mon, 27 May 2019 20:00:13 +0800 Subject: Re: [PATCH] drivers: base: power: Use of_clk_get_parent_count() To: Geert Uytterhoeven CC: "Rafael J. Wysocki" , Len Brown , Greg Kroah-Hartman , Linux PM list , Linux Kernel Mailing List References: <20190525120155.108948-1-wangkefeng.wang@huawei.com> From: Kefeng Wang Message-ID: Date: Mon, 27 May 2019 19:57:44 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.3.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Language: en-US X-Originating-IP: [10.177.19.180] X-CFilter-Loop: Reflected Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org On 2019/5/27 19:08, Geert Uytterhoeven wrote: > Hi Kefeng, > > On Sat, May 25, 2019 at 1:54 PM Kefeng Wang wrote: >> Use of_clk_get_parent_count() instead of open coding. >> >> Signed-off-by: Kefeng Wang > Thanks for your patch! > >> --- a/drivers/base/power/clock_ops.c >> +++ b/drivers/base/power/clock_ops.c >> @@ -195,8 +195,7 @@ int of_pm_clk_add_clks(struct device *dev) >> if (!dev || !dev->of_node) >> return -EINVAL; >> >> - count = of_count_phandle_with_args(dev->of_node, "clocks", >> - "#clock-cells"); >> + count = of_clk_get_parent_count(dev->of_node); >> if (count <= 0) >> return -ENODEV; > > Given of_clk_get_parent_count() is provided by , I think > you should add an include for that. Thanks for your kind suggestion, v2 has been sent with the head and your reviewed-by. > > With the above fixed: > Reviewed-by: Geert Uytterhoeven > > Gr{oetje,eeting}s, > > Geert >