From patchwork Fri Jan 13 15:07:47 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 9515821 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4E9FE601DA for ; Fri, 13 Jan 2017 15:08:03 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3FD0A28573 for ; Fri, 13 Jan 2017 15:08:03 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 301F228699; Fri, 13 Jan 2017 15:08:03 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A4C9928573 for ; Fri, 13 Jan 2017 15:08:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751967AbdAMPIB (ORCPT ); Fri, 13 Jan 2017 10:08:01 -0500 Received: from mail-lf0-f50.google.com ([209.85.215.50]:34580 "EHLO mail-lf0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751678AbdAMPH7 (ORCPT ); Fri, 13 Jan 2017 10:07:59 -0500 Received: by mail-lf0-f50.google.com with SMTP id v186so39811106lfa.1 for ; Fri, 13 Jan 2017 07:07:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=KIT5Eybk4QBEVFlPBgy/Qt5cuij2J0MBk6C20LIpgW8=; b=LSWB5ey9OCJIU9FlxhOCCm/KLr/CvahAO4Vpl0hOUwhnTmzT78qVfhMxj/ttTjHAes jQS85y3W/w90c8UfwoSt/Ev/rxXHIabEcsWzmjIaGmBFF7vdTcCn+8UYa9Ynmhwzl8KG Wsu7ZyJEZeJmQG2nDiHpaKoXA+spjYR4vkziY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=KIT5Eybk4QBEVFlPBgy/Qt5cuij2J0MBk6C20LIpgW8=; b=NcoCvKyDH9/8inLK9yMOXcDNKxtsnmZeSbOwb26xMy9DoGfMSrpmAtvVYyv3gJ0R3w Zlo7Q1lngURsi/u49UGTgDRMlDPqLsIcy03t9htkQAye4mcsuDOmd9EJRbrOVWgSm9cw Seh6xZLR7rx3c+Oy54qrk/Rq018FDbLME1ccv1CktQh859WXtTVvCeLNQLl4bw8qT/fE V/lyPNOjUIgE0j409zJxiJ+BALnvM1AlGccVTZXb79K2gS4gBDKrCDhBkOXEIe64hgWP dy3R4uXU/tXxijtgL7Q3cw9WmD71w+xmZWDX7h45Z1XPwqzZo7etpknnlEHIn0hu7tzw ldsw== X-Gm-Message-State: AIkVDXLxOcT9VvqzayooFjgYIk2s2YusHA5sr2RahqHQxvAJA5bSNm2OWjKQVxq/fd3122BU X-Received: by 10.25.23.24 with SMTP id n24mr6257778lfi.127.1484320078149; Fri, 13 Jan 2017 07:07:58 -0800 (PST) Received: from gnarp.ideon.se ([85.235.10.227]) by smtp.gmail.com with ESMTPSA id x75sm3976405lfi.16.2017.01.13.07.07.57 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Jan 2017 07:07:57 -0800 (PST) From: Linus Walleij To: Michael Turquette , Stephen Boyd Cc: linux-clk@vger.kernel.org, Linus Walleij , Ulf Hansson Subject: [PATCH 1/3] clk: ux500: move AB8500 sysclk over to PRCMU clk driver Date: Fri, 13 Jan 2017 16:07:47 +0100 Message-Id: <20170113150747.30105-1-linus.walleij@linaro.org> X-Mailer: git-send-email 2.9.3 Sender: linux-clk-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-clk@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The AB8500 sysclk is just another PRCMU-controlled clock, there is no reason why it should be in the ABx500-controlled part of the clock implementation. Doing this and the corresponding device tree changes makes USB work on the Ux500 again. Cc: Ulf Hansson Signed-off-by: Linus Walleij Acked-by: Ulf Hansson --- drivers/clk/ux500/abx500-clk.c | 8 -------- drivers/clk/ux500/u8500_of_clk.c | 3 +++ 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/drivers/clk/ux500/abx500-clk.c b/drivers/clk/ux500/abx500-clk.c index a07c31e6f26d..0467fcae3b0e 100644 --- a/drivers/clk/ux500/abx500-clk.c +++ b/drivers/clk/ux500/abx500-clk.c @@ -15,7 +15,6 @@ #include #include #include -#include #include "clk.h" /* Clock definitions for ab8500 */ @@ -39,13 +38,6 @@ static int ab8500_reg_clks(struct device *dev) if (ret) return ret; - /* ab8500_sysclk */ - clk = clk_reg_prcmu_gate("ab8500_sysclk", NULL, PRCMU_SYSCLK, 0); - clk_register_clkdev(clk, "sysclk", "ab8500-usb.0"); - clk_register_clkdev(clk, "sysclk", "ab-iddet.0"); - clk_register_clkdev(clk, "sysclk", "snd-soc-mop500.0"); - clk_register_clkdev(clk, "sysclk", "shrm_bus"); - /* ab8500_sysclk2 */ clk = clk_reg_sysctrl_gate(dev , "ab8500_sysclk2", "ab8500_sysclk", AB8500_SYSULPCLKCTRL1, AB8500_SYSULPCLKCTRL1_SYSCLKBUF2REQ, diff --git a/drivers/clk/ux500/u8500_of_clk.c b/drivers/clk/ux500/u8500_of_clk.c index e960d686d9db..d5888591e1a9 100644 --- a/drivers/clk/ux500/u8500_of_clk.c +++ b/drivers/clk/ux500/u8500_of_clk.c @@ -206,6 +206,9 @@ static void u8500_clk_init(struct device_node *np) clk = clk_reg_prcmu_gate("timclk", NULL, PRCMU_TIMCLK, 0); prcmu_clk[PRCMU_TIMCLK] = clk; + clk = clk_reg_prcmu_gate("ab8500_sysclk", NULL, PRCMU_SYSCLK, 0); + prcmu_clk[PRCMU_SYSCLK] = clk; + clk = clk_reg_prcmu_opp_volt_scalable("sdmmcclk", NULL, PRCMU_SDMMCCLK, 100000000, CLK_SET_RATE_GATE); prcmu_clk[PRCMU_SDMMCCLK] = clk;