From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) (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 6E746386C1C for ; Tue, 21 Jul 2026 08:15:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.41 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784621748; cv=none; b=IcNu4YpOs75XKlvtYnBB5osN08vCvsqpwkTm7IBn+FFVdNmLoHa52QERh96TI4WItW4sJyj5kAAOMDxpBDaXGGa+nk2oHbRd3OnBiSp3HGmYPxnbwueJYRcNxUvO+z2+fultNMXxCqQThphXGByc/Du9o+7sFco/rixMK9iiKfY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784621748; c=relaxed/simple; bh=prhorMOs0HUs4HPMOoyn3Wxj7sy84z7z9tcp/RjFPvo=; h=Message-ID:Date:MIME-Version:From:Subject:To:Cc:References: In-Reply-To:Content-Type; b=IfTjJU2Ey0EanZKYHNe0XSzDNBjrMFaZ+EEhgpm83BA7htYnYI10dbbnoAml/twbJjzYKhzQgPefrPyKR80dU9vEDOsvb9hydBnNUUHljZqneIlIfR6aOc2fEiwzeOvwoPG78LJhceNbL+JzFvwoiF7L/gNWjrMjKCpyMdBZMAo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=vsTC1/nm; arc=none smtp.client-ip=209.85.221.41 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 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="vsTC1/nm" Received: by mail-wr1-f41.google.com with SMTP id ffacd0b85a97d-4799b3f7c83so7955763f8f.2 for ; Tue, 21 Jul 2026 01:15:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1784621732; x=1785226532; darn=vger.kernel.org; h=content-transfer-encoding:content-type:in-reply-to:organization :autocrypt:content-language:references:cc:to:subject:reply-to:from :user-agent:mime-version:date:message-id:from:to:cc:subject:date :message-id:reply-to:content-type; bh=ZYoAtIkHW87FIAd0vM+TKdI5UC2ppQruRqxPUsfJzmE=; b=vsTC1/nmIHqMBYyt8RzRVERPI6lqz+eDYrvMeYS+647+48QW9wkrJ43Ep2gxHTvKGm KHwLcvGVxYI0LG9dyhVGXLZ+CoLUsG3MvTGDaFSdw25rVd+zM0Z6x72mIow63B35qnLs zw2DdiPhBsPRfKcHyzuw+QXVp0zf8RUwcpviQzsIjIU6wNCnzmCZSLzhDmHKp4Ng8Whl bZrjKtHXMf/gemHNwYKOo5tJoBMagYuZpT6ofr0jUETs2z7iWYtubkXRhIQGxMeVNm2p tr3hZI6s2BNNnylL5gJGEETH6Z4Bxv7SQ2lf5LpQhwnA8rKqVM0sohKx0fLF7+v60nLO hvhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1784621732; x=1785226532; h=content-transfer-encoding:content-type:in-reply-to:organization :autocrypt:content-language:references:cc:to:subject:reply-to:from :user-agent:mime-version:date:message-id:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to:content-type; bh=ZYoAtIkHW87FIAd0vM+TKdI5UC2ppQruRqxPUsfJzmE=; b=YkQuhMsl/nzBcC1K73m03B40I8Ma7BhumPt4oy/NaYakBYOMYYGc1EYOoeVPK65KkA ldqvLO0fJd1c54jL94GNir+jZKpa1iqRfBQ1CTX289yUUQ+8XxRVxbq4IQaJ+d93Bm6I caymjAbrsPg3+787vWs8zDeri8FsVj0IWQ4RrY11PTaSgWDCqaoqIn+XXQUESslhk+He xTGf36Ekza44TnlweVpNqpcemC0kwGqkRufVCzxzSxgnwhqe62yPYq/KxainWnh+NUZM wnhgDwE3hyraCeK6xKt/efEGcwsTOgtaFQFpo6uzVg5aM5ZT64PPdLOyaV7YyCoEcHX/ F59Q== X-Forwarded-Encrypted: i=1; AHgh+RptBXb+p8VaWnZc6uF9M1eXEQabFV1DS6i9fSK3q35cy9+ssy1SgEO/31sEdC8wtcUBHmJ1BUv54KsN3HM=@vger.kernel.org X-Gm-Message-State: AOJu0YwDMhq6uLurzpGjb/GwiE2uPH0Qfglf2vxe/3U39fPs5TEwIFjr qTcwrYHQ0IwbJW4mIevaj97GJBS7rdwuXe5xf4SF/JNsBe2oJJtj5sx+XwnTlTngEG8= X-Gm-Gg: AR+sD129WyohdfhFvBXmt3GeJ6cWxwX3xC7Au5GKAgeXCnK1sx4x4UmSQMgpATVAy4i hV46yndNXVV5g/1E5sRI2u8fK4ODlyaIPHhk4dRDj9U6k/G2skWX0vpjkcX0AXZXPJqAs648zdK y+YsG9yQK9MYcZmRuMVo3HTYBHqbrW83idkmp0Hvxe9Rg5nEKN3mTCSlGTc4NtTH7xwo0ryouDU klS6ixPihZ0t0JItqxL7bCs5pM+3HDA2kHoljEf2am0sOAp9OT0Cn9R1NZLUcHRagi0SDF9KwLc 5m5mfdYtPnJUBZIyNdo/RjI6QNCw2p0hiJvo71veUKc6LtOKntqfL+3JYilrwhNNNvXDGJ8k9Sy Ddimsv5mbBnNwhbmN8u/KnI6i37Kd40sN2LVYpT3WdwuPTylpQPSnEBJSc/cCpgLJbtO9RKRLfo 1CgCSME/DAp3I0EEfkpYwMHJYwAzTh5+C7GKxxx/bbl0JnC6sa81wt/3c= X-Received: by 2002:adf:e00f:0:20b0:47f:77ae:d8f9 with SMTP id ffacd0b85a97d-47f77aeda2emr6547848f8f.59.1784621731787; Tue, 21 Jul 2026 01:15:31 -0700 (PDT) Received: from ?IPV6:2a01:e0a:106d:1080:588:18d6:82ff:eb96? ([2a01:e0a:106d:1080:588:18d6:82ff:eb96]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-47f6b85970esm30396524f8f.15.2026.07.21.01.15.31 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Jul 2026 01:15:31 -0700 (PDT) Message-ID: <4c9ef1ac-1748-4604-99af-52e37877b23b@linaro.org> Date: Tue, 21 Jul 2026 10:15:30 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Neil Armstrong Reply-To: Neil Armstrong Subject: Re: [PATCH v13 1/2] dt-bindings: phy: qcom: Add CSI2 C-PHY/DPHY schema To: Bryan O'Donoghue , Vinod Koul , Kishon Vijay Abraham I , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: Bryan O'Donoghue , Vladimir Zapolskiy , linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org, linux-media@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Krzysztof Kozlowski References: <20260720-x1e-csi2-phy-v13-0-160c31958863@linaro.org> <20260720-x1e-csi2-phy-v13-1-160c31958863@linaro.org> Content-Language: en-US, fr Autocrypt: addr=neil.armstrong@linaro.org; keydata= xsBNBE1ZBs8BCAD78xVLsXPwV/2qQx2FaO/7mhWL0Qodw8UcQJnkrWmgTFRobtTWxuRx8WWP GTjuhvbleoQ5Cxjr+v+1ARGCH46MxFP5DwauzPekwJUD5QKZlaw/bURTLmS2id5wWi3lqVH4 BVF2WzvGyyeV1o4RTCYDnZ9VLLylJ9bneEaIs/7cjCEbipGGFlfIML3sfqnIvMAxIMZrvcl9 qPV2k+KQ7q+aXavU5W+yLNn7QtXUB530Zlk/d2ETgzQ5FLYYnUDAaRl+8JUTjc0CNOTpCeik 80TZcE6f8M76Xa6y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2SD6PO9umRef8V82o2oaCLvf4WeIssFjwB0b6a12opuRP7yo3E3gTCS KmbUuLv1CtxKQF+fUV1cVaTPMyT25Od+RC1K+iOR0F54oUJvJeq7fUzbn/KdlhA8XPGzwGRy 4zcsPWvwnXgfe5tk680fEKZVwOZKIEuJC3v+/yZpQzDvGYJvbyix0lHnrCzq43WefRHI5XTT QbM0WUIBIcGmq38+OgUsMYu4NzLu7uZFAcmp6h8g Organization: Linaro In-Reply-To: <20260720-x1e-csi2-phy-v13-1-160c31958863@linaro.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hi, On 7/20/26 03:11, Bryan O'Donoghue wrote: > Add a base schema for the MIPI CSI2 PHYs on Qualcomm SoCs. This PHY > supports both DPHY and CPHY operation. A special mode of DPHY operation - > called variously split-mode or combo-mode also allows for two sensors to be > connected to one PHY. > > The submitted binding here describes the DPHY modes of operation only. CPHY > is left to future work. > > Reviewed-by: Krzysztof Kozlowski > Signed-off-by: Bryan O'Donoghue > --- > .../bindings/phy/qcom,x1e80100-csi2-phy.yaml | 195 +++++++++++++++++++++ > 1 file changed, 195 insertions(+) > > diff --git a/Documentation/devicetree/bindings/phy/qcom,x1e80100-csi2-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,x1e80100-csi2-phy.yaml > new file mode 100644 > index 0000000000000..880fe602945cb > --- /dev/null > +++ b/Documentation/devicetree/bindings/phy/qcom,x1e80100-csi2-phy.yaml > @@ -0,0 +1,195 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/phy/qcom,x1e80100-csi2-phy.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Qualcomm X1E80100 SoC CSI2 PHY > + > +maintainers: > + - Bryan O'Donoghue > + > +description: > + Qualcomm MIPI CSI2 C-PHY/D-PHY combination PHY. Connects MIPI CSI2 sensors > + to Qualcomm's Camera CSI Decoder. The PHY supports both C-PHY and D-PHY > + modes. > + > +properties: > + compatible: > + const: qcom,x1e80100-csi2-phy > + > + reg: > + maxItems: 1 > + > + "#phy-cells": > + const: 1 > + description: > + The single cell specifies the PHY operating mode. > + > + clocks: > + maxItems: 3 > + > + clock-names: > + items: > + - const: core > + - const: timer > + - const: ahb > + > + interrupts: > + maxItems: 1 > + > + operating-points-v2: true > + > + opp-table: > + type: object > + > + power-domains: > + items: > + - description: Titan Top GDSC - Titan ISP Block, Global Distributed Switch Controller. > + - description: MMCX voltage rail > + - description: MXC or MXA voltage rail > + > + power-domain-names: > + items: > + - const: top > + - const: mmcx > + - const: mx > + > + vdda-0p9-supply: > + description: Phandle to a 0.9V regulator supply to a PHY. > + > + vdda-1p2-supply: > + description: Phandle to 1.2V regulator supply to a PHY. > + > + ports: > + $ref: /schemas/graph.yaml#/properties/ports > + > + properties: > + port@0: > + $ref: /schemas/graph.yaml#/$defs/port-base > + description: > + Sensor input. Always present. A single sensor is described by a > + single endpoint with one to four data lanes. DPHY split mode, > + where two independent sensors share the same PHY, is described > + by two endpoints; endpoint@0 with exactly two data-lanes and > + endpoint@1 with exactly one data-lane. > + unevaluatedProperties: false > + > + patternProperties: > + "^endpoint(@[0-9a-f]+)?$": > + $ref: /schemas/media/video-interfaces.yaml# > + unevaluatedProperties: false > + properties: > + data-lanes: > + minItems: 1 > + maxItems: 4 > + > + required: > + - data-lanes > + - remote-endpoint > + > + allOf: > + - if: > + required: > + - endpoint@1 > + then: > + properties: > + endpoint@0: > + properties: > + data-lanes: > + minItems: 2 > + maxItems: 2 > + endpoint@1: > + properties: > + data-lanes: > + maxItems: 1 > + required: > + - endpoint@0 > + > + port@1: > + $ref: /schemas/graph.yaml#/properties/port > + description: Output to the CAMSS CSID controller. > + > + required: > + - port@0 > + - port@1 > + > +required: > + - compatible > + - reg > + - "#phy-cells" > + - clocks > + - clock-names > + - interrupts > + - operating-points-v2 > + - power-domains > + - power-domain-names > + - vdda-0p9-supply > + - vdda-1p2-supply > + - ports > + > +additionalProperties: false > + > +examples: > + - | > + #include > + #include > + #include > + #include > + > + phy@ace4000 { > + compatible = "qcom,x1e80100-csi2-phy"; > + reg = <0x0ace4000 0x2000>; > + #phy-cells = <1>; > + > + clocks = <&camcc CAM_CC_CSIPHY0_CLK>, > + <&camcc CAM_CC_CSI0PHYTIMER_CLK>, > + <&camcc CAM_CC_CORE_AHB_CLK>; > + clock-names = "core", > + "timer", > + "ahb"; > + > + interrupts = ; > + > + operating-points-v2 = <&csiphy_opp_table>; > + > + power-domains = <&camcc CAM_CC_TITAN_TOP_GDSC>, > + <&rpmhpd RPMHPD_MMCX>, > + <&rpmhpd RPMHPD_MX>; > + power-domain-names = "top", > + "mmcx", > + "mx"; > + > + vdda-0p9-supply = <&vreg_l2c_0p9>; > + vdda-1p2-supply = <&vreg_l1c_1p2>; > + > + ports { > + #address-cells = <1>; > + #size-cells = <0>; > + > + port@0 { > + reg = <0>; > + csiphy0_in: endpoint { > + data-lanes = <0 1 2 3>; > + remote-endpoint = <&sensor_out>; > + }; > + }; > + > + port@1 { > + reg = <1>; > + csiphy0_out: endpoint { > + remote-endpoint = <&csid_in>; > + }; > + }; > + }; > + > + csiphy_opp_table: opp-table { > + compatible = "operating-points-v2"; > + > + opp-300000000 { > + opp-hz = /bits/ 64 <300000000>; > + required-opps = <&rpmhpd_opp_low_svs_d1>, > + <&rpmhpd_opp_low_svs_d1>; > + }; > + }; > + }; > While I see the utility of moving the CSI PHY into a separate node and transferring the sensor endpoints there, I don't see why the PHYs would be linked to CAMSS via the `phys =` property and via a port/endpoint to the CSIDs. In my view, the `phys =` property should be used to reference static PHYs associated with a controller, whereas port/endpoint graphs are better suited for identifying the node and device for dynamic PHYs, like the ones we have here. To that extent, I understand how moving this to the PHY framework could help clean up the code. However, some PHY-related logic will still need to remain in CAMSS to handle dynamic associations to different CSIDs at runtime. I'm still not really convinced about moving this code to the PHY subsystem as a standalone PHY driver. Neil