From nobody Sat Oct 4 21:05:28 2025 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 676E929B8F5; Wed, 13 Aug 2025 03:07:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054440; cv=none; b=DiPvnVCL2DnDdWE1lZMEe7q5Nb4GPAyikmtlHXBlmQBTiGgm5vvcxCaZ008KikzS8pFyP1sekwzdXaig0pdDTbDcYhPFl0NNjnJrJwaff0ms0SYWlVTnJikMv7xNLwv6Uegui6Wap6tCd82D5Cv0XuDijtxnsHhlq4i8ZrtlZhM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054440; c=relaxed/simple; bh=xZ6pnrAP7l3v1+vSKYq9HN1IRgI25GYRYNyzJzx5EkQ=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=nLqvGkuJmiPHU4FU6ZzdJCrjBx+4dpV9xP45hyNg0PwZ6qp11zaLqwvovGcz/wzMtW8Lm7UautpASgJ1cKhwWteYFH1o4ibpqCWJRyntAm90Vg3gAZQ/8Bj7ueBvrca15MPOmO0F5ARElcdbpf+Aezx/fcmT7ALraZd2oKQ+2Tk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=VbnrGmPe; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="VbnrGmPe" Received: from pps.filterd (m0279867.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 57CJTB38012901; Wed, 13 Aug 2025 03:07:09 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= XaMEShqIo7D+kvQKbClFP1RffU0iExWhMWyy693Ho5w=; b=VbnrGmPeJzI+Zn2E UhPZAiKQFnKNfn1pwwSyOoV1qj8gt9+YDs1CbpevawvY3NYyj+HpcMwi/TZZKg4C +B72lyerWgzmv9b7zgH5CzCmpJ4TIqUY7e//O7oLgbWm4IMM/n8KDdtQMeM172B6 CZLoT6syjf3+VXskX6dgFHyuln6GiK859u5xFI/4anvGmamd2dnxU1UGA0vdqRQw H6gRufhUOAb/tNt47KPSGx6MqnEZGitBWyCi9Ckce9XJ72paRCuNR18oBpLStZFR 4JV/4c8k+tRVkOBtUOtp1XnWPJaQt/IACno42r3sNH9VUNDHKhmeInBBEJJSkb46 fxMB+Q== Received: from nasanppmta03.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 48fjxbddgb-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:09 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA03.qualcomm.com (8.18.1.2/8.18.1.2) with ESMTPS id 57D378bp027907 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:08 GMT Received: from hu-lxu5-sha.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1748.10; Tue, 12 Aug 2025 20:07:05 -0700 From: Ling Xu To: , , , , , , , , CC: , , , , , , Ling Xu , Krzysztof Kozlowski Subject: [PATCH v10 1/5] dt-bindings: misc: qcom,fastrpc: Add GDSP label Date: Wed, 13 Aug 2025 08:36:34 +0530 Message-ID: <20250813030638.1075-2-quic_lxu5@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250813030638.1075-1-quic_lxu5@quicinc.com> References: <20250813030638.1075-1-quic_lxu5@quicinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Authority-Analysis: v=2.4 cv=G6EcE8k5 c=1 sm=1 tr=0 ts=689c015d cx=c_pps a=JYp8KDb2vCoCEuGobkYCKw==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=GEpy-HfZoHoA:10 a=2OwXVqhp2XgA:10 a=KKAkSRfTAAAA:8 a=EUspDBNiAAAA:8 a=COk6AnOGAAAA:8 a=y9j2seIhk4up1NT0-iEA:9 a=cvBusfyB2V15izCimMoJ:22 a=TjNXssC_j7lpFel5tvFf:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwODExMDA5NyBTYWx0ZWRfX1VPkQhMXgJVk pgKYcTUFn32l5thbbIDZejCjeb8yBpzC7gWs5SyMPWuahWqZZcFtwssFw0WecApuNgcuqxKJ4fN hfQbO9KNi9znp3+imuWAPTtaneKBWTAGQ1WlAwIjEGEAyktK5QFLw0DDpF1BM8JkDL5TLiw7Pix bx1vGcpnxH/N9OHYeHGAZHaZJw7re+Tv7+HXNjQQL4Vygd5Xa7SeDKTEsH+MqHC4PuP+6yDsG3c 0vuBwSqbkDfN+73/KWKbSEyT24JrdszRrXDgr3GJKiGQFF5kwiU1dm6h33WvTLacT/aHS1DpD14 9bMd09jE+cNY8p5gZmLb6Ww+1ed+0anq/ojJpc+cZggeI7CzeIv9BNRdP16eJyShNKQsY8jxWZN AVJyKtUK X-Proofpoint-ORIG-GUID: EHs3ddc_jtNsomHPfZUEkko0jU6u5aNF X-Proofpoint-GUID: EHs3ddc_jtNsomHPfZUEkko0jU6u5aNF X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.1.9,FMLib:17.12.80.40 definitions=2025-08-12_08,2025-08-11_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 priorityscore=1501 bulkscore=0 spamscore=0 phishscore=0 malwarescore=0 adultscore=0 impostorscore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2507300000 definitions=main-2508110097 Content-Type: text/plain; charset="utf-8" There are some products which support GDSP remoteprocs. GDSP is General Purpose DSP where tasks can be offloaded. There are 2 GDSPs named gdsp0 and gdsp1. Add "gdsp0" and "gdsp1" as the new supported labels for GDSP fastrpc domains. Acked-by: Krzysztof Kozlowski Reviewed-by: Ekansh Gupta Signed-off-by: Ling Xu --- Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml b/Doc= umentation/devicetree/bindings/misc/qcom,fastrpc.yaml index 0840a3d92513..3f6199fc9ae6 100644 --- a/Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml +++ b/Documentation/devicetree/bindings/misc/qcom,fastrpc.yaml @@ -27,6 +27,8 @@ properties: - sdsp - cdsp - cdsp1 + - gdsp0 + - gdsp1 =20 memory-region: maxItems: 1 --=20 2.34.1 From nobody Sat Oct 4 21:05:28 2025 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 355A91E3DDB; Wed, 13 Aug 2025 03:07:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054440; cv=none; b=pVKmrwUzLsa7frWt02PIkfiTimhCT/a8HmzhxDLHvU/Mec0gRly7AhI9iV5CX4r9Wp2uq539TGtLKalVL4oQa9xFFxMZQuogch2Us3K8FnZs/iCjs/vGY+HXxaOEcLLI2k4iit2rmgcgOR+7xpuZjclI+xTBsrNVhuXcgPhbrqw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054440; c=relaxed/simple; bh=66K2J7MGXzg0fFQ8/Lr1/rjrLNcPWvLcvLnKunwziJM=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=lMET2s24XGtoDaVWokPVmTZ8DwrInlSfC9IHlfXbqbAJ0NVsXIIHHT2nwfGGuNjR6jY5ppB/v5O4spvMcJsbmvG9gGiTS5/gSbKAuweStfcxJmUf0ZhRNjfn5ueZ9sfJURdHmJFX3XvFpI/tJoCpslE73drjK3PsUKCMMh4sG0c= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=NzOS61my; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="NzOS61my" Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 57CLaSYI002367; Wed, 13 Aug 2025 03:07:14 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= K8RzXHghvzZ2GJ4f2U8gglg8QG8weQwzVPVQmwiOfmU=; b=NzOS61myEUyFd/vD FvBrsxA+6Dg/6NeljvDTBrvL3H4CnBAubalOmvYgaz7tzOBLWOAzYIs6DovZgL2i cp0ACHTdia5FVANcX8He2O35NsgUuaWNaIhb01ZmV6G0ngEgnkQfNp8mkWTiP1CH ySStzPzdZsOA19u8wfeaB+lv9UlcHxbmr+3VCAmwfuO1ULIU99lutZtwA65us7w8 uop5zKlAEXM7un2Z0hluwokS+oAKiI+S4pxojQh9WuTUQ3wSuXrnlnVaWfA6CkW/ OcpxG3GKOPvYVWsFQQHRLfSGwAVLesa3FxgjDAIbndGmjYuGcuSaIrYETEQ/pf9M o9caiQ== Received: from nasanppmta03.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 48dxj4a8k3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:14 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA03.qualcomm.com (8.18.1.2/8.18.1.2) with ESMTPS id 57D37DuE028005 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:13 GMT Received: from hu-lxu5-sha.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1748.10; Tue, 12 Aug 2025 20:07:09 -0700 From: Ling Xu To: , , , , , , , , CC: , , , , , , Ling Xu , Dmitry Baryshkov , Konrad Dybcio Subject: [PATCH v10 2/5] arm64: dts: qcom: lemans: add GDSP fastrpc-compute-cb nodes Date: Wed, 13 Aug 2025 08:36:35 +0530 Message-ID: <20250813030638.1075-3-quic_lxu5@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250813030638.1075-1-quic_lxu5@quicinc.com> References: <20250813030638.1075-1-quic_lxu5@quicinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwODA5MDAyNyBTYWx0ZWRfX/pQ5iTphjiqD pijyGRFNA9BXHMtncRRjfzj5S3H+ESRVzlyGF9hr7B1CggV2Lfyd/PInI2ajg/bg9yfAJpW0D47 17ED7Tvuvt3QJv0hnL5YL1V+Jzc2s+/oEKoz+9BemyWk3xMvv9Px9rdZC00s1nt87lZpEymS1Ci N0HyuYVw+yRhcml2rxYUI6QnHFkUelfQ7rJHKp3dNxlml+vt5U37xZOHHMpIG7f6Ch3//ckjIpe HLdXjgahnJC6e4RSlrxEgtPWHnnMl8h2vFiSwcCEGAzETxZn3Pi5lst/7R6TOlsN2KE72eHIqX3 C6dU0bpOBh52A40dnrsgop6aDHNTJBa43Upi2YltnFT2paBUsYkknGyao3bslSDzx3s/0lgo2vD N5blBm70 X-Authority-Analysis: v=2.4 cv=fvDcZE4f c=1 sm=1 tr=0 ts=689c0162 cx=c_pps a=JYp8KDb2vCoCEuGobkYCKw==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=GEpy-HfZoHoA:10 a=2OwXVqhp2XgA:10 a=EUspDBNiAAAA:8 a=COk6AnOGAAAA:8 a=CfRyy-KmkZQ3OiQjKWoA:9 a=TjNXssC_j7lpFel5tvFf:22 X-Proofpoint-ORIG-GUID: pV9vfCO7ZmLHn-jv2k-WWQgjr7gjnE0C X-Proofpoint-GUID: pV9vfCO7ZmLHn-jv2k-WWQgjr7gjnE0C X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.1.9,FMLib:17.12.80.40 definitions=2025-08-12_08,2025-08-11_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 adultscore=0 priorityscore=1501 spamscore=0 suspectscore=0 clxscore=1015 phishscore=0 bulkscore=0 impostorscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2507300000 definitions=main-2508090027 Content-Type: text/plain; charset="utf-8" Add GDSP0 and GDSP1 fastrpc compute-cb nodes for lemans SoC. Reviewed-by: Dmitry Baryshkov Reviewed-by: Konrad Dybcio Signed-off-by: Ling Xu Reviewed-by: Ekansh Gupta --- arch/arm64/boot/dts/qcom/lemans.dtsi | 58 ++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/lemans.dtsi b/arch/arm64/boot/dts/qco= m/lemans.dtsi index 322abd0294be..a4c79194cee9 100644 --- a/arch/arm64/boot/dts/qcom/lemans.dtsi +++ b/arch/arm64/boot/dts/qcom/lemans.dtsi @@ -6092,6 +6092,35 @@ IPCC_MPROC_SIGNAL_GLINK_QMP =20 label =3D "gpdsp0"; qcom,remote-pid =3D <17>; + + fastrpc { + compatible =3D "qcom,fastrpc"; + qcom,glink-channels =3D "fastrpcglink-apps-dsp"; + label =3D "gdsp0"; + #address-cells =3D <1>; + #size-cells =3D <0>; + + compute-cb@1 { + compatible =3D "qcom,fastrpc-compute-cb"; + reg =3D <1>; + iommus =3D <&apps_smmu 0x38a1 0x0>; + dma-coherent; + }; + + compute-cb@2 { + compatible =3D "qcom,fastrpc-compute-cb"; + reg =3D <2>; + iommus =3D <&apps_smmu 0x38a2 0x0>; + dma-coherent; + }; + + compute-cb@3 { + compatible =3D "qcom,fastrpc-compute-cb"; + reg =3D <3>; + iommus =3D <&apps_smmu 0x38a3 0x0>; + dma-coherent; + }; + }; }; }; =20 @@ -6135,6 +6164,35 @@ IPCC_MPROC_SIGNAL_GLINK_QMP =20 label =3D "gpdsp1"; qcom,remote-pid =3D <18>; + + fastrpc { + compatible =3D "qcom,fastrpc"; + qcom,glink-channels =3D "fastrpcglink-apps-dsp"; + label =3D "gdsp1"; + #address-cells =3D <1>; + #size-cells =3D <0>; + + compute-cb@1 { + compatible =3D "qcom,fastrpc-compute-cb"; + reg =3D <1>; + iommus =3D <&apps_smmu 0x38c1 0x0>; + dma-coherent; + }; + + compute-cb@2 { + compatible =3D "qcom,fastrpc-compute-cb"; + reg =3D <2>; + iommus =3D <&apps_smmu 0x38c2 0x0>; + dma-coherent; + }; + + compute-cb@3 { + compatible =3D "qcom,fastrpc-compute-cb"; + reg =3D <3>; + iommus =3D <&apps_smmu 0x38c3 0x0>; + dma-coherent; + }; + }; }; }; =20 --=20 2.34.1 From nobody Sat Oct 4 21:05:28 2025 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 D519629CB3C; Wed, 13 Aug 2025 03:07:25 +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=1755054447; cv=none; b=Qm9CrMiQ5nzfLCbSCUGhi3p4Moo4HK0OIjt4L55n4fPPb7zaR9TXbDRVmWcKuA79Abv1pETLf0YOqy6W+R3efgdzCCqPtqSx8RKAjh9Npx8m5Vjgrm0GiEtHamG/bdvA7IYouh2BGJgfcCmApTpibfKfZqvfhcnVViP8CGnFoxc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054447; c=relaxed/simple; bh=+DbJ8vVk3Eeo+k/16WN6hNxNCFyC6LipNDuT7pPGXgs=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=iUJz16PCLCuOT+7/lUhSfrtjYVAFQY0Ux7CYPq+mE0UQK/fAbuvHdYIkzBe2XFEHjqj4HJTI50KjfBCfBV9Kr6uyjQrzsEUuIAJfI89ad2DOof64bZztgV3gZi+ydfBljR4ifgaoNoGBqt0XNjvDZK0J/J+lP1F5onG8R1IVxjI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=mPrP5JC4; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="mPrP5JC4" Received: from pps.filterd (m0279873.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 57D01ufm029045; Wed, 13 Aug 2025 03:07:19 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= 8PEKPUTP6LKmwaWly+WXM2OUEQeeuLc9kEHmal8yQ4o=; b=mPrP5JC4Efh+/R5N xiC96o5ImJ+igRoU3RY5ooAMYxyYNYecty6E6gK3DdcQElP//GkYBwJfJkDDwmtF V0ZmHDNIuYqFvdN5sKq+g/eSWU+a28lZ5s6IYCQqTlRZXrZaGSQO1tlJEpfkMe8C 2HwG4AlWENjDuHVbWpQrNzGW+/zcKVq5Vfwl1CRafjqGQhlmd2kSNRp0c0ayV7gk 2pFkpsrm5FTa9b+va6KT0jr9fm08JbrI5ss0VyA5cfZl7+7+cKVB2z0X7WGqnPEm pJVtnFSp3lhhIvJIlrEJ5hnydq7iETI3wN8qW8EreW9chpCXhgfEmrwB2AuOUe6N deXBqw== Received: from nasanppmta02.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 48g5hma5db-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:19 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA02.qualcomm.com (8.18.1.2/8.18.1.2) with ESMTPS id 57D37ImW030266 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:18 GMT Received: from hu-lxu5-sha.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1748.10; Tue, 12 Aug 2025 20:07:14 -0700 From: Ling Xu To: , , , , , , , , CC: , , , , , , Ling Xu , Dmitry Baryshkov Subject: [PATCH v10 3/5] misc: fastrpc: Remove kernel-side domain checks from capability ioctl Date: Wed, 13 Aug 2025 08:36:36 +0530 Message-ID: <20250813030638.1075-4-quic_lxu5@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250813030638.1075-1-quic_lxu5@quicinc.com> References: <20250813030638.1075-1-quic_lxu5@quicinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwODEyMDExOSBTYWx0ZWRfX2kYzrXVFyL21 2PkD6Uq4aOOuVpjj/VULiE0yJL8KOUfr2FBSbjyHuUNsUAa4hZ4G+6l/JbIo08hVkiz+FzDzorE eVhuKR8UkrdGGarqc5no3S+YsENjHG/pol/MaNjRC0YaMeh86hQMWmRd0/7Adw7HGYLwLjOtYVr 2hoRnYV+MZYjOXJd3/wHzL4bDTIac7sRU1HwYmU6vpj6rzEUfoTimNujtNK052duPGHH6ctZ/Qd TwgrTB5Bwhh+ed8MCNQ5T6NZnITprIU5nNgFl/0HFS1J4uhQHcTDmTlRlQ/w637+x8gjdVgfYEj bYyJFk+mKS6Ql+QvRVxf/YnUU1VIJLGaLENTB9IXDVH4d1JIICyuNXIN+ukNPMD5ImoqCLyTpaM zR87Elar X-Proofpoint-GUID: tpOpRRMfQrbWGEvz0xYBcIFsUk6ZfWzH X-Proofpoint-ORIG-GUID: tpOpRRMfQrbWGEvz0xYBcIFsUk6ZfWzH X-Authority-Analysis: v=2.4 cv=d4b1yQjE c=1 sm=1 tr=0 ts=689c0167 cx=c_pps a=JYp8KDb2vCoCEuGobkYCKw==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=GEpy-HfZoHoA:10 a=2OwXVqhp2XgA:10 a=EUspDBNiAAAA:8 a=COk6AnOGAAAA:8 a=MG1_WR4Zzsb28POLZ0YA:9 a=TjNXssC_j7lpFel5tvFf:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.1.9,FMLib:17.12.80.40 definitions=2025-08-12_08,2025-08-11_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 malwarescore=0 spamscore=0 phishscore=0 adultscore=0 bulkscore=0 priorityscore=1501 impostorscore=0 suspectscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2507300000 definitions=main-2508120119 Content-Type: text/plain; charset="utf-8" Domain ID in the uAPI is misleading. Remove checks and log messages related to 'domain' field in capability structure. Update UAPI to mark the field as unused. Reviewed-by: Dmitry Baryshkov Reviewed-by: Ekansh Gupta Signed-off-by: Ling Xu --- drivers/misc/fastrpc.c | 14 +------------- include/uapi/misc/fastrpc.h | 2 +- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/drivers/misc/fastrpc.c b/drivers/misc/fastrpc.c index 53e88a1bc430..2dfcf8a66806 100644 --- a/drivers/misc/fastrpc.c +++ b/drivers/misc/fastrpc.c @@ -1723,7 +1723,6 @@ static int fastrpc_get_info_from_kernel(struct fastrp= c_ioctl_capability *cap, uint32_t attribute_id =3D cap->attribute_id; uint32_t *dsp_attributes; unsigned long flags; - uint32_t domain =3D cap->domain; int err; =20 spin_lock_irqsave(&cctx->lock, flags); @@ -1741,7 +1740,7 @@ static int fastrpc_get_info_from_kernel(struct fastrp= c_ioctl_capability *cap, err =3D fastrpc_get_info_from_dsp(fl, dsp_attributes, FASTRPC_MAX_DSP_ATT= RIBUTES); if (err =3D=3D DSP_UNSUPPORTED_API) { dev_info(&cctx->rpdev->dev, - "Warning: DSP capabilities not supported on domain: %d\n", domain); + "Warning: DSP capabilities not supported\n"); kfree(dsp_attributes); return -EOPNOTSUPP; } else if (err) { @@ -1769,17 +1768,6 @@ static int fastrpc_get_dsp_info(struct fastrpc_user = *fl, char __user *argp) return -EFAULT; =20 cap.capability =3D 0; - if (cap.domain >=3D FASTRPC_DEV_MAX) { - dev_err(&fl->cctx->rpdev->dev, "Error: Invalid domain id:%d, err:%d\n", - cap.domain, err); - return -ECHRNG; - } - - /* Fastrpc Capablities does not support modem domain */ - if (cap.domain =3D=3D MDSP_DOMAIN_ID) { - dev_err(&fl->cctx->rpdev->dev, "Error: modem not supported %d\n", err); - return -ECHRNG; - } =20 if (cap.attribute_id >=3D FASTRPC_MAX_DSP_ATTRIBUTES) { dev_err(&fl->cctx->rpdev->dev, "Error: invalid attribute: %d, err: %d\n", diff --git a/include/uapi/misc/fastrpc.h b/include/uapi/misc/fastrpc.h index f33d914d8f46..c6e2925f47e6 100644 --- a/include/uapi/misc/fastrpc.h +++ b/include/uapi/misc/fastrpc.h @@ -134,7 +134,7 @@ struct fastrpc_mem_unmap { }; =20 struct fastrpc_ioctl_capability { - __u32 domain; + __u32 unused; /* deprecated, ignored by the kernel */ __u32 attribute_id; __u32 capability; /* dsp capability */ __u32 reserved[4]; --=20 2.34.1 From nobody Sat Oct 4 21:05:28 2025 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 B41A52BD588; Wed, 13 Aug 2025 03:07:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054451; cv=none; b=WzN6tvS8Gkq5UiXPWxRLriBoT4mkaTa8nY9qu/cdOvo/RgVe+zO2cadcm63JdhiG09h2zL62TkYyIWyOOXgVHVZNNDs5hAe3siPOgs8ayHaxav3FElKhpJRS7QnKa/2FiGh4pa2nkHo7/RI2Wwpb41PYjbrj0sKWJqVTpXl5xVE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054451; c=relaxed/simple; bh=9Ofvav1/BkjETQLohGdWWSRAd5YphrxUsJmR8jI6KwE=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=t5W/Hnolt/ULACVO3yh6DdTefhTASs0GLs0JdTRFwMle4C/R4vhGqFz/DkQvnhNSvmDjnnuRHnnxaMjqtQMSqip9yQ6O07vyvb2y4Iw9DPP1zxHPtFHPZmckah9xdmhIkKFQsF0Z1U930c2HtFg/FN5qX10EUqI3yrxYedjpCZ8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=DxPZrRPd; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="DxPZrRPd" Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 57CLAlkR025489; Wed, 13 Aug 2025 03:07:23 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= XbIZ28Tv89nPPKyunuXu74eQ7U6F5KsaimB5zK3+eE8=; b=DxPZrRPdzlksA6KG KfjxM+qyGM9LnhpgBr4j/JtXTv26ZE5i/LmWW3J+M5IPzoHVczSTqaC/GJA1na3a hZbhJsdnQrVFRtl9EavrhiQm6ij56QiUq/OgaKZvUtb+Syhr3LNSbH8xME+D58eg vdKD1ST5FOUJNLpjpIObtfecjoz86p/9kktYCLFsuDIV9JP/xIjV3m9meYy/OoNo QkFxZJv9Uk4itXvSsDQ2zuwLs/cukhnurVaylF03a9wZC4/5sGxpbQXKqJ5K6coW nlGlMD7J4JqJDx3sJvn1B9/YD8Mn5MiHcAbuhNmkhgFstjr8rWvoLKRXK2g7wm3q 94/YQw== Received: from nasanppmta01.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 48dw9stena-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:23 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA01.qualcomm.com (8.18.1.2/8.18.1.2) with ESMTPS id 57D37Njj023052 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:23 GMT Received: from hu-lxu5-sha.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1748.10; Tue, 12 Aug 2025 20:07:19 -0700 From: Ling Xu To: , , , , , , , , CC: , , , , , , Ling Xu , Srinivas Kandagatla , Dmitry Baryshkov Subject: [PATCH v10 4/5] misc: fastrpc: Cleanup the domain names Date: Wed, 13 Aug 2025 08:36:37 +0530 Message-ID: <20250813030638.1075-5-quic_lxu5@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250813030638.1075-1-quic_lxu5@quicinc.com> References: <20250813030638.1075-1-quic_lxu5@quicinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Authority-Analysis: v=2.4 cv=J+Wq7BnS c=1 sm=1 tr=0 ts=689c016b cx=c_pps a=JYp8KDb2vCoCEuGobkYCKw==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=GEpy-HfZoHoA:10 a=2OwXVqhp2XgA:10 a=KKAkSRfTAAAA:8 a=EUspDBNiAAAA:8 a=COk6AnOGAAAA:8 a=1vV_c3hU4hwyYT0DQScA:9 a=cvBusfyB2V15izCimMoJ:22 a=TjNXssC_j7lpFel5tvFf:22 X-Proofpoint-ORIG-GUID: QJ7sdeTFb1i_22MjpBrrbweNOyICyqjB X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwODA5MDAxNSBTYWx0ZWRfX+C42fXRfCqJE z4oZLE60OQC3wlddtKr3uHlF/Pn6lHk3PITJsvMSoRE77Ove/1qTAQVqE8sfupp6heVNkLtehxx ku/73fhPvuZhRuWgjU2UPAV+9INl1F8i4GNpP7L7Wl3PvOHd/6S/kNY5FzouadCYOKlTbPypVav 2XWe3f+h0QPXF8WsUCpB11PqD3zHOPil6FXEuCgFovhENOJn3oZBShlW7pSsOX+AWlLtbIMfwpX mcfRNoAu7RJEa9rtDCtDeqrl+a5axlJhd5MAzlcnD2twDAfjA89SNhot7LTJlbSjR6eyEyWQiCR iQm7dexowRCwsrSLZqDkan+Cm7TIy7J0Cheihrpqr9dUwfLq3k3/576BZv6ub//qzOs5Zj8MdzY hTVxFPkX X-Proofpoint-GUID: QJ7sdeTFb1i_22MjpBrrbweNOyICyqjB X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.1.9,FMLib:17.12.80.40 definitions=2025-08-12_08,2025-08-11_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 adultscore=0 malwarescore=0 impostorscore=0 bulkscore=0 phishscore=0 suspectscore=0 spamscore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2507300000 definitions=main-2508090015 Content-Type: text/plain; charset="utf-8" Currently the domain ids are added for each instance of domains, this is totally not scalable approach. Clean this mess and create domain ids for only domains not its instances. Co-developed-by: Srinivas Kandagatla Signed-off-by: Srinivas Kandagatla Reviewed-by: Dmitry Baryshkov Reviewed-by: Ekansh Gupta Signed-off-by: Ling Xu --- drivers/misc/fastrpc.c | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/drivers/misc/fastrpc.c b/drivers/misc/fastrpc.c index 2dfcf8a66806..5fc7dec65ed8 100644 --- a/drivers/misc/fastrpc.c +++ b/drivers/misc/fastrpc.c @@ -27,8 +27,6 @@ #define MDSP_DOMAIN_ID (1) #define SDSP_DOMAIN_ID (2) #define CDSP_DOMAIN_ID (3) -#define CDSP1_DOMAIN_ID (4) -#define FASTRPC_DEV_MAX 5 /* adsp, mdsp, slpi, cdsp, cdsp1 */ #define FASTRPC_MAX_SESSIONS 14 #define FASTRPC_MAX_VMIDS 16 #define FASTRPC_ALIGN 128 @@ -106,8 +104,6 @@ =20 #define miscdev_to_fdevice(d) container_of(d, struct fastrpc_device, miscd= ev) =20 -static const char *domains[FASTRPC_DEV_MAX] =3D { "adsp", "mdsp", - "sdsp", "cdsp", "cdsp1" }; struct fastrpc_phy_page { u64 addr; /* physical address */ u64 size; /* size of contiguous region */ @@ -2243,6 +2239,20 @@ static int fastrpc_device_register(struct device *de= v, struct fastrpc_channel_ct return err; } =20 +static int fastrpc_get_domain_id(const char *domain) +{ + if (!strncmp(domain, "adsp", 4)) + return ADSP_DOMAIN_ID; + else if (!strncmp(domain, "cdsp", 4)) + return CDSP_DOMAIN_ID; + else if (!strncmp(domain, "mdsp", 4)) + return MDSP_DOMAIN_ID; + else if (!strncmp(domain, "sdsp", 4)) + return SDSP_DOMAIN_ID; + + return -EINVAL; +} + static int fastrpc_rpmsg_probe(struct rpmsg_device *rpdev) { struct device *rdev =3D &rpdev->dev; @@ -2258,15 +2268,10 @@ static int fastrpc_rpmsg_probe(struct rpmsg_device = *rpdev) return err; } =20 - for (i =3D 0; i < FASTRPC_DEV_MAX; i++) { - if (!strcmp(domains[i], domain)) { - domain_id =3D i; - break; - } - } + domain_id =3D fastrpc_get_domain_id(domain); =20 if (domain_id < 0) { - dev_info(rdev, "FastRPC Invalid Domain ID %d\n", domain_id); + dev_info(rdev, "FastRPC Domain %s not supported\n", domain); return -EINVAL; } =20 @@ -2313,21 +2318,20 @@ static int fastrpc_rpmsg_probe(struct rpmsg_device = *rpdev) case ADSP_DOMAIN_ID: case MDSP_DOMAIN_ID: case SDSP_DOMAIN_ID: - /* Unsigned PD offloading is only supported on CDSP and CDSP1 */ + /* Unsigned PD offloading is only supported on CDSP */ data->unsigned_support =3D false; - err =3D fastrpc_device_register(rdev, data, secure_dsp, domains[domain_i= d]); + err =3D fastrpc_device_register(rdev, data, secure_dsp, domain); if (err) goto err_free_data; break; case CDSP_DOMAIN_ID: - case CDSP1_DOMAIN_ID: data->unsigned_support =3D true; /* Create both device nodes so that we can allow both Signed and Unsigne= d PD */ - err =3D fastrpc_device_register(rdev, data, true, domains[domain_id]); + err =3D fastrpc_device_register(rdev, data, true, domain); if (err) goto err_free_data; =20 - err =3D fastrpc_device_register(rdev, data, false, domains[domain_id]); + err =3D fastrpc_device_register(rdev, data, false, domain); if (err) goto err_deregister_fdev; break; --=20 2.34.1 From nobody Sat Oct 4 21:05:28 2025 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 7646B2BDC0B; Wed, 13 Aug 2025 03:07:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054454; cv=none; b=OgiblNyNeCsX+cYJfN4Kc+jS0MNxDv8edsofDnfnsp5xdZc8iGiDzJqwV7/FBWCRpVKql5LM2S0wSUpyd4IMTn1Vr+OZBivOx6jYCcHASkv8QI3x7eejD6POQ9uv7cu4+qOTRE6ziJuCbSEyyDecH5kHXxiqCIKC21BJXSJOWC8= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755054454; c=relaxed/simple; bh=8Vglun/J9JxuRkbsyDVeU3zDZ2Kec2PO7uev+VxB14U=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=iiEFScY30+dFJchUrcFFePQ9Ubzx1TZQQPC0geNd8vR6XbeFiMihmhSWaOwR+C8ZV3G/b35VzepYMy7qLLdSpDeglwS0ByIhhRcLJluJ/X0hgX7zuNuf+C1LXeMhgan5N/hGbmTRREeHCObv7sGX/N04NoFjATpZTMM/eC1NB48= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=VA8EnZNh; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="VA8EnZNh" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 57CH6U9p010804; Wed, 13 Aug 2025 03:07:28 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= Mitqp2S0km2xrpzeQ4ZUDagOv4HpeKqLCHGW2C8hpsQ=; b=VA8EnZNhXmvoH+e3 ytXQgwoos+hoIDhuXKDSfgKzmqjx9I5b/pbrgMEkVrWakOQwlmhSOEXmKvrhjuMO 8DVJAu0a+ZlxH6wv8/AX8QKJ1N/Ss3oeR+fJpNh4duFuMiFIY8ldZmvTpQCJR/+T IEc77CIe+UWIUQyRvdsQopvw+RW8arcV+7PtMcl2L6mF4GaamkDj9sajuwNnGgC0 YzcrGlWS89da5hjtbtqeM1MKA8W8omAv1T83N9pScWleTp/HfvDH+OqlU088+z8T 4TBYjUIfJt7ZUyCxIcfsH9Ke6C84Wo887LuSugSPzrmTuVpdIsQLMRgxP6xb14i8 vVx4UA== Received: from nasanppmta03.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 48g9q9sakf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:28 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA03.qualcomm.com (8.18.1.2/8.18.1.2) with ESMTPS id 57D37RkF028432 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Aug 2025 03:07:27 GMT Received: from hu-lxu5-sha.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1748.10; Tue, 12 Aug 2025 20:07:24 -0700 From: Ling Xu To: , , , , , , , , CC: , , , , , , Ling Xu , Dmitry Baryshkov Subject: [PATCH v10 5/5] misc: fastrpc: add support for gdsp remoteproc Date: Wed, 13 Aug 2025 08:36:38 +0530 Message-ID: <20250813030638.1075-6-quic_lxu5@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250813030638.1075-1-quic_lxu5@quicinc.com> References: <20250813030638.1075-1-quic_lxu5@quicinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Authority-Analysis: v=2.4 cv=CNMqXQrD c=1 sm=1 tr=0 ts=689c0170 cx=c_pps a=JYp8KDb2vCoCEuGobkYCKw==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=GEpy-HfZoHoA:10 a=2OwXVqhp2XgA:10 a=EUspDBNiAAAA:8 a=COk6AnOGAAAA:8 a=VHSkhjcgKWVwXbDC_XQA:9 a=TjNXssC_j7lpFel5tvFf:22 X-Proofpoint-GUID: ILp4ZGVfUbTGNbc0tLNQJzGvB7q1-m_e X-Proofpoint-ORIG-GUID: ILp4ZGVfUbTGNbc0tLNQJzGvB7q1-m_e X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwODEyMDE2NCBTYWx0ZWRfX3r+j3c9m+cIq ofxZRw8JoMWfBJko+HHMY1OslS4C3+lxFanq2r5IWaFNajIJWSQcj6bZYk5u0EW0575DjG61OIu 3tAACHaO18nCXxRU5lAMo3VlvY5eRdMh3ajHjDDFW2T3ik0jTmjC/TvTtctzF4rMJ1esp+mQZN+ 7MbUd1Dy4/dxRqHwRv7pgm2Z13CuPmfY0UJUMitu977IfpzNyQrXEtlR3tV1KLwyJAXHV5gvZXc ufpd0UxXpB3UNavgovWP3jlAS43zqVM9GGIVVqucerlNFmh4U1WpocNMXyrzoA+tB1lVHLRXclr NA7Uoqao/9zxW5iyuP66LxX0LTuUYO0a0rGVCszaCCcR2TzENxqnX6+7VFZgOLHxVdKeN5SQHJq fxQgpqXz X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.1.9,FMLib:17.12.80.40 definitions=2025-08-12_08,2025-08-11_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 adultscore=0 phishscore=0 bulkscore=0 clxscore=1015 malwarescore=0 impostorscore=0 priorityscore=1501 suspectscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.19.0-2507300000 definitions=main-2508120164 Content-Type: text/plain; charset="utf-8" Some platforms (like lemans) feature one or more GPDSPs (General Purpose DSPs). Similar to other kinds of Hexagon DSPs, they provide a FastRPC implementation, allowing code execution in both signed and unsigned protection domains. Extend the checks to allow domain names starting with "gdsp" (possibly followed by an index). Reviewed-by: Dmitry Baryshkov Reviewed-by: Ekansh Gupta Signed-off-by: Ling Xu --- drivers/misc/fastrpc.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/misc/fastrpc.c b/drivers/misc/fastrpc.c index 5fc7dec65ed8..8e1d97873423 100644 --- a/drivers/misc/fastrpc.c +++ b/drivers/misc/fastrpc.c @@ -27,6 +27,7 @@ #define MDSP_DOMAIN_ID (1) #define SDSP_DOMAIN_ID (2) #define CDSP_DOMAIN_ID (3) +#define GDSP_DOMAIN_ID (4) #define FASTRPC_MAX_SESSIONS 14 #define FASTRPC_MAX_VMIDS 16 #define FASTRPC_ALIGN 128 @@ -2249,6 +2250,8 @@ static int fastrpc_get_domain_id(const char *domain) return MDSP_DOMAIN_ID; else if (!strncmp(domain, "sdsp", 4)) return SDSP_DOMAIN_ID; + else if (!strncmp(domain, "gdsp", 4)) + return GDSP_DOMAIN_ID; =20 return -EINVAL; } @@ -2318,13 +2321,14 @@ static int fastrpc_rpmsg_probe(struct rpmsg_device = *rpdev) case ADSP_DOMAIN_ID: case MDSP_DOMAIN_ID: case SDSP_DOMAIN_ID: - /* Unsigned PD offloading is only supported on CDSP */ + /* Unsigned PD offloading is only supported on CDSP and GDSP */ data->unsigned_support =3D false; err =3D fastrpc_device_register(rdev, data, secure_dsp, domain); if (err) goto err_free_data; break; case CDSP_DOMAIN_ID: + case GDSP_DOMAIN_ID: data->unsigned_support =3D true; /* Create both device nodes so that we can allow both Signed and Unsigne= d PD */ err =3D fastrpc_device_register(rdev, data, true, domain); --=20 2.34.1