From patchwork Tue Dec 5 06:10:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sibi Sankar X-Patchwork-Id: 173723 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp3238127vqy; Mon, 4 Dec 2023 22:11:17 -0800 (PST) X-Google-Smtp-Source: AGHT+IHKuzGmOK/49oxVj1APLPYRvdsZmeScuge2rB/m7/krweCjuBKXQOlRqMWGzq529J+pacGr X-Received: by 2002:a05:6358:7e08:b0:170:17eb:9c40 with SMTP id o8-20020a0563587e0800b0017017eb9c40mr5671474rwm.33.1701756677555; Mon, 04 Dec 2023 22:11:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701756677; cv=none; d=google.com; s=arc-20160816; b=fq7HEhEN56QWNqR1AT+E2tFFYore03g2aYQHsbWYZfYQtsei9yiypO1a8yuCxqNAaX QxPJMco8fzL6K0vxzWTuE5CIbBL7fr/qmsadUkA4RcCp3puQMhDbFRrR2b3MsxSTs3Sk mY1vF5lhyZtIP7TYtwU4QpYwyCN7H48J4Hb1JgXoGhFF8OMhTOno7bCo+27vMHy+iSQj oUhehUIfWtBfJjWJALkQhwwtH0bX71XuipLsFjAfr7x0Dlv1UryFcUjMCwPwis0KV2II m2AazpMsnlOFegLFmtIsiSTOVmh8rF9HI3a8uKknq783kHdUQvZ9fXYK1PmhKKNmvyZo +TlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=7CWx8C9XE0luytjPVkQBdfbRlLh+RJR/tazhl+w79/0=; fh=hBzWgvmtW0nuDyhGmbBgXuva5tN2LCNKOPJRQLDf5OI=; b=R5KvYnTIWH2TyewVL0xX2kPhFsj83DFXTcyrS/UtG8kd5hV4HHri7mjJtWC54dMO4W et+uzPXAv0Ah5+pqsdrmvC3ulg2uGlnYzUGlM0m27fqPZGNVBKMbTIvwcOgHxV3URB28 M1fA/Bya+wtZoMWoAnkCiCEnZqUOOMctglBYyO2RPLNC8zZLpwuSdRmIuq0rIm1Xuf7s MWajyULtndxQ+57VBVXFhIibtE2QT9OD7Qz68BwpJJaDjrt+kJLZDvifqunSG9dUUbvu YhTrwubSKolGwycuM7u78InNna5sDhHOI7Q2dLlpKR24BBP4RlK+ZYaL4v6n6FZxb9y8 efMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=Hsrl5JsC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 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 groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id bh10-20020a056a02020a00b005c2122e482csi9349407pgb.700.2023.12.04.22.11.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Dec 2023 22:11:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=Hsrl5JsC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 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 (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id EF60C80A2225; Mon, 4 Dec 2023 22:11:11 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344370AbjLEGK5 (ORCPT + 99 others); Tue, 5 Dec 2023 01:10:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47650 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344331AbjLEGKv (ORCPT ); Tue, 5 Dec 2023 01:10:51 -0500 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 22970C9; Mon, 4 Dec 2023 22:10:58 -0800 (PST) Received: from pps.filterd (m0279870.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3B55pjCK004087; Tue, 5 Dec 2023 06:10:53 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=qcppdkim1; bh=7CWx8C9XE0luytjPVkQBdfbRlLh+RJR/tazhl+w79/0=; b=Hsrl5JsCt+DwFVt7oUnzz4z1KVKcpzbJvTjDP330Z0Zi7RaQjCKcg+c9pS4QkVzKO6gm vP6J0LsQtRfLAhCaKaUE1TbDD9J6RiFjvXo1HrfC6KhIPRIJyO21aXvCxBLNmWT2dJVk lpOjj4krXe/C2FCAcc+Zz7KQdxt/scRy5lpYgDCxyZ3/jnDo+QhEc6AGJvp6AJ2uOhxv Jub9XcprMVTxAAPUJdRmWOWvQ1sfvL3TsGhUcH+jROcHp6Vg6NZ46nxRbxJVnMzpWljR 7QctLvNvH2I1eRlS6nTPboKuBhQjOYsLfPJUKL9Nk4UUWRSFRGqp98s71xmgpbkBNzfs 7Q== Received: from nalasppmta02.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3usghcsv15-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 05 Dec 2023 06:10:53 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 3B56AqhP028873 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 5 Dec 2023 06:10:52 GMT Received: from blr-ubuntu-253.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.1118.40; Mon, 4 Dec 2023 22:10:46 -0800 From: Sibi Sankar To: , , , , , CC: , , , , , , , , , , , Sibi Sankar Subject: [PATCH V3 4/4] clk: qcom: rpmh: Add support for X1E80100 rpmh clocks Date: Tue, 5 Dec 2023 11:40:02 +0530 Message-ID: <20231205061002.30759-5-quic_sibis@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20231205061002.30759-1-quic_sibis@quicinc.com> References: <20231205061002.30759-1-quic_sibis@quicinc.com> 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-ORIG-GUID: cN9Cp6DQdrkiT5QqSn9ls5tWgtNUtqKj X-Proofpoint-GUID: cN9Cp6DQdrkiT5QqSn9ls5tWgtNUtqKj X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.997,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-12-05_03,2023-12-04_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=999 phishscore=0 adultscore=0 bulkscore=0 spamscore=0 lowpriorityscore=0 suspectscore=0 clxscore=1015 mlxscore=0 malwarescore=0 impostorscore=0 priorityscore=1501 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311060000 definitions=main-2312050050 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Mon, 04 Dec 2023 22:11:12 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1784421209839962432 X-GMAIL-MSGID: 1784421209839962432 From: Rajendra Nayak Adds the RPMH clocks present in X1E80100 SoC Co-developed-by: Neil Armstrong Signed-off-by: Neil Armstrong Signed-off-by: Rajendra Nayak Co-developed-by: Sibi Sankar Signed-off-by: Sibi Sankar Reviewed-by: Bryan O'Donoghue Reviewed-by: Konrad Dybcio --- drivers/clk/qcom/clk-rpmh.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/drivers/clk/qcom/clk-rpmh.c b/drivers/clk/qcom/clk-rpmh.c index 5d853fd43294..ce6f4363d2f7 100644 --- a/drivers/clk/qcom/clk-rpmh.c +++ b/drivers/clk/qcom/clk-rpmh.c @@ -372,6 +372,9 @@ DEFINE_CLK_RPMH_VRM(clk3, _a1, "clka3", 1); DEFINE_CLK_RPMH_VRM(clk4, _a1, "clka4", 1); DEFINE_CLK_RPMH_VRM(clk5, _a1, "clka5", 1); +DEFINE_CLK_RPMH_VRM(clk3, _a2, "clka3", 2); +DEFINE_CLK_RPMH_VRM(clk4, _a2, "clka4", 2); +DEFINE_CLK_RPMH_VRM(clk5, _a2, "clka5", 2); DEFINE_CLK_RPMH_VRM(clk6, _a2, "clka6", 2); DEFINE_CLK_RPMH_VRM(clk7, _a2, "clka7", 2); DEFINE_CLK_RPMH_VRM(clk8, _a2, "clka8", 2); @@ -737,6 +740,28 @@ static const struct clk_rpmh_desc clk_rpmh_sm4450 = { .num_clks = ARRAY_SIZE(sm4450_rpmh_clocks), }; +static struct clk_hw *x1e80100_rpmh_clocks[] = { + [RPMH_CXO_CLK] = &clk_rpmh_bi_tcxo_div2.hw, + [RPMH_CXO_CLK_A] = &clk_rpmh_bi_tcxo_div2_ao.hw, + [RPMH_LN_BB_CLK1] = &clk_rpmh_clk6_a2.hw, + [RPMH_LN_BB_CLK1_A] = &clk_rpmh_clk6_a2_ao.hw, + [RPMH_LN_BB_CLK2] = &clk_rpmh_clk7_a2.hw, + [RPMH_LN_BB_CLK2_A] = &clk_rpmh_clk7_a2_ao.hw, + [RPMH_LN_BB_CLK3] = &clk_rpmh_clk8_a2.hw, + [RPMH_LN_BB_CLK3_A] = &clk_rpmh_clk8_a2_ao.hw, + [RPMH_RF_CLK3] = &clk_rpmh_clk3_a2.hw, + [RPMH_RF_CLK3_A] = &clk_rpmh_clk3_a2_ao.hw, + [RPMH_RF_CLK4] = &clk_rpmh_clk4_a2.hw, + [RPMH_RF_CLK4_A] = &clk_rpmh_clk4_a2_ao.hw, + [RPMH_RF_CLK5] = &clk_rpmh_clk5_a2.hw, + [RPMH_RF_CLK5_A] = &clk_rpmh_clk5_a2_ao.hw, +}; + +static const struct clk_rpmh_desc clk_rpmh_x1e80100 = { + .clks = x1e80100_rpmh_clocks, + .num_clks = ARRAY_SIZE(x1e80100_rpmh_clocks), +}; + static struct clk_hw *of_clk_rpmh_hw_get(struct of_phandle_args *clkspec, void *data) { @@ -838,6 +863,7 @@ static const struct of_device_id clk_rpmh_match_table[] = { { .compatible = "qcom,sm8450-rpmh-clk", .data = &clk_rpmh_sm8450}, { .compatible = "qcom,sm8550-rpmh-clk", .data = &clk_rpmh_sm8550}, { .compatible = "qcom,sc7280-rpmh-clk", .data = &clk_rpmh_sc7280}, + { .compatible = "qcom,x1e80100-rpmh-clk", .data = &clk_rpmh_x1e80100}, { } }; MODULE_DEVICE_TABLE(of, clk_rpmh_match_table);