From patchwork Sun Aug 13 14:21:11 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shawn Guo X-Patchwork-Id: 109953 Delivered-To: patch@linaro.org Received: by 10.140.95.78 with SMTP id h72csp3255794qge; Sun, 13 Aug 2017 07:22:47 -0700 (PDT) X-Received: by 10.98.196.25 with SMTP id y25mr20445506pff.88.1502634167057; Sun, 13 Aug 2017 07:22:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1502634167; cv=none; d=google.com; s=arc-20160816; b=GX7YOS8Oa0mBueSeIoS0JF8dbakUIf3LL6fp5F+9KTQD8RBLCaRsj7Xfowc2glV11B AZotwKjBroq+Xu74eGCGl9ozMT7OY0+BJHh0R3D2SzCdJuTfQSG8k1/sc/qcnwapN0LL klT9WAltk52wUl3t7dqXs1rw6Mgi+/5ZW9pFtuNQodPdqYiZ5SvZE0z3oywMZqapEpmc FjEevqVMvmR6c1JhTZDRr2fl+hwsTB2Y+kI1q7pCfL4MxLrOlmevFRsUxPER6qzOJlM+ xDyL/UyQVdfxCRt8GHO0bpK6ocbasavBICco/yOpSmuiR/a871h2TuUl7Ca9pwdRr2we eOXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dmarc-filter:arc-authentication-results; bh=yqn0LxRFSoW9IRpU04WpUjnEjvOsldWJ//+2w/Wc8zI=; b=lZzcs3KPalDZ83snoj0+F8a4k7NSw+wgOzgXWSyJTufRwO1naOrcIpmvMKMCxpogU5 ks5M0tqVOlPJL6Kfeo9pin0Nn0KfTASuI5x5FTeT6OT1/h6xUIi6I9RgQ9NDiP4DVNJP k/UdJeDmWr/lLEpyAzqMLuY8j2GEn+ETvFfNRtx5PU7MOJc1LtpOGS3QrTEA4aJcfEKj lxvICMrS/1OGp0jN4eKxUbhYFPN8rvqhunBMyaujr7Xi6wZPWJ/iXirDzZ6uQOKlQVKc MSvHlPkGEa2m62qYj8BO4tSZRQmQ37We60RgjBHbw9cJyx3l+LhAA2HRKkgHGVuMfVWu tPxw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-usb-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-usb-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m129si2923356pgm.686.2017.08.13.07.22.45; Sun, 13 Aug 2017 07:22:47 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-usb-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-usb-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-usb-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752111AbdHMOWo (ORCPT + 4 others); Sun, 13 Aug 2017 10:22:44 -0400 Received: from mail.kernel.org ([198.145.29.99]:36254 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752095AbdHMOWn (ORCPT ); Sun, 13 Aug 2017 10:22:43 -0400 Received: from localhost.localdomain (li411-102.members.linode.com [106.187.91.102]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id EEECE239A6; Sun, 13 Aug 2017 14:22:40 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EEECE239A6 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=shawnguo@kernel.org From: Shawn Guo To: Felipe Balbi Cc: Stephen Boyd , linux-arm-kernel@lists.infradead.org, linux-usb@vger.kernel.org, linux-clk@vger.kernel.org, Shawn Guo Subject: [PATCH] usb: dwc3: of-simple: remove include of clk-provider.h Date: Sun, 13 Aug 2017 22:21:11 +0800 Message-Id: <1502634071-2266-1-git-send-email-shawnguo@kernel.org> X-Mailer: git-send-email 1.9.1 Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org From: Shawn Guo The header clk-provider.h is there for clock drivers (providers) to include, not client drivers (consumers). That said, of_clk_get_parent_count() is a helper function for clock providers, not a clk API for consumers. Let's replace of_clk_get_parent_count() with of_count_phandle_with_args() call, so that we can remove the include of clk-provider.h. Signed-off-by: Shawn Guo --- drivers/usb/dwc3/dwc3-of-simple.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Acked-by: Stephen Boyd diff --git a/drivers/usb/dwc3/dwc3-of-simple.c b/drivers/usb/dwc3/dwc3-of-simple.c index fe414e7a9c78..4cef7d4f9cd0 100644 --- a/drivers/usb/dwc3/dwc3-of-simple.c +++ b/drivers/usb/dwc3/dwc3-of-simple.c @@ -25,7 +25,6 @@ #include #include #include -#include #include #include #include @@ -96,7 +95,8 @@ static int dwc3_of_simple_probe(struct platform_device *pdev) platform_set_drvdata(pdev, simple); simple->dev = dev; - ret = dwc3_of_simple_clk_init(simple, of_clk_get_parent_count(np)); + ret = dwc3_of_simple_clk_init(simple, of_count_phandle_with_args(np, + "clocks", "#clock-cells")); if (ret) return ret;