Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp18937424rwd; Wed, 28 Jun 2023 02:48:54 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ62XhrT4TkcP14m8seYF5xOO7A97dQYbdmViLmTuMgTTXYtlYLvgxl9AGvNfUWIjSWK0aXW X-Received: by 2002:a05:6a20:3d12:b0:125:dee7:cfed with SMTP id y18-20020a056a203d1200b00125dee7cfedmr10747507pzi.16.1687945733719; Wed, 28 Jun 2023 02:48:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687945733; cv=none; d=google.com; s=arc-20160816; b=WZ/a/ABqabjkX82Sex/vPrhBeijRnPcQPLiPHo0Y/RnWqdq+8Z2+OgW3Y2UhgOQuDc aDtc8zQsDC+b2K2g1t+SJBdl5XaCPP8EPtjr18RXULYEnY6uQXS0X7ZZXy6t6Le5rzwq omN58kJDxyAO/mtldjSEo/kGyE1N+KxPTMs1OaWBfz/AcS66JVOPR174AzHfDOfvlZXL +fW/G/qoqHfthZm8PzODtQSeWlmVV2wX3vlkRGatXY66P7gRFLBN05FDvMGtCG06tRLf +d4am+afFPr7XesyLOwRqWvTsF/5vjBnXKK2S7OnFHnCjo1n7xfLdY6KeGq231vZ/kmr SMFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=aTyQYBqnv5lZLmGa5ZgXjaO2FVawaJRwjSBPrESS2aE=; fh=w4jsPtcPsVeA09vMnWtt1CUCL1R8oa8DphqzCofVFbs=; b=c11MleU7c+ttkECiMKv5V1Gcx0KFQdhYmRa2ZHCX/SGQIwC1yvBQF8I6nDpZyc4FYm MAKDhUMiUaZJHPJw/qzDVpLFdxV/1JzECZFtAm3w18lgon82Gt6w7DoyY1inJnotcUHV nOrboqNeKXpP6epdsC9BoB6NzcZKqBwb5zNg2pHMX+jvFGPW+MZgrIWtYocTcYRFOqIq TA+gmkaEHWUNQ6DZJalYR083a4dlgYWdGsIsVfZUvlkrMnwsf+R/LIzJHJKi6Fytgeo2 bol11et4aLONj2kgwIHbfpWI15gxEtLCkNSy+RC23HOV336x+1jvgPkF7M3InYQBp1XE Fe/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=gO3KlcCW; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q3-20020a656843000000b0054ff67d6666si8496519pgt.512.2023.06.28.02.48.41; Wed, 28 Jun 2023 02:48:53 -0700 (PDT) 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=gO3KlcCW; 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 S235331AbjF1Jed (ORCPT + 99 others); Wed, 28 Jun 2023 05:34:33 -0400 Received: from mx0b-0031df01.pphosted.com ([205.220.180.131]:20778 "EHLO mx0b-0031df01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233637AbjF1J3Z (ORCPT ); Wed, 28 Jun 2023 05:29:25 -0400 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 35S5tCNE007034; Wed, 28 Jun 2023 09:29:15 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-transfer-encoding : content-type; s=qcppdkim1; bh=aTyQYBqnv5lZLmGa5ZgXjaO2FVawaJRwjSBPrESS2aE=; b=gO3KlcCWcXQnrw4onb5XahR26Ks2OMoozNOziR2GhaHxNF4ez5lT4763HdD1/7mPHP5W L2mp561syBzrQeDvqwJ8p/QFDUT09eXv8zUjDWd3q2h3fs0eXeBpICBzWrgiBHRUdla3 9JvIOHQBedn1A4uiJ9KWejHmXbnMEZhhxIt6R9UFDANSPgJBO2d008/2GujpWS0dXcpz aoLobmCCQ+yDT0hP+nfv1emX4Rt3Mp4nLrJiCt8Ii1d+lmmMhOhc/pwcdiZrDnjuuMGs 4dqzXwggVFyrduS68HwaG3QywLt2tzwaOad72/dSEoIv86QN4gRDs2bSvqjNre9mmeQu 2Q== Received: from nasanppmta03.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3rgetpghk5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 28 Jun 2023 09:29:15 +0000 Received: from nasanex01a.na.qualcomm.com (nasanex01a.na.qualcomm.com [10.52.223.231]) by NASANPPMTA03.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 35S9TEe3014784 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 28 Jun 2023 09:29:14 GMT Received: from hu-imrashai-hyd.qualcomm.com (10.80.80.8) by nasanex01a.na.qualcomm.com (10.52.223.231) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.42; Wed, 28 Jun 2023 02:29:09 -0700 From: Imran Shaik To: Andy Gross , Konrad Dybcio , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley CC: Taniya Das , Imran Shaik , Melody Olvera , "Dmitry Baryshkov" , , , , , Jagadeesh Kona , Satya Priya Kakitapalli , Ajit Pandey Subject: [PATCH V2 2/5] clk: qcom: gcc-qdu1000: Fix gcc_pcie_0_pipe_clk_src clock handling Date: Wed, 28 Jun 2023 14:58:34 +0530 Message-ID: <20230628092837.3090801-3-quic_imrashai@quicinc.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230628092837.3090801-1-quic_imrashai@quicinc.com> References: <20230628092837.3090801-1-quic_imrashai@quicinc.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nasanex01a.na.qualcomm.com (10.52.223.231) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: xgXSDepepyXmkGB-IDzQVAuWXVCu8rgv X-Proofpoint-GUID: xgXSDepepyXmkGB-IDzQVAuWXVCu8rgv X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.957,Hydra:6.0.591,FMLib:17.11.176.26 definitions=2023-06-28_06,2023-06-27_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 adultscore=0 mlxlogscore=999 spamscore=0 priorityscore=1501 suspectscore=0 clxscore=1015 bulkscore=0 mlxscore=0 phishscore=0 lowpriorityscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2305260000 definitions=main-2306280082 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fix the gcc_pcie_0_pipe_clk_src clock handling for QDU1000 and QRU1000 SoCs. Fixes: 1c9efb0bc040 ("clk: qcom: Add QDU1000 and QRU1000 GCC support") Co-developed-by: Taniya Das Signed-off-by: Taniya Das Signed-off-by: Imran Shaik --- Changes since v1: - Newly added drivers/clk/qcom/gcc-qdu1000.c | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) diff --git a/drivers/clk/qcom/gcc-qdu1000.c b/drivers/clk/qcom/gcc-qdu1000.c index 5051769ad90c..c00d26a3e6df 100644 --- a/drivers/clk/qcom/gcc-qdu1000.c +++ b/drivers/clk/qcom/gcc-qdu1000.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0-only /* - * Copyright (c) 2022, Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2022-2023, Qualcomm Innovation Center, Inc. All rights reserved. */ #include @@ -370,16 +370,6 @@ static const struct clk_parent_data gcc_parent_data_6[] = { { .index = DT_TCXO_IDX }, }; -static const struct parent_map gcc_parent_map_7[] = { - { P_PCIE_0_PIPE_CLK, 0 }, - { P_BI_TCXO, 2 }, -}; - -static const struct clk_parent_data gcc_parent_data_7[] = { - { .index = DT_PCIE_0_PIPE_CLK_IDX }, - { .index = DT_TCXO_IDX }, -}; - static const struct parent_map gcc_parent_map_8[] = { { P_BI_TCXO, 0 }, { P_GCC_GPLL0_OUT_MAIN, 1 }, @@ -439,16 +429,15 @@ static struct clk_regmap_mux gcc_pcie_0_phy_aux_clk_src = { }, }; -static struct clk_regmap_mux gcc_pcie_0_pipe_clk_src = { +static struct clk_regmap_phy_mux gcc_pcie_0_pipe_clk_src = { .reg = 0x9d064, - .shift = 0, - .width = 2, - .parent_map = gcc_parent_map_7, .clkr = { .hw.init = &(const struct clk_init_data) { .name = "gcc_pcie_0_pipe_clk_src", - .parent_data = gcc_parent_data_7, - .num_parents = ARRAY_SIZE(gcc_parent_data_7), + .parent_data = &(const struct clk_parent_data){ + .index = DT_PCIE_0_PIPE_CLK_IDX, + }, + .num_parents = 1, .ops = &clk_regmap_phy_mux_ops, }, }, -- 2.25.1