From patchwork Sat Feb 18 16:04:30 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kathiravan Thirumoorthy X-Patchwork-Id: 58947 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp437677wrn; Sat, 18 Feb 2023 08:08:26 -0800 (PST) X-Google-Smtp-Source: AK7set8mE/P6gzD6VawcoiaYsiFnwZavmRjENDZ+g4GuyGnXVw2opLWs2DvcWFtYu+dHBxh+AMz+ X-Received: by 2002:a17:902:f9d0:b0:198:f027:5925 with SMTP id kz16-20020a170902f9d000b00198f0275925mr2365969plb.64.1676736506523; Sat, 18 Feb 2023 08:08:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676736506; cv=none; d=google.com; s=arc-20160816; b=PUon/nWwMCne4dP9k0JUhRiN+kEOp++/bqppzunmFkmvREjCG27ygC3LI1b9JfA+Qs zyNuIKh3HjvnbacLxPk7bDsHx4K4/WlBcBTFBuGdJar78qLGZGAvEf5yBre91LLoCkYI tLSSgQdYSmtFgh24rKZDekbyg0vy5dmvbc+CC091Oa4XIjkAJdclORPCkJ+HlZPj0hXC TMvAn0OSD5nQuLNg4g5cavNXfZgSFFief4B6a/ZOM7JXsDnhlGFJ1x/hAias7lASGQuw /lp/E/7kgx2YJro1fB15iZ26DdGm1x/ie4yhbt40tp0M//RaJuu7qEQXk3ZUlhXEqg7p NA9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from :dkim-signature; bh=Y0rTtoTMn6ZnNqDbDaUytNOP79PGCne+oIxzZUiwE68=; b=CDNuQbfdW69OyG6xlGstHgiF9IR/xwXO945M/a6UMYUfdHmg0GRf5t7CwmEGSTN7lf SNvCgYAadJNtmAcPCaJE/9s+FWLRlzGmj7wUCwd+g+d6HkoydjD1ItliapMNMiabE/vb Un2ed5dC3D6vM2hBf5xK9Y/tzZRTz8vwJJ61/7LQ8vD8jZZbAh7izsL8mXQtuDuxiMIq qMbyEu7ZaGFfmgMIHjRklDdl2+FS1j7ZU8wUNNwwHtHl/83koMx8s6O7eeMtPNgktyHt 651kudJF1JFCirrg3go0FZE22+UiTc+qZWZtK41EU7Vs5lRFGyp52LnkDP0DYTU9GbIJ FgBQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=mFyjGfKI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e15-20020a17090301cf00b001992144f3aasi4083038plh.581.2023.02.18.08.08.13; Sat, 18 Feb 2023 08:08:26 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=mFyjGfKI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229681AbjBRQEz (ORCPT + 99 others); Sat, 18 Feb 2023 11:04:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43740 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229441AbjBRQEy (ORCPT ); Sat, 18 Feb 2023 11:04:54 -0500 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C820B12BF9; Sat, 18 Feb 2023 08:04:52 -0800 (PST) Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 31IFivqp007898; Sat, 18 Feb 2023 16:04:49 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=qcppdkim1; bh=Y0rTtoTMn6ZnNqDbDaUytNOP79PGCne+oIxzZUiwE68=; b=mFyjGfKI3LoVBLOM7b7gVT8irZy5ip5v4Lkb3Kl3GnNLIslmTi3X2erwXAC1OxfPbeCQ BjDQkbhS/PmXcHIMqyDVkq1RjloaIkcawj4s7xaqTbia1MgKBY3vFlW088Y2ocVSB4lg OdeF/RvsKIS2lON0tLrtmlukD/EdrQ9tJNi4+h3g4sOr8wiocsUmPfo1T+BB8E0cuqSe eUFQVurbz4bdSK4zi7uVzGZt+9lgakp9D4+tdeczLsLsTI2+KdmFdJgC2YRP0/apF7FH SRaL7pSUz8ZZAl/21oxpUy5sQ1I7E5c4FqY20AHdGjKoz9y+h1YG/TiMy6olp+TNFI2d Rw== Received: from nalasppmta03.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3ntp9893mh-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 18 Feb 2023 16:04:48 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA03.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 31IG4lgN023058 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sat, 18 Feb 2023 16:04:47 GMT Received: from kathirav-linux.qualcomm.com (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.41; Sat, 18 Feb 2023 08:04:43 -0800 From: Kathiravan T To: , , , , , , , CC: , , Kathiravan T Subject: [PATCH V5] clk: qcom: ipq5332: mark GPLL4 as ignore unused temporarily Date: Sat, 18 Feb 2023 21:34:30 +0530 Message-ID: <20230218160430.22055-1-quic_kathirav@quicinc.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: JEfbt7SgZ2_Sw-BcKcjzQrKkNhaEZ3lA X-Proofpoint-ORIG-GUID: JEfbt7SgZ2_Sw-BcKcjzQrKkNhaEZ3lA X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.930,Hydra:6.0.562,FMLib:17.11.170.22 definitions=2023-02-18_11,2023-02-17_01,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=824 mlxscore=0 adultscore=0 priorityscore=1501 malwarescore=0 suspectscore=0 lowpriorityscore=0 bulkscore=0 clxscore=1015 impostorscore=0 spamscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2302180145 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1758185658951429581?= X-GMAIL-MSGID: =?utf-8?q?1758185658951429581?= Clock framework disables the GPLL4 source since there are no active users for this source currently. Some of the clocks initialized by the bootloaders uses the GPLL4 as the source. Due to this, when the GPLL4 is disabled by the clock framework, system is going for the reboot. To avoid this, mark the GPLL4 as ignore unused so that clock framework doesn't disable it. Once the users of this source is enabled, we can get rid of this flag. Signed-off-by: Kathiravan T --- Changes in V5: - Update the commit title to reflect CLK_IGNORE_UNUSED is used - This patch depends on the IPQ5332 baseport patches https://lore.kernel.org/linux-arm-msm/20230217075835.460-1-quic_kathirav@quicinc.com/ Changes in V4: - Updated the commit message and comment in driver that CLK_IGNORE_UNUSED is used - This patch depends on the IPQ5332 baseport patches https://lore.kernel.org/linux-arm-msm/20230217075835.460-1-quic_kathirav@quicinc.com/ Changes in V3: - Fixed the typo in the comment - Used CLK_IGNORE_UNUSED instead of CLK_IS_CRITICAL Changes in V2: - Added a comment in driver explaining the need of the flag drivers/clk/qcom/gcc-ipq5332.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/clk/qcom/gcc-ipq5332.c b/drivers/clk/qcom/gcc-ipq5332.c index 9e4baea33937..bdb4a0a11d07 100644 --- a/drivers/clk/qcom/gcc-ipq5332.c +++ b/drivers/clk/qcom/gcc-ipq5332.c @@ -128,6 +128,17 @@ static struct clk_alpha_pll gpll4_main = { .parent_data = &gcc_parent_data_xo, .num_parents = 1, .ops = &clk_alpha_pll_stromer_ops, + /* + * There are no consumers for this GPLL in kernel yet, + * (will be added soon), so the clock framework + * disables this source. But some of the clocks + * initialized by boot loaders uses this source. So we + * need to keep this clock ON. Add the + * CLK_IGNORE_UNUSED flag so the clock will not be + * disabled. Once the consumer in kernel is added, we + * can get rid of this flag. + */ + .flags = CLK_IGNORE_UNUSED, }, }, };