From patchwork Mon Dec 18 12:06:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Manivannan Sadhasivam X-Patchwork-Id: 18233 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:24d3:b0:fb:cd0c:d3e with SMTP id r19csp1190884dyi; Mon, 18 Dec 2023 04:08:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IFEWejNtC7ko0kpBUYUjjpthTrrVQnuYEBRZE6WTnbJOtWlmhDAw+WWHhWPFjyqiTHGeN50 X-Received: by 2002:a50:ccc7:0:b0:553:75b0:754 with SMTP id b7-20020a50ccc7000000b0055375b00754mr334100edj.3.1702901283313; Mon, 18 Dec 2023 04:08:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702901283; cv=none; d=google.com; s=arc-20160816; b=sD2T3/QyJC116RRIIYcucT+2OQlRnVOgQKl9ySXr3cct2Gsv7YZuSavIcupgyjp3mu 0Sj8TF4lZcjEy/bvQPwzgQwd7BHaZcn/toPfd/8+HcWek0D8CkbfjK6XkWGzAXOviKfF SJDpHIWQW8GbNOP/1uXD74NTuRVWUlIKvRe/lsRINW59KT8kHX53vVzTmOlX5RaY7U0m 3UAgQVcXL6WweKXzTqY/BGq7iCRA0zcoldNqaa9jHN3iQZsAHZ3oCxEXnwo3cCtChUrP MwkFOVHrr6GGGqmajhM5JnzGqnsQFB32FeFuoZHtH2E4LovGrkT8P0SrTpsye/wCPiCT Rvzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=YIT2xVBZqZYxPQc446/fiLF5Jt+cT22dHCDUQGgryDo=; fh=yBeMP5CYoaCt9QDq1YHTsHgWGX03r+xhx0TLcWIjRWQ=; b=TNXl7mjJS+oA8gKiAEn45IOfH/vHNx149HgFz6ugMEa+5UHSYl02UfMdhzrrOueGbc nuZeRLdizwtuUaQEn/CXy9PNgHTb3oKrtk+nBZ9RoCKCHBvEnToBAllIjzxNS25ud/1A psRcErrB4KZpqFeJwsiNoQ/GW6rQQL6KJ/frGIvNtcqKKn/d3raKXnNXqHR+7hwH1qoV XK6BZYyFw5b/KfMr3KXXlOZAEZIUSyUqoZbN0Z1twl9rqqaZtVAWZA23vgAyzk73RfL7 X0Mh6z1jv4ncmxdZY722hGoAN8RCf5o5i5GOZEY1+f+xX77MY10bf6HaR0K5LZj0Z650 50uw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=grd9U0yu; spf=pass (google.com: domain of linux-kernel+bounces-3526-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3526-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id eg19-20020a056402289300b00553728e3ae5si232910edb.285.2023.12.18.04.08.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 04:08:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-3526-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=grd9U0yu; spf=pass (google.com: domain of linux-kernel+bounces-3526-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3526-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id D0A091F22B10 for ; Mon, 18 Dec 2023 12:08:02 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 51B7449F66; Mon, 18 Dec 2023 12:07:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="grd9U0yu" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-pl1-f172.google.com (mail-pl1-f172.google.com [209.85.214.172]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9FFDD4B148 for ; Mon, 18 Dec 2023 12:07:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-pl1-f172.google.com with SMTP id d9443c01a7336-1d098b87eeeso24944585ad.0 for ; Mon, 18 Dec 2023 04:07:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702901246; x=1703506046; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=YIT2xVBZqZYxPQc446/fiLF5Jt+cT22dHCDUQGgryDo=; b=grd9U0yuqervyuUiZ3fggnMTV5KN4l18q9swL+e8abU+xzs7mlWvboiTt/HgUf+Dvs 7RoM9pgl5kVJwQDMiezRo04n1dKsnRR1CpuDQuFkBV2Ykp7/T0ivX52KZt2c6pkYCrJW LWBhlBIGFSiSYHak2DUQmROIQBO3G9ElBe39a4CZl/I4c8jSVRFtWSvpasl7SM7Kv4hg 2ClWNJZRFhGt4uA87IYzcRZE6alsCXlx6Nb+W62MzUAKP3rvxWxcAtCN0cdekp1xSKHc uPD4j1D5shHazyW7xRXQjSJp2sH2JkpxRULZHcz+0tCqyF45hu60yTtnBZDVF3Mbffc1 N7kg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702901246; x=1703506046; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=YIT2xVBZqZYxPQc446/fiLF5Jt+cT22dHCDUQGgryDo=; b=SYW+FzeSb5NR3LJyZf4qxe8Lrv+7Z52YHb8dDVuBTFYHMlzXGDEPOPqpl1I0hy84w8 ELqVNSveL2qnSGMm/COqf02NQMqlTKqVB0EAEJi6Um2F2qIr3T2XOkBfjFpFTR9Yc5Sz KqCaPXIFw0J+syX+fMwcMyTVJNR1o67Jz9rExReTsmb6OxoXXEjH74Wt/w24XNdhil+8 TcQsGygWAbMlQKkEKg+gkbyx2t6yR1mFY8UMYBCZ+VZRmhv007SQnyajJ9QUX+Sx59ju fYxZf3SJR/mHv+P/8ylYMcypCCiTDEQUZTekZzPBxBX95EQuStdO3sTsWmhLv/Ul6K8W 3R6w== X-Gm-Message-State: AOJu0Yyvfg0lEjUiM6sTHLt2hcJe2c7o2bGGNcjKeV0tYq915O1ONqMk oXxo1Wc3LsWoQBpP4S1gzYwZ X-Received: by 2002:a17:902:ecc1:b0:1d0:60cc:7ebb with SMTP id a1-20020a170902ecc100b001d060cc7ebbmr19506524plh.25.1702901245929; Mon, 18 Dec 2023 04:07:25 -0800 (PST) Received: from localhost.localdomain ([117.207.27.21]) by smtp.gmail.com with ESMTPSA id j18-20020a170902c3d200b001d368c778dasm1285709plj.235.2023.12.18.04.07.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 04:07:25 -0800 (PST) From: Manivannan Sadhasivam To: andersson@kernel.org, konrad.dybcio@linaro.org, vkoul@kernel.org, sboyd@kernel.org, mturquette@baylibre.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org Cc: linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, quic_cang@quicinc.com, Manivannan Sadhasivam Subject: [PATCH v2 00/16] Fix Qcom UFS PHY clocks Date: Mon, 18 Dec 2023 17:36:56 +0530 Message-Id: <20231218120712.16438-1-manivannan.sadhasivam@linaro.org> X-Mailer: git-send-email 2.25.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1785621416034917834 X-GMAIL-MSGID: 1785621416034917834 Hi, This series fixes the clocks supplied to QMP PHY IPs in the Qcom SoCs. All of the Qcom SoCs except MSM8996 require 3 clocks for QMP UFS: * ref - 19.2MHz reference clock from RPM/RPMh * ref_aux - Auxiliary reference clock from GCC * qref - QREF clock from GCC or TCSR (TCSR since SM8550) MSM8996 only requires 'ref' and 'qref' clocks. Hence, this series fixes the binding, DT and GCC driver to reflect the actual clock topology. Note that the clock topology is not based on any downstream dts sources (even they are not accurate). But rather based on information from Qcom internal documentation and brain dump from Can Guo. Testing ======= Tested on Qualcomm RB5 development board based on SM8250 SoC. I don't expect this series to break other SoCs too. - Mani Manivannan Sadhasivam (16): dt-bindings: phy: qmp-ufs: Fix PHY clocks phy: qcom-qmp-ufs: Switch to devm_clk_bulk_get_all() API dt-bindings: clock: qcom: Add missing UFS QREF clocks clk: qcom: gcc-sc8180x: Add missing UFS QREF clocks arm64: dts: qcom: msm8996: Fix UFS PHY clocks arm64: dts: qcom: msm8998: Fix UFS PHY clocks arm64: dts: qcom: sdm845: Fix UFS PHY clocks arm64: dts: qcom: sm6115: Fix UFS PHY clocks arm64: dts: qcom: sm6125: Fix UFS PHY clocks arm64: dts: qcom: sm6350: Fix UFS PHY clocks arm64: dts: qcom: sm8150: Fix UFS PHY clocks arm64: dts: qcom: sm8250: Fix UFS PHY clocks arm64: dts: qcom: sc8180x: Fix UFS PHY clocks arm64: dts: qcom: sc8280xp: Fix UFS PHY clocks arm64: dts: qcom: sm8350: Fix UFS PHY clocks arm64: dts: qcom: sm8550: Fix UFS PHY clocks .../phy/qcom,sc8280xp-qmp-ufs-phy.yaml | 47 +++++++------- arch/arm64/boot/dts/qcom/msm8996.dtsi | 4 +- arch/arm64/boot/dts/qcom/msm8998.dtsi | 12 ++-- arch/arm64/boot/dts/qcom/sc8180x.dtsi | 6 +- arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 18 ++++-- arch/arm64/boot/dts/qcom/sdm845.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm6115.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm6125.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm6350.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm8150.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm8250.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm8350.dtsi | 8 ++- arch/arm64/boot/dts/qcom/sm8550.dtsi | 9 ++- drivers/clk/qcom/gcc-sc8180x.c | 28 +++++++++ drivers/phy/qualcomm/phy-qcom-qmp-ufs.c | 61 +++---------------- include/dt-bindings/clock/qcom,gcc-sc8180x.h | 2 + 16 files changed, 124 insertions(+), 119 deletions(-)