From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f53.google.com (mail-lf1-f53.google.com [209.85.167.53]) (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 DBEEF222565 for ; Mon, 29 Jun 2026 13:38:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.53 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782740314; cv=none; b=l5fqtV+v+x31a4GhJOFaPwO+h4CuLYlwjdlof4gOEDu22fkisSgw/Nly02ZydtguBBeR3AObNaPVZUaNk+EWF5e/7eroD6l7/H3FrB2ngbqM3edifsmIZ3Q0Towi2C1MIIyLO4s/6Ztn3SFh+DeL7qADzCpvMeQPVS97a3S/zt8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782740314; c=relaxed/simple; bh=TfGPUSh1Tkv5RQsbszpn0J091nTNxxCn1z8sG6lbaa4=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=EgNYIxtvxJRby4wSgHUSq+lnVcKilRVA9qr9AdGAojP0gUBzI5t2LnovtYZaDEt00Les3ty5igV485sLKRHIIWmwLOLyJ0uZYtR/ttr0tTbxLArXum/B1cQurFxv9cTTG8YVmb5kHQrpcaOFbjsbP2KkSpdSmKS7Uae9erUDGYM= 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=nJ/v7HWb; arc=none smtp.client-ip=209.85.167.53 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="nJ/v7HWb" Received: by mail-lf1-f53.google.com with SMTP id 2adb3069b0e04-5aeb0c46243so169042e87.1 for ; Mon, 29 Jun 2026 06:38:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1782740311; x=1783345111; darn=vger.kernel.org; h=content-transfer-encoding:content-type:in-reply-to:from:references :cc:to:subject:user-agent:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to:content-type; bh=zJW6e0aSzU7jXjzCKOKSVMzV7kCjNy2RKnzo8JF5eQ8=; b=nJ/v7HWbplWkjOcvCCCQutg4rzqmAMqUAaoodtWWIsG/YmtcBhp691pqEXdxzxJgeT Xbs7A+txNeOzMn+neBSnUhACZZ6AccrRI4L66QhHukN3Cm7olEGuFwkrX9JRzo25C7nK xEHzm6vCz5C6BkFhVOVWpQFrDdx+WSYQh9K6e/ns0UOmiTkHHWleU/W5ZKQPuDRXXPY2 rovCMmsiI36mzxNjoDl2RrzHQuMYuuq/CwasrT8YXi5aGZ10JUqORTQZBHAJjojpm5Tk dtjtgDgnG85BezrwUtFXenufbNETUlWdpTiEU73ieA8xL38Uw88KmkD4cK+WKNi5tpKa +Whw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1782740311; x=1783345111; h=content-transfer-encoding:content-type:in-reply-to:from:references :cc:to:subject: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=zJW6e0aSzU7jXjzCKOKSVMzV7kCjNy2RKnzo8JF5eQ8=; b=OIvAF/UAHPM+ZBRpOL+XnzlHiz7IjeSa2Jvbo+Z97b/C+ZgvH7RCie2TKehmoMpiJO +CveKo+W/0JSLszpX/Fg0jI9QVgzV5uKGcvzQdF4KjCAEkjQwHU/e6xtUP3ED6uk+5Fr 4xq/auCYe1RXTltbW8eZRQHNX/w4kbrU1Npz71oXCyuBdAiqzLv7DOlJ0T7PdvSPvBt1 pEEikPptMjrRFafJGylPcnVdnbGUB7TfCbq5SyDxKsKVa4KDrbZ9UIKvBKirCtNkD9VM 45faaXuW9f3hupL5YnjQwRPKKrP+GaETcpzW8D7ciMFQSYG0w0V5F1I82cy9fLZ5xFXb 8BMw== X-Forwarded-Encrypted: i=1; AHgh+Rpvmspfg4MC9mHW+GHvART2OZGEKdyNuzd2wPJX9Zjaxru4ZjPoP8JJluZISE8H9vl3dYk0ufBBioH6y8U=@vger.kernel.org X-Gm-Message-State: AOJu0YzlvV0YypfHr6o0aObB+rjR7laWRqnH3MY0z7YhoFfuWQEIRzcy lh+sEtWrOMl+PNt1dv6inpR0xRsuxA4GnE3OH7rlUIB3iyZRQl+4z//WAQJxKk5x2VQ= X-Gm-Gg: AfdE7clxJIK4B8OQeaCjAQK6a3og3NBl2Lro7N7e019oNTU0k6+5OrmEVWgq9taQGsX SLLFH7pkyEvn16WopU/GC8KHQtK0jfvltpcoS8K7tgj2kvZ65zhbMoLUK0oCUl4RgCdKycpsuRQ xLEdWcIH/WFcjddfaOMejh1OkrJv+uV7PzeCF675A+P+CSCsFWi4rEj2ShImjiITAkCe8GhSdKa 6El2NtXshOJRe27HNYEiBRH6Sy4flZP9Gm3c79N+Xa0NSh1flejHtKkECdOvejhyqqSODaUFYYp gLt7L8/yDY164y/vWmPuXu2b+FFbvSZWeMpyDOdm3CJ+Fn329W2lqUvTFkxRXvJC+QELIkvPmlq j6Q1dJxbxgT3BdtIlg+Bcji09tWuHqzT7Rc86tfiiACGSBBLTRHd+tpYzjFSiHOgaRVLaXBCDeX gV4qqPURaLd6nipUYGc6D6QefZXmgmCFvwss5mZSIhgRU9CGTYWCOMRK8TUeCbAQ2xEhg= X-Received: by 2002:a05:6512:3b11:b0:5ae:ba7d:8fad with SMTP id 2adb3069b0e04-5aeba7d9145mr395243e87.4.1782740310847; Mon, 29 Jun 2026 06:38:30 -0700 (PDT) Received: from [192.168.1.100] (91-159-24-186.elisa-laajakaista.fi. [91.159.24.186]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-5aeb72c186dsm1237741e87.43.2026.06.29.06.38.30 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 29 Jun 2026 06:38:30 -0700 (PDT) Message-ID: <569539db-b079-439a-bd05-cb97c30141c1@linaro.org> Date: Mon, 29 Jun 2026 16:38:29 +0300 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 2/4] dt-bindings: media: qcom: Add JPEG encoder binding To: Atanas Filipov , linux-media@vger.kernel.org Cc: mchehab@kernel.org, robh@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, andersson@kernel.org, quic_vgarodia@quicinc.com, quic_jesszhan@quicinc.com, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org References: <20260629121750.3469292-1-atanas.filipov@oss.qualcomm.com> <20260629121750.3469292-3-atanas.filipov@oss.qualcomm.com> From: Vladimir Zapolskiy In-Reply-To: <20260629121750.3469292-3-atanas.filipov@oss.qualcomm.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hi Atanas. On 6/29/26 15:17, Atanas Filipov wrote: > Add device-tree binding for the Qualcomm JPEG encoder hardware block > present in SM8250 (Kona) SoCs. > > The JPEG encoder is a standalone hardware IP within the camera subsystem > that performs JPEG compression in memory-to-memory fashion. It is > separate from the CAMSS ISP pipeline and has its own register space, > interrupt, clocks, power domain, IOMMU streams, and interconnect paths. > > Signed-off-by: Atanas Filipov > --- > .../bindings/media/qcom,jpeg-encoder.yaml | 160 ++++++++++++++++++ > 1 file changed, 160 insertions(+) > create mode 100644 Documentation/devicetree/bindings/media/qcom,jpeg-encoder.yaml > > diff --git a/Documentation/devicetree/bindings/media/qcom,jpeg-encoder.yaml b/Documentation/devicetree/bindings/media/qcom,jpeg-encoder.yaml > new file mode 100644 > index 000000000000..c8b4808054cb > --- /dev/null > +++ b/Documentation/devicetree/bindings/media/qcom,jpeg-encoder.yaml > @@ -0,0 +1,160 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/media/qcom,jpeg-encoder.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Qualcomm JPEG Encoder > + > +maintainers: > + - Atanas Filipov > + > +description: > + Qualcomm JPEG Encoder is the JPEG encode hardware present in Qualcomm SoCs. > + > +properties: > + compatible: > + enum: > + - qcom,sm8250-jenc > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + clocks: > + maxItems: 6 > + > + clock-names: > + items: > + - const: hf_axi > + - const: sf_axi > + - const: core_ahb > + - const: cpas_ahb > + - const: cnoc_axi > + - const: jpeg > + > + power-domains: > + maxItems: 1 > + > + iommus: > + description: > + Two SMMU stream IDs for the JPEG hardware. The first entry is for > + the JPEG core engine; the second is for the JPEG DMA/scale path. > + The exact stream ID assignment is SoC-specific and not publicly > + documented by Qualcomm. > + minItems: 2 > + maxItems: 2 > + > + interconnects: > + maxItems: 4 > + > + interconnect-names: > + items: > + - const: cpu-cfg > + - const: hf-mnoc > + - const: sf-mnoc > + - const: icp-mnoc > + > + operating-points-v2: true > + > + opp-table: > + type: object > + > +required: > + - compatible > + - reg > + - clocks > + - clock-names > + - interrupts > + - power-domains > + - iommus > + - interconnects > + - interconnect-names > + > +additionalProperties: false > + > +examples: > + - | > + #include > + #include > + #include > + #include > + > + soc { > + #address-cells = <2>; > + #size-cells = <2>; > + > + camss@ac6a000 { > + compatible = "qcom,sm8250-camss"; > + reg = <0 0x0ac6a000 0 0x2000>; > + #address-cells = <2>; > + #size-cells = <2>; > + ranges; > + > + jpeg-encoder@ac53000 { > + compatible = "qcom,sm8250-jenc"; > + reg = <0 0xac53000 0 0x1000>; > + > + interrupts = ; > + power-domains = <&camcc TITAN_TOP_GDSC>; > + > + clocks = <&gcc GCC_CAMERA_HF_AXI_CLK>, > + <&gcc GCC_CAMERA_SF_AXI_CLK>, > + <&camcc CAM_CC_CORE_AHB_CLK>, > + <&camcc CAM_CC_CPAS_AHB_CLK>, > + <&camcc CAM_CC_CAMNOC_AXI_CLK>, > + <&camcc CAM_CC_JPEG_CLK>; > + clock-names = "hf_axi", > + "sf_axi", > + "core_ahb", > + "cpas_ahb", > + "cnoc_axi", > + "jpeg"; > + iommus = <&apps_smmu 0x2040 0x400>, > + <&apps_smmu 0x2440 0x400>; > + > + interconnects = > + <&gem_noc MASTER_AMPSS_M0 0 &config_noc SLAVE_CAMERA_CFG 0>, > + <&mmss_noc MASTER_CAMNOC_HF 0 &mc_virt SLAVE_EBI_CH0 0>, > + <&mmss_noc MASTER_CAMNOC_SF 0 &mc_virt SLAVE_EBI_CH0 0>, > + <&mmss_noc MASTER_CAMNOC_ICP 0 &mc_virt SLAVE_EBI_CH0 0>; > + interconnect-names = "cpu-cfg", > + "hf-mnoc", > + "sf-mnoc", > + "icp-mnoc"; Since the proper option for describing this hardware is to have it as a child device tree node of CAMSS device tree node, which should serve or be percepted as a bus, it makes no sense to repeat and moreover rename bus/parent's resources, here is the list: * "hf_axi", "sf_axi", "core_ahb", "cpas_ahb" and "cnoc_axi" clocks, * Titan GDSC power domain and all four interconnects. Only "jpeg" clock and iommus are left specific to the hardware description of this IP under CAMSS, right? Thus, it should be reflected like this in the dt description as well, and the complexity of shared resource management has to be done in the driver, which might be tedious unfortunately, but certainly doable. > + > + operating-points-v2 = <&jpeg_opp_table>; > + > + jpeg_opp_table: opp-table { > + compatible = "operating-points-v2"; > + > + opp-300000000 { > + opp-hz = /bits/ 64 <300000000>; > + opp-level = <0>; > + required-opps = <&rpmhpd_opp_svs>; > + }; > + > + opp-400000000 { > + opp-hz = /bits/ 64 <400000000>; > + opp-level = <1>; > + required-opps = <&rpmhpd_opp_svs>; > + }; > + > + opp-480000000 { > + opp-hz = /bits/ 64 <480000000>; > + opp-level = <2>; > + required-opps = <&rpmhpd_opp_svs_l1>; > + }; > + > + opp-600000000 { > + opp-hz = /bits/ 64 <600000000>; > + opp-level = <3>; > + required-opps = <&rpmhpd_opp_nom>; > + }; > + }; > + }; > + }; > + }; -- Best wishes, Vladimir