Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp17894071ybl; Thu, 2 Jan 2020 14:15:25 -0800 (PST) X-Google-Smtp-Source: APXvYqx+lCu6flvu1WR9lDAsvb8vwKmnxG1bobbefuU1AtQ9gE8VzX2zTbdRNtpYSwD7ofkDXmMG X-Received: by 2002:a9d:32f:: with SMTP id 44mr45604793otv.234.1578003325498; Thu, 02 Jan 2020 14:15:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578003325; cv=none; d=google.com; s=arc-20160816; b=f6IBrdLnZMfJTHZQ2ZRFzaBcNvAiI0F4fhVgyWWOAytqsp8CsakpYiaQROPD5dmxWY zMmoNCbN2Ryx3oELQW2tEpI3opfo/1L0M9345mJc3CIdYhbdxlnRy0sQOP9HAvSeVYJg IN/MPUsdbiLGMn4NAjScF6UTBrtkQsoedADxSuT/YMjRkVgS6agmsUjDzcInG8HWZwCc 44wPR1UKbzepdaMXXVgy+GFDjemJuYy1Y8vyZ7VLYlIfyaiUvR9lhit5cox5X5y9+KaH rxFQzvyDszYijyq7rGjv4Ibt2i4NvUSjK2IhtFenB3qrGtKD1iKr00YOe9p13tlb3bLS jo3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=jjKQ52ehVvM066nai6etsSI5bmrSjzjceI0U5hp0x6M=; b=JnE0tmae3wqQA+tZpMdu7otCJFYAAIch860Xl5Zgnk+NMzbm9f/MaezpPkZTvgL9VL RldYSnwcQ/VpjhZaOpYPCisdyHSlfAft7gYiTRZV8rHoSTnIwKJfWhF4AKytL/QpTh/t uIjxbpRqi7iqa9G/BM7t70PxP1hooT2lNd0rF+IB6nhTxb8mF8rHqhnPvQjdhO6FVGes sVfXS32afihi8civntNVvLRZihuKUkZz2YHhgNjct1Mrpp+iaTNc5BiheYB3nEWJ5gzl pueGGTE3NSFnqlQMwNUJOaaVsSqzNeP7Wdr6hqhansJ8JdkUxClSb7+tkvTHKYTaU/PI SKyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=dIN3yvgn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-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 u191si23648774oia.86.2020.01.02.14.15.13; Thu, 02 Jan 2020 14:15:25 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=dIN3yvgn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727581AbgABWM4 (ORCPT + 99 others); Thu, 2 Jan 2020 17:12:56 -0500 Received: from mail.kernel.org ([198.145.29.99]:52314 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727569AbgABWMx (ORCPT ); Thu, 2 Jan 2020 17:12:53 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2F5F221D7D; Thu, 2 Jan 2020 22:12:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1578003172; bh=To3ybeRrIJZsIK2I51g9pmOYOKb3+uskSjOVbVV6dzU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=dIN3yvgnqXhRmLVLSOHojjMlVdHI5yRb3WijGN7SyEakp3NYTgW1HGmv4fNebU99g KsfRG4BLnhbLffCYitrZcUglydMdskB7dOdxWGF4BJFJhE7fBEb5eIAtbTnqaL/Sm9 IFxvJsSCesJwq79DDBGPoVN4hN7PxpCgcm8/ch4A= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jeffrey Hugo , Stephen Boyd , Sasha Levin Subject: [PATCH 5.4 049/191] clk: qcom: smd: Add missing pnoc clock Date: Thu, 2 Jan 2020 23:05:31 +0100 Message-Id: <20200102215835.167420054@linuxfoundation.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200102215829.911231638@linuxfoundation.org> References: <20200102215829.911231638@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jeffrey Hugo [ Upstream commit ba1d366de261981c0dd04fac44d2ce3a5eba2eaa ] When MSM8998 support was added, and analysis was done to determine what clocks would be consumed. That analysis had a flaw, which caused the pnoc to be skipped. The pnoc clock needs to be on to access the uart for the console. The clock is on from boot, but has no consumer votes in the RPM. When we attempt to boot the modem, it causes the RPM to turn off pnoc, which kills our access to the console and causes CPU hangs. We need pnoc to be defined, so that clk_smd_rpm_handoff() will put in an implicit vote for linux and prevent issues when booting modem. Hopefully pnoc can be consumed by the interconnect framework in future so that Linux can rely on explicit votes. Fixes: 6131dc81211c ("clk: qcom: smd: Add support for MSM8998 rpm clocks") Signed-off-by: Jeffrey Hugo Link: https://lkml.kernel.org/r/20191107190615.5656-1-jeffrey.l.hugo@gmail.com Signed-off-by: Stephen Boyd Signed-off-by: Sasha Levin --- drivers/clk/qcom/clk-smd-rpm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/clk/qcom/clk-smd-rpm.c b/drivers/clk/qcom/clk-smd-rpm.c index fef5e8157061..930fa4a4c52a 100644 --- a/drivers/clk/qcom/clk-smd-rpm.c +++ b/drivers/clk/qcom/clk-smd-rpm.c @@ -648,6 +648,7 @@ static const struct rpm_smd_clk_desc rpm_clk_qcs404 = { }; /* msm8998 */ +DEFINE_CLK_SMD_RPM(msm8998, pcnoc_clk, pcnoc_a_clk, QCOM_SMD_RPM_BUS_CLK, 0); DEFINE_CLK_SMD_RPM(msm8998, snoc_clk, snoc_a_clk, QCOM_SMD_RPM_BUS_CLK, 1); DEFINE_CLK_SMD_RPM(msm8998, cnoc_clk, cnoc_a_clk, QCOM_SMD_RPM_BUS_CLK, 2); DEFINE_CLK_SMD_RPM(msm8998, ce1_clk, ce1_a_clk, QCOM_SMD_RPM_CE_CLK, 0); @@ -670,6 +671,8 @@ DEFINE_CLK_SMD_RPM_XO_BUFFER_PINCTRL(msm8998, rf_clk2_pin, rf_clk2_a_pin, 5); DEFINE_CLK_SMD_RPM_XO_BUFFER(msm8998, rf_clk3, rf_clk3_a, 6); DEFINE_CLK_SMD_RPM_XO_BUFFER_PINCTRL(msm8998, rf_clk3_pin, rf_clk3_a_pin, 6); static struct clk_smd_rpm *msm8998_clks[] = { + [RPM_SMD_PCNOC_CLK] = &msm8998_pcnoc_clk, + [RPM_SMD_PCNOC_A_CLK] = &msm8998_pcnoc_a_clk, [RPM_SMD_SNOC_CLK] = &msm8998_snoc_clk, [RPM_SMD_SNOC_A_CLK] = &msm8998_snoc_a_clk, [RPM_SMD_CNOC_CLK] = &msm8998_cnoc_clk, -- 2.20.1