From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BF34C42EED5 for ; Wed, 13 May 2026 14:30:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778682653; cv=none; b=oa3AuG/7HbvaGODLZImSO2zKkAVdDjHQDxYLmvE5r1LC9Shs9KRKt0Thvjev0VPrHBkFIs7hNASojP6TNx2NVHS6qKqeebfCxks7sP3mPu19moifSYicjV/s1e/0MGXjPWzFS2pk8eeEk4aTrwwc8OQwH7Qg5Q2h41bnF/qWeqM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778682653; c=relaxed/simple; bh=9vwn9p/G3SBynF/R6x9abjmpGFFEqEuhbl5fGpI/Xo4=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=Os/5SB4HvVjmhlHADHOQcgVfMy8tkqsU7GLHFHjQi7kNJV36tlUjnQgCMyK0JOfTEzVg7R3UamEneCQ0Ga3hDzhLkfkQ1tDHkEVIi/DuClnSyLjppgxk1JdJkRENj5Kpmj9FoRh/GbWUuyvQe18XmmHtYifZZmSnbRNObkb7tBE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=ZV2cLJMZ; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=eoBz9nuR; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="ZV2cLJMZ"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="eoBz9nuR" Received: from pps.filterd (m0279870.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 64DACwE92338782 for ; Wed, 13 May 2026 14:30:50 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= kRdRHlj/4FYDgqpaQppw+iq5ofthvt61GQTIwvPfv54=; b=ZV2cLJMZDRi4atUp 7gvRykW+ST4ITAgk7scyikVL3gdndFwbo8rKTvUhKXHkmRh/l9CrpfFMY8yQXqfG fT9sv3BgWY/Wsuqf8WPUwAkc/+JoL1+oobkfZhbjbqrzfufmDCbHaF2fSMCVmocp rmcAijS8MpXPFEyF2JSxlejK06CsckT/SHVM++3DHpn0MHHMBpcl7Slt/x74oKsa dRsXBYABpnZuaBFVG4o5QVV47Kd1LSVnr7DLXBmIWFlT8seqt/qaU2Wpm5nQC6M9 Ge4mMXfPQ5jIZjrneJpkuiyZr+GPzqaZqdGvHV0iuchr69jgVvf+sq5L6y8SRclh tYEGog== Received: from mail-pf1-f197.google.com (mail-pf1-f197.google.com [209.85.210.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4e49vxbw3j-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 13 May 2026 14:30:50 +0000 (GMT) Received: by mail-pf1-f197.google.com with SMTP id d2e1a72fcca58-836d0184333so6594790b3a.0 for ; Wed, 13 May 2026 07:30:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1778682650; x=1779287450; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=kRdRHlj/4FYDgqpaQppw+iq5ofthvt61GQTIwvPfv54=; b=eoBz9nuRq4YRspFMGC3/VyVm5e95DLTh8Q+i3IE6zLJfZ19DAl+pbZm5Medftp3S71 WZWvN6IfuH8x8hrYuDGseh79gV8Q7oifAqhujFxLC0fXwjivOMLESnFTsMiaC8xuaiNO HoMa3ZEeNU9Q3ikYQKZut6mOYyNLw85E5c7k8wVT3oAn2G9KR+oIVeVJ+6fWrFKr5fL8 rukp+lOUJwSTR+9uYpe3O5fMyg1sggXZHqYpbFxYIRarjsOYb6mMwzQCoqDqpkt037n+ lHXpTAMgUGjrJAY0MtqxTqctrhy5egnTocoEalSPbU82is7S0P+fVwAfVwh/IG2nUMKB gmOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778682650; x=1779287450; h=content-transfer-encoding:in-reply-to:from:content-language :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; bh=kRdRHlj/4FYDgqpaQppw+iq5ofthvt61GQTIwvPfv54=; b=ay9qhssO4KqD8PoD3CdfU4FWvzBPHv0xSCbxmP9Sde44fn2YHvc5U51MFvkW3IlLRN kC+L9ANq2MO1PuOqHW9MSzJNJtbJktEZYuftKqVP0RGR08R31lHlx+2KSlDL2E6pEe04 LlhudJmE+Ci99rrzhr6lyUI5wVcrg/Omm0UuE/XUE3UxWfFom4KN/k2YBx/WUxbhRJWH nyGpSVQlAQ0Kox2wGa1GU9tR2qMHDlzt+jn01+iZwwVHiQvMBa0egGm6wO92NXuzt68L sN3bMDM8Y2FGyVcfRh6gDjEDNiWcfjnVhZtcjraIEofTz2UpyzwOX8aXWjeZxIuKxU0F bRIQ== X-Forwarded-Encrypted: i=1; AFNElJ+nihiqiHsZM7aqOELvpHu4ghoClb1+DcYqiOhX5rAXqfuN56YAjh/8omdGuSG8sOSaf7NrouKBvGWytf8=@vger.kernel.org X-Gm-Message-State: AOJu0Yzh2lGBe2k9KMuktSRCIkgR17ael/+uvYd+82mHNRCHFfHQDOHx 6kQyCKlyTUkwI0sYtxMrlf9V3+sh1NDugMC1GO14kWTrzisdobcPXiHRimgTtgfgTWlKvt6yYir mvZHfA0Exv3fHbXcxNuepb4ClqeawnT+o+nHMjF8lszunC3e8LNGf/LevYwR/bkxju3g= X-Gm-Gg: Acq92OFnQK9ZAS6DRdzti1gZKp8PG5kY3cAJp444mN3GJyxgVJD/lAn6406801YWkIx QwzUGYBsVnHUOoNyUrVVCXFZg8vZnOlSImEg9VkYoJZdTDXu6bUhnyth4cF2YfdAW6CJL/PYUVb Blq99G1VILFXnNmGmmPoJcmXBw9UnyWp6l2WLqq/fvLuZJyZ16ZApsz4Ujz9CAD9j1/WChwBmZ2 nYAfpLP4EGcBCaWNYaFoQ6I4ZHNpt+ZGfAQikYULrS5+Pvc/SjaATprIwRp/Phn6DeW8pS4SPNE 4634HbfoWp8JNKOFOIOsntRKVSQiZE/hDhHaQEEjS3UC5kiAFM7Hcc9ZRxWb2PFix9Gqe9Hq8xR /5HGkDVX6QmqEQU5UD1663ZXALRwtcm2EcNhCgipJ/l79SZwSA5M2Ey8= X-Received: by 2002:a05:6a00:22c6:b0:82c:dfea:9e2a with SMTP id d2e1a72fcca58-83f0542d985mr3656144b3a.2.1778682649618; Wed, 13 May 2026 07:30:49 -0700 (PDT) X-Received: by 2002:a05:6a00:22c6:b0:82c:dfea:9e2a with SMTP id d2e1a72fcca58-83f0542d985mr3656058b3a.2.1778682649050; Wed, 13 May 2026 07:30:49 -0700 (PDT) Received: from [10.204.101.125] ([202.46.23.25]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-83967dbcf16sm31628277b3a.40.2026.05.13.07.30.41 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 13 May 2026 07:30:48 -0700 (PDT) Message-ID: Date: Wed, 13 May 2026 20:00:39 +0530 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 v5 12/14] media: iris: Add platform data for glymur To: Dmitry Baryshkov , Vishnu Reddy Cc: Dikshita Agarwal , Abhinav Kumar , Bryan O'Donoghue , Mauro Carvalho Chehab , Joerg Roedel , Will Deacon , Robin Murphy , Hans Verkuil , Stefan Schmidt , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stanimir Varbanov , Jorge Ramirez-Ortiz , Del Regno , Bjorn Andersson , Konrad Dybcio , linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, iommu@lists.linux.dev, Krzysztof Kozlowski , devicetree@vger.kernel.org References: <20260509-glymur-v5-0-7fbb340c5dbd@oss.qualcomm.com> <20260509-glymur-v5-12-7fbb340c5dbd@oss.qualcomm.com> Content-Language: en-US From: Vikash Garodia In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Proofpoint-ORIG-GUID: AqfkXlaBex-CJhvzaIv4eah2LrBLRFHG X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNTEzMDE0OSBTYWx0ZWRfX+WihqVm5ja0u EDsVPmE/j0EmXlEoBSrwG64Ft+25/k8+2uXJWPwY1BlbJ44PpQC9+bcID7wlGzstNXANnp5LtOA xayDvwJUjsyAGz25CFwZr4bSThnLkKIfL4ub6QT3cCxhUA46Vt3ox/GFOK/Olo6ED5osPTe6pj6 64yF9LoK1lTl9U617HkLlo6MuA/zmD/OuMgnamTsDjzoIHPuxo8ykZLlLB4J4Siv283CQ3K2mmJ 10UnwsEGWrbVX5Vi7wu4nXdSMrabpuG/3sXtRWD0Z6OHoPrIZ5xKFqqX15JFV1rkUMmM4VjF+wa aQm6aFry1wiyAt0nB1NIbVr1jkjaz4UWmPmMLyb8AK0r30Gcn1fg651La+ihOBWbLbAW+EX2PpM u3giYORszz59W5n/F23vnf4gPcNNEgqeacFrBy1GCcoVUs9Wp6a4IjDim/bUuDAhB5KnmyXu6qb j4bR1xwtAF1DvOvCOlg== X-Proofpoint-GUID: AqfkXlaBex-CJhvzaIv4eah2LrBLRFHG X-Authority-Analysis: v=2.4 cv=A8Fc+aWG c=1 sm=1 tr=0 ts=6a048b1a cx=c_pps a=rEQLjTOiSrHUhVqRoksmgQ==:117 a=ZePRamnt/+rB5gQjfz0u9A==:17 a=IkcTkHD0fZMA:10 a=NGcC8JguVDcA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=gowsoOTTUOVcmtlkKump:22 a=EUspDBNiAAAA:8 a=AkRF1kMk2nwCDGt8pKAA:9 a=QEXdDO2ut3YA:10 a=2VI0MkxyNR6bbpdq8BZq:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-05-13_01,2026-05-13_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 suspectscore=0 impostorscore=0 bulkscore=0 phishscore=0 clxscore=1015 priorityscore=1501 spamscore=0 lowpriorityscore=0 adultscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605050000 definitions=main-2605130149 On 5/13/2026 7:47 PM, Dmitry Baryshkov wrote: > On Mon, May 11, 2026 at 09:45:01PM +0530, Vishnu Reddy wrote: >> >> On 5/9/2026 2:35 AM, Dmitry Baryshkov wrote: >>> On Sat, May 09, 2026 at 12:30:01AM +0530, Vishnu Reddy wrote: >>>> On glymur platform, the iris core shares most properties with the >>>> iris core on the SM8550 platform. The major difference is that glymur >>>> integrates two codec cores (vcodec0 and vcodec1), while SM8550 has only >>>> one. Add glymur specific platform data, reusing SM8550 definitions >>>> wherever applicable. >>> This leave me in confusion. Having two cores, each with its own set of >>> clocks and pm domains, I'd have expected that each core scales >>> independently. I.e. if the load is pushed to the core0, it requires >>> core0 clocks to go higher (while core1 clocks can stay at the low freq). >>> Or, at least, the clocks would be set to the frequency corresponding to >>> the max of the workloads (if for some reason the cores should stay in >>> sync). >>> >>> However, I don't see it in the code. All clocks and all power domains >>> seem do be scaled using the common workload. If my assumptions were not >>> correct, please explain it in the commit message. >> >> The OPP core logic sets the rpmhpd level and clock rate based on the OPP table >> defined in the DT node, where the clock frequency and power rail level are >> tightly coupled together. Since vcodec0 and vcodec1 share the same power rails, >> independently scaling one clock high while keeping the other low is not >> straightforward within this OPP framework. >> >> Do you have any suggestion on how best to handle per core independent clock >> scaling within these constraints? > > This would require more plumbing and driver changes, but: > > iris: video-codec@foo { > compatible = "qcom,glymur-iris", > clocks = ; > resets = ; > > /* or core@0 */ > codec@0 { > clocks, resets, power-domains; > operating-points-v2 = <&iris_opp_table> > }; > > /* or core@1 */ > codec@1 { > clocks, resets, power-domains; > operating-points-v2 = <&iris_opp_table> > }; > > iris_opp_table: opp-table { > compatible = "operating-points-v2" > }; > }; > clock source "video_cc_mvs0_clk_src" is common for both the cores. It would not matter if core0 is scaled for a specific workload and core1 is scaled for different (let say lower), as the common PLL would always generate the higher of them. Infact, going with the approach of exclusive scaling would be an issue here. The later core scaling command would bring down/up the corner for other core, and could lead to under/over-voting. >> >>>> Reviewed-by: Vikash Garodia >>>> Signed-off-by: Vishnu Reddy >>>> --- >>>> drivers/media/platform/qcom/iris/Makefile | 1 + >>>> .../platform/qcom/iris/iris_platform_common.h | 5 ++ >>>> .../media/platform/qcom/iris/iris_platform_gen2.c | 99 ++++++++++++++++++++++ >>>> .../platform/qcom/iris/iris_platform_glymur.c | 97 +++++++++++++++++++++ >>>> .../platform/qcom/iris/iris_platform_glymur.h | 17 ++++ >>>> drivers/media/platform/qcom/iris/iris_probe.c | 4 + >>>> 6 files changed, 223 insertions(+) >>>> >