From mboxrd@z Thu Jan 1 00:00:00 1970 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 446002882D3 for ; Fri, 21 Nov 2025 07:58:17 +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=1763711898; cv=none; b=m466ecZ7IWEUCNFJouCIGUTWsr93+d+L3Hh+RLVDFazu7awWkr2Igv2F72AO+J9df3CpZNJs26dTGpj6MRwHoOsg0JWbVHBag9Gh5iWjU5cexpe6k8WgU/EofVpr8avmGuHlYWUrJHYgQ39bjJMRQqUUjH96psqUWpvfwB/wT3k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763711898; c=relaxed/simple; bh=jeDCTy5CItHZIAsH2+22GN49JOtwibzV7pQrgH2Dyvw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=DLKn+Y92I9HezUvY7GKMkwiyk+s3Vb5hrt0oSKtxtR6kXDa7cIYU5YaPGeqXsqzPZSsS9dNTflDnIy+uvUdaIrNnyr6X9SJYxfdUhr1TNdWqMCJs16ASgOdBw15lJk2bh31KtS7zo9eoPFykEUhz+/xVzsQPOzqx4bTBIx/9e10= 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=NI8T+MQL; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=MdHU8jwA; arc=none smtp.client-ip=205.220.168.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="NI8T+MQL"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="MdHU8jwA" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 5AL2gOnB2007428 for ; Fri, 21 Nov 2025 07:58:16 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= jeDCTy5CItHZIAsH2+22GN49JOtwibzV7pQrgH2Dyvw=; b=NI8T+MQLBjmm3H6x YyPqFDvaqF6uYEKuuXyFaYmBIVv7ft8DzZ+YVzf2Ska9qauCLcX5fhkdTjj2haIY IGq5RVBexvBX2b2cTc4PfYuo9kg5wbiBy6v0MuKm7nng9N893/S05C9FtYADA4sr n6lYmY9OxC4IZ5YkLB8JSeLH2UgSQnOkr3xNIsiJriX0yZn2dXwgc3L5hSj9m625 CdyAg/aeLv7Ivrol6NG6oiocWbinZ7bJpxdvG9eRKcpWpq1OyhMtvnJ+UROoW0qx ThfIGlgSFNY86hoSo7+A651TYT0nq250LS6+D9uyDv59qWAjosEUSdwV/wl1zTDU sZtTrg== Received: from mail-pg1-f199.google.com (mail-pg1-f199.google.com [209.85.215.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4ajb531era-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Fri, 21 Nov 2025 07:58:16 +0000 (GMT) Received: by mail-pg1-f199.google.com with SMTP id 41be03b00d2f7-ba265ee0e34so1604060a12.2 for ; Thu, 20 Nov 2025 23:58:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1763711896; x=1764316696; 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=jeDCTy5CItHZIAsH2+22GN49JOtwibzV7pQrgH2Dyvw=; b=MdHU8jwAMngPmjT6F7LtkooGeb90I+VW5nd1bTTRW11NbfGFudVi/GEOv6Tb3e1mEg 7N8mgUL9qMkOpfNgzlxctflxvEH7QSovn15cifsp3ZbnTWuYv9VWpnzLJ2BOFEvCeCYh N4rmMVJVk+JEBqreM2fW++aEgvSQcQAyvcbJsrIcjjnzChQF5S0MuLhBjKZAG0D70+EZ yVeL+denpibf77XHVfC2uj+BQBxWBMnelZmxuJC2lIBp8a0khJH4+k5gwN33IWXk9wTj liN6FqNCJIPQCUGPNSXPrWZqeEaPI8DCx3Hfu6xzzrDGcEB1HNwhG3Nx+U8lbdA1lT3l oPjg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763711896; x=1764316696; 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=jeDCTy5CItHZIAsH2+22GN49JOtwibzV7pQrgH2Dyvw=; b=eDV3pchdPjMtBxQFS6DB/2TJUUw8Y7yvdeNywvlQiUvYCuq0r6pQPZDyffmA6elyjR m25HEvRUIxzJ+iLnPJtZ/OoVR/Fq58tcZT2HKBwjgFhn1WRge+40ybHL0pEs/hl9kirK eV+7hnRxMz9nMD4dDxUWr2imZT216QbKmPyNonK4njSD5+CRhkl9/gdPn6pD9VijwNXs xeNVeYkVl7kQ+WvMb+BQRsM4aCspgmdzw9EUldmJobjk5lhrMS8DpL1sXh4OvSqckiat LKy2geot3U7at71FiXSmr63HIkaMggPv61wfT8pTCk2VZE5xTn56jsQP6D16X26IzuAk z00w== X-Forwarded-Encrypted: i=1; AJvYcCU0RizQH+1eCYAROeiMBarr9RjWsnIYf8dFZqKvzSLMvCpuppE0Q/II/vwiAO6+siYUdvMK3lPRGHXRdJg=@vger.kernel.org X-Gm-Message-State: AOJu0YxUv8bCbNPI3SlmK0g5wg91Wpr+UAV1cIfTC1sTLzK0Io81zTle Vx6aRl8/N2udEFLnJiGmYRrq08TmCBiZ4Vq4u7Je7uqJ9xaapmtyglqq6xgjQK/GlJ32vgwgJvS CFufrD8NvrwYgg0eDvUyrh4PBbF7XINXNDBDf5qSxJvYnykbEBtW8zf5vjzBm0iEMFUo= X-Gm-Gg: ASbGncvzGNblyh7hpdCwOTTvJfGyaSlcSmaf5Cf0EEg7kSEwz09Uj/Dus5wU4NGaRha XsLYQ9/rsYQ0fGEWZGOGfCApKcDQvjhph+TjFdOmaIKqn4WRJqgJoyZJbxA2DGIkODG6oUgQMAf YQa/SqC/BulrM2sgwRh/vrhHim/PFQ4sMAwCsBEHqmw+tpYaugIYZgd/eRtkrPpaJgQ8yrzSUwF J4FolLXcPcZGRPVoNak37HzHV2+ff2MbpBJ4LeDu+T29AetzN6EHBQOYSi6f02RhLHI04xSbfhV GWqrgLDniVyrDetI8tskFBMqHO6IpOABH3Mw9QQMwiidu6BOt+4tnCK5NA6SVrbMxZ1GOlWh0GY YRAEWHUTWMZec0uy23B68bW/eybAhfiRYQ7+v4dI= X-Received: by 2002:a05:6a21:4ed5:20b0:35d:d477:a7ea with SMTP id adf61e73a8af0-3614ecd2f67mr1636728637.19.1763711895763; Thu, 20 Nov 2025 23:58:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IFyjLtaQLBEGaZm2Ur42/KqItW/LqfnfBWEZ2bGbEg+OISKo3TJXr0ALrMMV2s5oZTTRmIS5g== X-Received: by 2002:a05:6a21:4ed5:20b0:35d:d477:a7ea with SMTP id adf61e73a8af0-3614ecd2f67mr1636692637.19.1763711895213; Thu, 20 Nov 2025 23:58:15 -0800 (PST) Received: from [10.204.78.148] ([202.46.23.25]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7c3f0b63aefsm5103018b3a.52.2025.11.20.23.58.10 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 20 Nov 2025 23:58:14 -0800 (PST) Message-ID: Date: Fri, 21 Nov 2025 13:28:09 +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 v2 1/3] arm64: dts: qcom: sdm630/660: Add CDSP-related nodes To: Nickolay Goppen , Srinivas Kandagatla , Konrad Dybcio , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht, linux@mainlining.org, Chenna Kesava Raju , Bharath Kumar References: <20251023-qcom-sdm660-cdsp-adsp-dts-v2-0-895ffe50ab5f@mainlining.org> <20251023-qcom-sdm660-cdsp-adsp-dts-v2-1-895ffe50ab5f@mainlining.org> <07066c46-4121-48da-846a-3a180d245589@oss.qualcomm.com> <47b40a91-8365-4431-9fd9-1e48fad2a4e1@mainlining.org> <83c3aea5-764e-4e60-8b16-67b474f19357@oss.qualcomm.com> <80836b8f-16a8-4520-ad11-5ca0abb3403e@oss.qualcomm.com> <99c22e73-797c-4a30-92ba-bc3bd8cf70f0@oss.qualcomm.com> <0b06f744-b695-43d9-8da3-4424e2b53a5e@oss.qualcomm.com> Content-Language: en-US From: Ekansh Gupta In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Proofpoint-GUID: cIwNXa1UKNY640y3Wz8p5S_dJ5V4OR9p X-Proofpoint-ORIG-GUID: cIwNXa1UKNY640y3Wz8p5S_dJ5V4OR9p X-Authority-Analysis: v=2.4 cv=Wugm8Nfv c=1 sm=1 tr=0 ts=69201b98 cx=c_pps a=Oh5Dbbf/trHjhBongsHeRQ==:117 a=ZePRamnt/+rB5gQjfz0u9A==:17 a=IkcTkHD0fZMA:10 a=6UeiqGixMTsA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=VwQbUJbxAAAA:8 a=NEAV23lmAAAA:8 a=OuZLqq7tAAAA:8 a=-v0Gm8E9aN-zKP_vqnUA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=_Vgx9l1VpLgwpw_dHYaR:22 a=AKGiAy9iJ-JzxKVHQNES:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUxMTIxMDA2MCBTYWx0ZWRfXw7e+MdupzEDX 1h/HZ9OwELqd6jOJt41QdtVqo1g4ijHQaG7tG39jyn+0U6lWF1U7WxVFjm8mt7uqOBvies6I7Oo TUDPurvJctXnfh3fXLrAIRi7yNx9qqusqjRiDD7LvVbekejoP2e+VjURVdABNGYWKWfQQzDpZss bruTH1KzgzEtfzj9evbPC7nGuba0QKusz4EXm0+ACghfypojIKFUyuFMSnLQlvArR9kLDe0qBgK wS3aZWFscMryCNsl5WxtS1sLOvELKFogIvNdmURG9FxFwMfzj1lU3T7Z2POpZKxADUNhNaLBAl5 EXWJhbA5My2mV+Ass4Zox64Y/dWHANf50onLWwKUVfv9UQ/JGpwruZ5rm57rdodqjX8ADFPQupN zDAUCXgGDBeu5DSr6ff+epwsVVkStA== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.9,FMLib:17.12.100.49 definitions=2025-11-21_02,2025-11-20_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 clxscore=1015 phishscore=0 bulkscore=0 adultscore=0 suspectscore=0 impostorscore=0 priorityscore=1501 malwarescore=0 lowpriorityscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2510240001 definitions=main-2511210060 On 11/20/2025 4:52 PM, Nickolay Goppen wrote: > 20.11.2025 13:54, Ekansh Gupta пишет: >> >> On 11/20/2025 1:27 PM, Nickolay Goppen wrote: >>> 20.11.2025 07:55, Ekansh Gupta пишет: >>>> On 11/20/2025 1:58 AM, Srinivas Kandagatla wrote: >>>>> On 11/12/25 1:52 PM, Konrad Dybcio wrote: >>>>>> On 11/10/25 6:41 PM, Srinivas Kandagatla wrote: >>>>>>> On 11/3/25 12:52 PM, Konrad Dybcio wrote: >>>>>>>> On 10/31/25 12:30 PM, Nickolay Goppen wrote: >>>>>>>>> 24.10.2025 16:58, Nickolay Goppen пишет: >>>>>>>>>> 24.10.2025 11:28, Konrad Dybcio пишет: >>>>>>>>>>> On 10/23/25 9:51 PM, Nickolay Goppen wrote: >>>>>>>>>>>> In order to enable CDSP support for SDM660 SoC: >>>>>>>>>>>>     * add shared memory p2p nodes for CDSP >>>>>>>>>>>>     * add CDSP-specific smmu node >>>>>>>>>>>>     * add CDSP peripheral image loader node >>>>>>>>>>>> >>>>>>>>>>>> Memory region for CDSP in SDM660 occupies the same spot as >>>>>>>>>>>> TZ buffer mem defined in sdm630.dtsi (which does not have CDSP). >>>>>>>>>>>> In sdm660.dtsi replace buffer_mem inherited from SDM630 with >>>>>>>>>>>> cdsp_region, which is also larger in size. >>>>>>>>>>>> >>>>>>>>>>>> SDM636 also doesn't have CDSP, so remove inherited from sdm660.dtsi >>>>>>>>>>>> related nodes and add buffer_mem back. >>>>>>>>>>>> >>>>>>>>>>>> Signed-off-by: Nickolay Goppen >>>>>>>>>>>> --- >>>>>>>>>>> [...] >>>>>>>>>>> >>>>>>>>>>>> +            label = "turing"; >>>>>>>>>>> "cdsp" >>>>>>>>>> Ok, I'll change this in the next revision. >>>>>>>>>>>> +            mboxes = <&apcs_glb 29>; >>>>>>>>>>>> +            qcom,remote-pid = <5>; >>>>>>>>>>>> + >>>>>>>>>>>> +            fastrpc { >>>>>>>>>>>> +                compatible = "qcom,fastrpc"; >>>>>>>>>>>> +                qcom,glink-channels = "fastrpcglink-apps-dsp"; >>>>>>>>>>>> +                label = "cdsp"; >>>>>>>>>>>> +                qcom,non-secure-domain; >>>>>>>>>>> This shouldn't matter, both a secure and a non-secure device is >>>>>>>>>>> created for CDSP >>>>>>>>>> I've added this property, because it is used in other SoC's, such as SDM845 and SM6115 for both ADSP and CDSP >>>>>>>>> Is this property not neccessary anymore? >>>>>>>> +Srini? >>>>>>> That is true, we do not require this for CDSP, as CDSP allows both >>>>>>> unsigned and signed loading, we create both secured and non-secure node >>>>>>> by default. May be we can provide that clarity in yaml bindings so that >>>>>>> it gets caught during dtb checks. >>>>>>> >>>>>>> >>>>>>> However in ADSP case, we only support singed modules, due to historical >>>>>>> reasons how this driver evolved over years, we have this flag to allow >>>>>>> compatiblity for such users. >>>>>> Does that mean that we can only load signed modules on the ADSP, but >>>>>> the driver behavior was previously such that unsigned modules were >>>>>> allowed (which was presumably fine on devboards, but not on fused >>>>>> devices)? >>>>> Yes, its true that we allowed full access to adsp device nodes when we >>>>> first started upstreaming fastrpc driver. >>>>> >>>>> irrespective of the board only signed modules are supported on the ADSP. >>>>> I think there was one version of SoC i think 8016 or some older one >>>>> which had adsp with hvx which can load unsigned modules for compute >>>>> usecase only. >>>>> >>>>> I have added @Ekansh for more clarity. >>>>> >>>>> --srini >>>> For all the available platforms, ADSP supports only signed modules. Unsigned >>>> modules(as well as signed) are supported by CDSP and GDSP subsystems. >>>> >>>> qcom,non-secure-domain property marks the corresponding DSP as non-secure DSP. >>>> The implications of adding this property would be the following: >>>> on ADSP, SDSP, MDSP: >>>> - Only non-secure device node(/dev/fastrpc-Xdsp) is created. >>>> - Non-secure device node can be used for signed DSP PD offload. >>>> >>>> on CDSP, GDSP: >>>> - Both secure(/dev/fastrpc-Xdsp-secure) and non-secure(/dev/fastrpc-Xdsp) devices >>>>     are created, regardless of this property. >>>> - Both the nodes can be used for signed and unsigned DSP PD offload. >>>> >>>> Note: If the property is not added for CDSP/GDSP, only secure device node can >>>> be used for signed PD offload, if non-secure device is used, the request gets >>>> rejected[1]. >>>> >>>> [1] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/tree/drivers/misc/fastrpc.c#n1245 >>>> >>>> //Ekansh >>> Does this mean that the qcom,non-secure-domain property should be dropped from both nodes? >> I checked again and found that unsigned module support for CDSP is >> not available on this platform. Given this, the safest approach would >> be to add the property for both ADSP and CDSP, ensuring that all >> created device nodes can be used for signed PD offload. I can provide >> a more definitive recommendation once I know the specific use cases >> you plan to run. > > It would be nice to have some testing instructions or how-to, something simple as "hello world" to be able to test it, to see if it works at all  There are some test pre-builts available here along with how-to instructions: https://github.com/qualcomm/fastrpc/tree/development/test You can try running calculator from here for basic offload testing.  > > >> //Ekansh >>>>>> Konrad >