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 EE4613D3490 for ; Wed, 25 Feb 2026 14:28:42 +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=1772029726; cv=none; b=Kl04AiKvGAAe6LsyP1JcrUAE71gqic/QX3yzLER7uE+H4IaIU7aSWGprJeBE5brCyrMWhxpu9B+Y9OsmfNThnzUreVYCG0IAsD99lb1o5BkmimGuauuu+6VokILicHn3qTN/0pBSaPt4MydI4gQBvi+GArUfbLyLIvhHtsPfGd0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772029726; c=relaxed/simple; bh=AULsyK6QnjWs4F4LCW08KjpiOXM6EU826reVsXkv+Go=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=tEl6yHjLiKS8evoLaqrQ46Kj1QfKjebKCnCVKkMPnH9VJILSU6XyzgyzP1xKvJcKNGUFdYoMsFKLhb+jiI6ySuyR2NtDUVz8/kENePXQkJVkTTnBlaruUR/lXb5Jote++01tELxLy77MGaUCDbtxDCAc02Vzcyffe6tcZWymV14= 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=KWOISrIl; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=brYC2NBQ; 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="KWOISrIl"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="brYC2NBQ" Received: from pps.filterd (m0279873.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 61PB356a788731 for ; Wed, 25 Feb 2026 14:28:42 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= zQmCtuOcHIia8KQum6i+PSa+8224BgJXHMjC5fyWebQ=; b=KWOISrIlUVSyrFWa QTRCag2nm+6GjYlPMM1upa1ZeWYHl2BqYM74aQ6cyhr4I8aVmNJGFuMv+d8ORH0S 77XGdHumt5ycaN3ZuWl5M6y6IhESbsxxeW5tmSMh2RmVVubR0uhhBNsoDsU64Ey5 tRZVaMSggTLOi3x/i+5FVf+57XV6dsC11Tdn+FyjhUYKVayEl+t90HQMYQ2wHAqk fraFIwRjHW4nBRQ/9T45cN/FWKwxcYonCf7dGp102/23LF3i7h85bwT87XWcTDmO MRRUmH+ZHk0KnSlsCi4ZmkY/AlLuEyAzlcvgIPPJc6Q0FZ3LzMaOCvyj8IrY1q+1 IjYR3A== Received: from mail-qk1-f200.google.com (mail-qk1-f200.google.com [209.85.222.200]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4chyv9ggjq-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 25 Feb 2026 14:28:41 +0000 (GMT) Received: by mail-qk1-f200.google.com with SMTP id af79cd13be357-8cb38a5dc3cso604712785a.3 for ; Wed, 25 Feb 2026 06:28:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1772029721; x=1772634521; 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=zQmCtuOcHIia8KQum6i+PSa+8224BgJXHMjC5fyWebQ=; b=brYC2NBQD74Fu8FCvgi8muF2+RxORVhFsoh5EAoomqzhaUmchyJC2fyrxDqj/RNgkP fnEr1U4OSiQEFjCkHJxXXHEWjUuLmlWmWoerMQTfHIj9ahm0DDTpmFUIALC0PT0dREyG UTC9T46WgOlLNDQrmz7K48no+Ni2SH+O5yN7uX/Q0fXbOw3Pz+yUHz9LWTR/VslNhUcD pUvB0gkf6TseUsnfiXqUx1H40et8WiZEB5xW4a5gzPyOWY9EWFf+zPTlXbN+LmxfgM9t YoQ/6Z5mw5pJzvx6SDLwXArBKj+mmfUDPSqEuNB7rmgPrF09rH6is9RIGoeJyFMT4ut2 Q4ig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772029721; x=1772634521; 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=zQmCtuOcHIia8KQum6i+PSa+8224BgJXHMjC5fyWebQ=; b=qErY30kKeV0+hXXBr4+uV6bvt8PCMoZqFanFvMJbZb5KLhki3ubogOHs42Prl7oacG u4juK8SvctwkevMTErmjDVf7gVTLrO121T/UDerTfBP3kcI24C2a22FpwlosWXw1jKUR +54T6DiEki3yZ4K9whULsXKbzKmtY0uUPpzSPiI6iHW7ojsO96f4rUfyEjyvrrJ5EYwF Hji7ShP7MyL1wms5+6Q/DniK6k6Zjy9wwXW2U2wf5IgjYFDvduoEdANEX5OkeHro5U4+ MtK28YqLqTfUfxvc3n2NHv2OGA5Ils01ZvPQWTm2rM5OKiArKXOrb3+kPrNZm9Z3dVKO 0q2w== X-Forwarded-Encrypted: i=1; AJvYcCXqdjfewaUWXjHQEqsKhdX0BV2n8FxQXrQPcBYbJLXPEeROBhFWFV6k6WU38lW+7b41AcXmkR5/4cm47Cc=@vger.kernel.org X-Gm-Message-State: AOJu0YxuwGrPDVW6RGz7gG/wRN4Qbkpuvv91brEDNtpWCZ10YStmcuiV rwSrY9AkY3QbLGTrD8jOUxFCdVP5/9gfICa016DouX0xp35zvoa81kNfDPSBV4PeDYbnmH3nOJ9 mahsJXS8YC4xCVIOSc1SOrZMrobsEnxglCvv9812wAXPelJ1dLSjjcwg9i2ET8fSPWJs= X-Gm-Gg: ATEYQzyKYWgz/Hikca9hiCrkDqQjKOVjhfFWXAvm2ai5bMdlZFhg0x4bmk6GW7aLfsy JeWSh2asNG5L9MUxMbqNFyj0tl6gGhmM2P8qq+dnOSOOsfuvwj+GzNqOAiiE2eGQhfBHBZB0kfI E/T+nK4v51RUGWmM75LrYNslHGITeL4u6oZ4F3U9ZFHWT2d4Ugtf0ckNi6zH79lNl7WjLo5qOTM Rx0s/f3fLbAGOSd7bynlNKI6EGyCx/ddqTMtzmnzZcvbwnstlpvXT9rU+tJJi9PkEOnDJ7tzMd2 wLeZbBDb7eLGcvnG/3p5GOhA25sKRYTMHLE4cwHeyJnR8PPGgJH/VD9HmqVArs4IkLva9cztgf0 /epp9XsIJYiEzK7FVV+acVCNz97+j5GMYNJO0dVcgxEHOy9ijTPExyMJTdlq8nR/OOTmuzkRXZ8 xHMjc= X-Received: by 2002:a05:620a:400d:b0:8c5:3892:a554 with SMTP id af79cd13be357-8cb8c9dffcdmr1658340585a.3.1772029721079; Wed, 25 Feb 2026 06:28:41 -0800 (PST) X-Received: by 2002:a05:620a:400d:b0:8c5:3892:a554 with SMTP id af79cd13be357-8cb8c9dffcdmr1658336885a.3.1772029720467; Wed, 25 Feb 2026 06:28:40 -0800 (PST) Received: from [192.168.119.254] (078088045245.garwolin.vectranet.pl. [78.88.45.245]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-65eab9a077asm4444053a12.4.2026.02.25.06.28.36 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 25 Feb 2026 06:28:38 -0800 (PST) Message-ID: <0b969abe-d9ce-4a87-be61-212a1b8cc8a9@oss.qualcomm.com> Date: Wed, 25 Feb 2026 15:28:36 +0100 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 07/13] soc: qcom: geni-se: Introduce helper APIs for performance control To: Praveen Talari , Andi Shyti , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Mukesh Kumar Savaliya , Viken Dadhaniya , Bjorn Andersson , Konrad Dybcio , linux-arm-msm@vger.kernel.org, linux-i2c@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, bjorn.andersson@oss.qualcomm.com, dmitry.baryshkov@oss.qualcomm.com Cc: prasad.sodagudi@oss.qualcomm.com, quic_vtanuku@quicinc.com, aniket.randive@oss.qualcomm.com, chandana.chiluveru@oss.qualcomm.com, jyothi.seerapu@oss.qualcomm.com, chiluka.harish@oss.qualcomm.com References: <20260206174112.4149893-1-praveen.talari@oss.qualcomm.com> <20260206174112.4149893-8-praveen.talari@oss.qualcomm.com> Content-Language: en-US From: Konrad Dybcio In-Reply-To: <20260206174112.4149893-8-praveen.talari@oss.qualcomm.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Proofpoint-ORIG-GUID: FBjQIHFjK5RfobJEjBmDiwCIHVWCNovz X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMjI1MDEzOCBTYWx0ZWRfXyhJUIi6ocKt5 c2S2v96Igpnpxo/jpM/1DJeKNsJYzoZfw8yHo5qH9sPgqXxyAtWl01ADi1TbYwCqSO+dHE60vuK T3K/iMfntP+690jLdiUsLpHUeelVL1KhzBh9z/tfMdUjiLtLOI5EQqE/fiRmDkh1hp+Di8r32G3 KAeCjCthvRfASue+0PuUXEJwK7eR+4m2YAcFoHogdU8++q103YJfkPFpowLuWH2UZ/bcouD/Sn2 Wt+7tJoBPbcGFnPjqi4ALhy8Ri8dea0KfhOPY3Nbl5032W05eFrRIdC51rS6Gm+AQErBTT4Rfx2 Hklv0KS/efz+nI6GuHrIfaWpywDl7+V+qlnmXkNoN9wM9yj0HcK/nmCXdaPOynZ4Dev8jKYMOEx inM37RBLNgl6lKw+N86SRPmsB67XOuA4Wq/XZ+xYKBrxtR3saV0COR3TVW7jz+gWjCd7orgRLaT G/XSg6iBWybBZIrEuSA== X-Authority-Analysis: v=2.4 cv=GZwaXAXL c=1 sm=1 tr=0 ts=699f0719 cx=c_pps a=hnmNkyzTK/kJ09Xio7VxxA==:117 a=FpWmc02/iXfjRdCD7H54yg==:17 a=IkcTkHD0fZMA:10 a=HzLeVaNsDn8A:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=rJkE3RaqiGZ5pbrm-msn:22 a=EUspDBNiAAAA:8 a=_nBXEjQIeNtNfcHD0-QA:9 a=QEXdDO2ut3YA:10 a=PEH46H7Ffwr30OY-TuGO:22 X-Proofpoint-GUID: FBjQIHFjK5RfobJEjBmDiwCIHVWCNovz X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-02-25_01,2026-02-25_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 priorityscore=1501 bulkscore=0 impostorscore=0 lowpriorityscore=0 malwarescore=0 phishscore=0 suspectscore=0 adultscore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2602130000 definitions=main-2602250138 On 2/6/26 6:41 PM, Praveen Talari wrote: > The GENI Serial Engine (SE) drivers (I2C, SPI, and SERIAL) currently > manage performance levels and operating points directly. This resulting > in code duplication across drivers. such as configuring a specific level > or find and apply an OPP based on a clock frequency. > > Introduce two new helper APIs, geni_se_set_perf_level() and > geni_se_set_perf_opp(), addresses this issue by providing a streamlined > method for the GENI Serial Engine (SE) drivers to find and set the OPP > based on the desired performance level, thereby eliminating redundancy. > > Signed-off-by: Praveen Talari > --- [...] > +/** > + * geni_se_set_perf_level() - Set performance level for GENI SE. > + * @se: Pointer to the struct geni_se instance. > + * @level: The desired performance level. > + * > + * Sets the performance level by directly calling dev_pm_opp_set_level > + * on the performance device associated with the SE. > + * > + * Return: 0 on success, or a negative error code on failure. > + */ > +int geni_se_set_perf_level(struct geni_se *se, unsigned long level) > +{ > + return dev_pm_opp_set_level(se->pd_list->pd_devs[DOMAIN_IDX_PERF], level); > +} My only remaining concern with this patch is this export - on v3 you mentioned that it'd be used in the UART driver (which currently does more or less the same thing, open-coded) - are we unable to leverage dev_pm_opp_set_rate there too? i.e. are the OPP tables produced by the SCMI servers not populating the rate field for UART specifically? Konrad