From patchwork Tue Jan 28 23:35:33 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860473 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 A705D192D76; Tue, 28 Jan 2025 23:36:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107388; cv=none; b=ZZ3j1xZExnCvbni0PxjrFxdeg+OkU13f4Uvr4ys5NzijVhtfgiGxKqU+/CDyworVpTij5h015D9IVmRVt6hZXJFAVVKB+nH6OiYPb1R5GxwB58sJF/GC633fhhaySoUYXCiliPV5Qkvy4uzP6V4DGExRNvV1pZLA+Y5gPxTdSls= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107388; c=relaxed/simple; bh=3vxlekL2NwQk9PnikoW9frxyAG29LNSo8zkvrDcJwAc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=iwQZ0Zc7XSF8oUL3Kjka0br5Y2/m7srXQTYiF+F9oVEgp6i+UvwYSw1XGaFlFgJmE8qLvau8PyAB6HNvNW7ExU7iFttBQXcVOxJEUBDR4tg1yLPn7dUGJiySDE7E+N41lnrclxglVaCUXyEpdCHc1zjexvLoq5tswwuu/NTJphg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=WbrwIg3U; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="WbrwIg3U" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107378; bh=3vxlekL2NwQk9PnikoW9frxyAG29LNSo8zkvrDcJwAc=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=WbrwIg3U3CURSYsBxjXiF3UQ7n3dfteg/3OvznJULkj//0SHZ+iVeQd9WMGVDd1JZ PJlKA6mx42mg6Kqg7IDV1B/Y+QP+h+vbCqd22MZOR77eqAe/FW38r+VNkw7sficJsF B4jWx4bnvwJHq3/c7iCcY5ACCrRBZ6UyNMNkLuQg= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:33 +0100 Subject: [PATCH v4 01/13] dt-bindings: remoteproc: qcom,msm8916-mss-pil: Support platforms with one power domain Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-1-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss , Krzysztof Kozlowski X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=2491; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=B88zuB3EiTSe4leTz3qIgobxf2MVkyWm8XcBBZJBjxw=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWnmUAzGT3lcBoCNJWgaE7uyb8LpUMaLeXKzc R2ARdTCSeSJAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp5gAKCRBy2EO4nU3X Vp1bD/sF7Oe1BDzzGwwX95BBTsFINkf/4EOYpnVnSdSVopcSmCER7n2xUB+jmtx2rmMjJXLz6hP VolcC5eGPmbXUceNIsUh26HX/o1gpwkiYKWZqDYAfJhHbnEKurO+dz7GTNrDum+V5k8yk0lHMLj DVTTbzSu1yGDxwo5PVdE8h4oUhVkt/PiTf32U5jaT0SPUIQH0RpEVrZW8kSkEvb6zRF6X6K6UMo wM4XuS29dIeKijsVh4/1j4dGaeEHVUaMbh52pu5myv8qrkc/rhUmJW2l8qCh4R50mdg5peXfaKr wKUnsBn+OshVbAk9ZgzePwgNFMUdujVFoARuWBjpoSkhC1+WI4N61WlwqWDvyr9i+3iDI39iauo DIt1NDgYrcApRLfFd6A4e2IefoCfNxsA1yZjo1+MUa/dNiDnXzNByCqipNLadPen4SbnNlXKdX+ uE9TjQEE5U4r5dUghe2Pfa/1whrQMNaDCgLOBwW1q0iWZCns9QxkOIhSSrzcoFyQ0VcYx7ZA9Rn OXud0LW7MQrGml+sblt+3IbKihfoPxtuQ1NHNq5tKgPo6GUHArec3lo9wScZ0vWwChxbqbsFBZJ t7+lIe9ZAnBEsgdC5cxkONzGl7vleZWT0k7IIaPbtmRCrD1SVc2yL5YuC0mF2YQ53K09fXzuGuw mns2t3wV01mMVGA== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD From: Matti Lehtimäki Add support for platforms such as MSM8974 which have the mx voltage rail exposed as regulator and only cx voltage rail as power domain. Signed-off-by: Matti Lehtimäki Reviewed-by: Krzysztof Kozlowski Signed-off-by: Luca Weiss --- .../bindings/remoteproc/qcom,msm8916-mss-pil.yaml | 34 +++++++++++++++++++--- 1 file changed, 30 insertions(+), 4 deletions(-) diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml index 588b010b2a9e53946a615219fc1468bc700deef8..c81364daa34b545e99261bf1f94ae2ad28d48ea7 100644 --- a/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml +++ b/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml @@ -70,16 +70,17 @@ properties: items: - description: CX proxy power domain (control handed over after startup) - description: MX proxy power domain (control handed over after startup) + (not valid for qcom,msm8974-mss-pil) - description: MSS proxy power domain (control handed over after startup) (only valid for qcom,msm8953-mss-pil) - minItems: 2 + minItems: 1 power-domain-names: items: - const: cx - - const: mx + - const: mx # not valid for qcom,msm8974-mss-pil - const: mss # only valid for qcom,msm8953-mss-pil - minItems: 2 + minItems: 1 pll-supply: description: PLL proxy supply (control handed over after startup) @@ -207,13 +208,38 @@ allOf: required: - power-domains - power-domain-names - else: + + - if: + properties: + compatible: + contains: + enum: + - qcom,msm8909-mss-pil + - qcom,msm8916-mss-pil + then: properties: power-domains: + minItems: 2 maxItems: 2 power-domain-names: + minItems: 2 maxItems: 2 + - if: + properties: + compatible: + contains: + enum: + - qcom,msm8974-mss-pil + then: + properties: + power-domains: + maxItems: 1 + power-domain-names: + maxItems: 1 + required: + - mx-supply + - if: properties: compatible: From patchwork Tue Jan 28 23:35:36 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860472 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 56532199939; Tue, 28 Jan 2025 23:36:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107388; cv=none; b=rEdeUsh7zYPEPvkNiOXso9JZcj1y2AHSFCeGr5BiMRGb2v5f5CmPSx8BNWpRXGc1w/ByDRKBzuGTKuw8c0y1YQ737GD8RWpxWWEGU8rMowzW5mhfnT5ltF/vPXtMLCA7oXvcOKFXur3JZ036hFWUfQeRrCdOXuJd3ybX2y5ZNYw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107388; c=relaxed/simple; bh=nD2pzDV8BppoM+IKRng7alJagSMAro8jZUFi3iMEfnc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=F3CaP7pbuOO8yyTuq9SIHzjCGtPIwnnu+uQ7NQsrE0Emm1QJbDeKKe59Vru/8pl5WfrO+4n9A6DvPqEuSsRgHQGSDfkvsb9HsfMlzRNdAOSiK8kzS4VeCQoZUtWpJTIpXk9NLbNxhfaWgF0os9zPsoU7+vKRAvP4zcAXR/g1FE8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=rej4FMa9; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="rej4FMa9" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107379; bh=nD2pzDV8BppoM+IKRng7alJagSMAro8jZUFi3iMEfnc=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=rej4FMa90sahffmep5gpMszv9fmw+jSgntm1M+lWhX/OOa/A1R2eqBlyIfKXTn7hn DczikGXyusOhSstt6xvAzPLOTejT8d26gl/q5J4iE5QeklQguI42vz8TYbZV/bgeBN Jyncyjtyxdpp+lXYkBz8Q8MB08ZVEs4N44EFJkqs= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:36 +0100 Subject: [PATCH v4 04/13] remoteproc: qcom_q6v5_mss: Handle platforms with one power domain Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-4-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss , Stephan Gerhold X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=2347; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=nD2pzDV8BppoM+IKRng7alJagSMAro8jZUFi3iMEfnc=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWno8meIkXHrI7bWQH3wq8YDGZ7PHCACEAYiq nbt5AkkYAiJAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp6AAKCRBy2EO4nU3X VmoWEACyQzDbFHqEtM4UkNqR/RsSfj56MEihkhtnvymIPEuAi672On0Q8hye5tzVQEsaZyyrnvJ AH69g3ypMamXrZdafbe+KFSMb/YkUsYhcl87IH+40FJzGrzy7X+2Izi30rlRuslV1/FaGb/AfGi zHpZgKFvG/WSVtDHydm/mGMS3PHHzD1g42ajCkS6+ycQgThiVSOImK76gpkRJc3vNfmuR7ftu2T Zmw3/dNEoB4MZAe0RIjnt6pAFvK5KihluOkTPIBwJlM2nU94XgRLoTxlXdy6otIvK2KikvfG/3f 3rgkMeBw9OuH14pXVb0epZ0owvMxXjpQvbewhIAfpN31YqJXu7CUoBoUYQc0cZFiwnP8ZxS13LF sRaRJithxRCeE7CbuGBGiTDMCa2LZsUVVTi496KOZz52/IvO4yqWET4z1ZbytlUwkYSHKH4xJxu rmfdG0xI+jQ8RYiO/hxv4BFHqsE22RQLIFPTCsUtKeJpxV1gHB5NlpwVGTBhRI3GUM2jNch8AmO cN3mWszB4GrKnb68iqlPko1ucNKoJxQtEySfblL/sZDU9wB67IDlDe/4pBVNU6L1Q+u+rTxlmv/ X/krtMcp/WytpEaRZ+dSMkFRdrfwHJw96QIPVPhYCL6z73ZtWD9nIblQyGAcYSDCicP+5varciZ h5Fz8l2239yU3iA== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD For example MSM8974 has mx voltage rail exposed as regulator and only cx voltage rail is exposed as power domain. This power domain (cx) is attached internally in power domain and cannot be attached in this driver. Fixes: 8750cf392394 ("remoteproc: qcom_q6v5_mss: Allow replacing regulators with power domains") Co-developed-by: Matti Lehtimäki Signed-off-by: Matti Lehtimäki Reviewed-by: Stephan Gerhold Signed-off-by: Luca Weiss --- drivers/remoteproc/qcom_q6v5_mss.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c index e78bd986dc3f256effce4470222c0a5faeea86ec..2c80d7fe39f8e308eb12e79415a551b5009b3fe4 100644 --- a/drivers/remoteproc/qcom_q6v5_mss.c +++ b/drivers/remoteproc/qcom_q6v5_mss.c @@ -1831,6 +1831,13 @@ static int q6v5_pds_attach(struct device *dev, struct device **devs, while (pd_names[num_pds]) num_pds++; + /* Handle single power domain */ + if (num_pds == 1 && dev->pm_domain) { + devs[0] = dev; + pm_runtime_enable(dev); + return 1; + } + for (i = 0; i < num_pds; i++) { devs[i] = dev_pm_domain_attach_by_name(dev, pd_names[i]); if (IS_ERR_OR_NULL(devs[i])) { @@ -1851,8 +1858,15 @@ static int q6v5_pds_attach(struct device *dev, struct device **devs, static void q6v5_pds_detach(struct q6v5 *qproc, struct device **pds, size_t pd_count) { + struct device *dev = qproc->dev; int i; + /* Handle single power domain */ + if (pd_count == 1 && dev->pm_domain) { + pm_runtime_disable(dev); + return; + } + for (i = 0; i < pd_count; i++) dev_pm_domain_detach(pds[i], false); } @@ -2449,13 +2463,13 @@ static const struct rproc_hexagon_res msm8974_mss = { .supply = "pll", .uA = 100000, }, - {} - }, - .fallback_proxy_supply = (struct qcom_mss_reg_res[]) { { .supply = "mx", .uV = 1050000, }, + {} + }, + .fallback_proxy_supply = (struct qcom_mss_reg_res[]) { { .supply = "cx", .uA = 100000, @@ -2481,7 +2495,6 @@ static const struct rproc_hexagon_res msm8974_mss = { NULL }, .proxy_pd_names = (char*[]){ - "mx", "cx", NULL }, From patchwork Tue Jan 28 23:35:37 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860470 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 B63C81F473E; Tue, 28 Jan 2025 23:36:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107392; cv=none; b=PC5DP8vB2JTS3zRN1uEDS9hfcW1HC5fThpX8f82q1wCiQ680F0UFezihUs6sabzJWZ3qH54jj2fHgYCx2oVyDmfLpK2s7C3hwKBYw1QAcZ8VzXjytexOpTo2g8NRRqubuaHGMKmvQ9hf9dBwBSlzDIm2NODtw54FYP0bHnyX2uw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107392; c=relaxed/simple; bh=WO0lvLO0J+rH/nOFep5/U1opFixrzWGFvLwItbmHAek=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=JNrVCmhAsloDEQdiNItrqjzsHkvTyK9RwmNOD40PaPpxy9l0hRaJbEF3WOS9s54IPvppka1guBLE4szRaGbH1gXH4tjmYHQP781MWbwvKFs8mBQ+X53OgXSf3aM9bKDcw3p/66eShjsLWmpa5faD16d/VgYO2QcvabhSg/hpnQs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=yx1qViwT; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="yx1qViwT" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107379; bh=WO0lvLO0J+rH/nOFep5/U1opFixrzWGFvLwItbmHAek=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=yx1qViwTXzVpsoIleU93JdH/jZuV/aLZDOZ44FfACqmHdB3bVjvkdl0kWnF1yz1PC mPxKQWQZoHwfRI7CuRPcowceurE/AkFHBXcL7gg5vS0dUifZEnkXqKPQ1BJvoKbAHw F/nX+KQ6phPNt2XDiKv8jbIosGpBiiPCb97FWayc= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:37 +0100 Subject: [PATCH v4 05/13] remoteproc: qcom_q6v5_mss: Add modem support on MSM8226 Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-5-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=8694; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=WO0lvLO0J+rH/nOFep5/U1opFixrzWGFvLwItbmHAek=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWnpfsk+S2KK9NCF3sxU9MupfW8ImgUte7Epn iZfGLTWj92JAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp6QAKCRBy2EO4nU3X VnxrD/0RmIyOlmolGqZMnfqOtJq1m+GgtHSRAxOjmtUKU+Wr5NmydSAJR1Hzz36pasNiiENwAEg Sr+JQmDeqNWnXVQFZ5iBdd3ZRpfWAWfnNLSVZBgSUt7K8x915OGr6u1U4uU/SrINIWxcsFP7KF4 uYu8fo8t7Q0fs8twR3WEDe11/wynLGGpdhPEPEnk+DGAwtJeF17H/a9s5Yx08NOVKfDhmXetoEc bjIGStyiHn8tOASrIhbNhasIih4py8mgFDkz94N6jlVSG7Fi49c2GkcYnLfAqRwkb/oDZbpHQD3 K6hPRVHchaOrVyJjh9H6REbC0YQa64P7p/FQbOAxIe1eI4aTFSvAnn7flBxMm4CCTRKKenlIbDR XzBm8NinaEinWfPHsouifeDURI3qMLLhvF1ut3ELQF+ToeV5TFKLiTmjmrpLr+ToxgpIq5r34LE YDNni3Ygsg0u6Td2YVPOo1nVl5UkKBChWp3YSo7PogmOss2vxl/Y89rGTQ6sK+bWzbpUEQ3Mqi7 TPWWzBmS9R8F5CUmBsdoRtyQKKa4s6oqK8E5dvFVoU7vj70XYyZKU+sWulfFp3MAGnu5ZkAZnCj k7xxiGOYaBJfqniy8UglwTYRyYgaZ8VOEltGD/pVDuIcQO/QBg8rA/pVPrmc3U0g4UiMxNcBG1O gWuJi6NMPghZHSg== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD Add support for the external power block headswitch register needed by MSM8226 and some other qcom platforms. Co-developed-by: Matti Lehtimäki Signed-off-by: Matti Lehtimäki Signed-off-by: Luca Weiss --- drivers/remoteproc/qcom_q6v5_mss.c | 117 ++++++++++++++++++++++++++++++++++++- 1 file changed, 116 insertions(+), 1 deletion(-) diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c index 2c80d7fe39f8e308eb12e79415a551b5009b3fe4..6f590f9128409b4aa427ab6bde1a9c4a966b3d15 100644 --- a/drivers/remoteproc/qcom_q6v5_mss.c +++ b/drivers/remoteproc/qcom_q6v5_mss.c @@ -134,6 +134,11 @@ #define BOOT_FSM_TIMEOUT 10000 #define BHS_CHECK_MAX_LOOPS 200 +/* External power block headswitch */ +#define EXTERNAL_BHS_ON BIT(0) +#define EXTERNAL_BHS_STATUS BIT(4) +#define EXTERNAL_BHS_TIMEOUT_US 50 + struct reg_info { struct regulator *reg; int uV; @@ -161,6 +166,7 @@ struct rproc_hexagon_res { bool has_mba_logs; bool has_spare_reg; bool has_qaccept_regs; + bool has_ext_bhs_reg; bool has_ext_cntl_regs; bool has_vq6; }; @@ -180,6 +186,7 @@ struct q6v5 { u32 halt_nc; u32 halt_vq6; u32 conn_box; + u32 ext_bhs; u32 qaccept_mdm; u32 qaccept_cx; @@ -237,6 +244,7 @@ struct q6v5 { bool has_mba_logs; bool has_spare_reg; bool has_qaccept_regs; + bool has_ext_bhs_reg; bool has_ext_cntl_regs; bool has_vq6; u64 mpss_perm; @@ -246,6 +254,7 @@ struct q6v5 { }; enum { + MSS_MSM8226, MSS_MSM8909, MSS_MSM8916, MSS_MSM8953, @@ -415,6 +424,34 @@ static void q6v5_pds_disable(struct q6v5 *qproc, struct device **pds, } } +static int q6v5_external_bhs_enable(struct q6v5 *qproc) +{ + u32 val; + int ret = 0; + + /* + * Enable external power block headswitch and wait for it to + * stabilize + */ + regmap_set_bits(qproc->conn_map, qproc->ext_bhs, EXTERNAL_BHS_ON); + + ret = regmap_read_poll_timeout(qproc->conn_map, qproc->ext_bhs, + val, val & EXTERNAL_BHS_STATUS, + 1, EXTERNAL_BHS_TIMEOUT_US); + + if (ret) { + dev_err(qproc->dev, "External BHS timed out\n"); + ret = -ETIMEDOUT; + } + + return ret; +} + +static void q6v5_external_bhs_disable(struct q6v5 *qproc) +{ + regmap_clear_bits(qproc->conn_map, qproc->ext_bhs, EXTERNAL_BHS_ON); +} + static int q6v5_xfer_mem_ownership(struct q6v5 *qproc, u64 *current_perm, bool local, bool remote, phys_addr_t addr, size_t size) @@ -1112,11 +1149,17 @@ static int q6v5_mba_load(struct q6v5 *qproc) goto disable_proxy_clk; } + if (qproc->has_ext_bhs_reg) { + ret = q6v5_external_bhs_enable(qproc); + if (ret < 0) + goto disable_vdd; + } + ret = q6v5_clk_enable(qproc->dev, qproc->reset_clks, qproc->reset_clk_count); if (ret) { dev_err(qproc->dev, "failed to enable reset clocks\n"); - goto disable_vdd; + goto disable_ext_bhs; } ret = q6v5_reset_deassert(qproc); @@ -1214,6 +1257,9 @@ static int q6v5_mba_load(struct q6v5 *qproc) disable_reset_clks: q6v5_clk_disable(qproc->dev, qproc->reset_clks, qproc->reset_clk_count); +disable_ext_bhs: + if (qproc->has_ext_bhs_reg) + q6v5_external_bhs_disable(qproc); disable_vdd: q6v5_regulator_disable(qproc, qproc->active_regs, qproc->active_reg_count); @@ -1281,6 +1327,8 @@ static void q6v5_mba_reclaim(struct q6v5 *qproc) qproc->reset_clk_count); q6v5_clk_disable(qproc->dev, qproc->active_clks, qproc->active_clk_count); + if (qproc->has_ext_bhs_reg) + q6v5_external_bhs_disable(qproc); q6v5_regulator_disable(qproc, qproc->active_regs, qproc->active_reg_count); @@ -1750,6 +1798,23 @@ static int q6v5_init_mem(struct q6v5 *qproc, struct platform_device *pdev) qproc->qaccept_axi = args.args[2]; } + if (qproc->has_ext_bhs_reg) { + ret = of_parse_phandle_with_fixed_args(pdev->dev.of_node, + "qcom,ext-bhs-reg", + 1, 0, &args); + if (ret < 0) { + dev_err(&pdev->dev, "failed to parse ext-bhs-reg index 0\n"); + return -EINVAL; + } + + qproc->conn_map = syscon_node_to_regmap(args.np); + of_node_put(args.np); + if (IS_ERR(qproc->conn_map)) + return PTR_ERR(qproc->conn_map); + + qproc->ext_bhs = args.args[0]; + } + if (qproc->has_ext_cntl_regs) { ret = of_parse_phandle_with_fixed_args(pdev->dev.of_node, "qcom,ext-regs", @@ -2021,6 +2086,7 @@ static int q6v5_probe(struct platform_device *pdev) platform_set_drvdata(pdev, qproc); qproc->has_qaccept_regs = desc->has_qaccept_regs; + qproc->has_ext_bhs_reg = desc->has_ext_bhs_reg; qproc->has_ext_cntl_regs = desc->has_ext_cntl_regs; qproc->has_vq6 = desc->has_vq6; qproc->has_spare_reg = desc->has_spare_reg; @@ -2174,6 +2240,7 @@ static const struct rproc_hexagon_res sc7180_mss = { .has_mba_logs = true, .has_spare_reg = true, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_SC7180, @@ -2202,6 +2269,7 @@ static const struct rproc_hexagon_res sc7280_mss = { .has_mba_logs = true, .has_spare_reg = false, .has_qaccept_regs = true, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = true, .has_vq6 = true, .version = MSS_SC7280, @@ -2233,6 +2301,7 @@ static const struct rproc_hexagon_res sdm660_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_SDM660, @@ -2268,6 +2337,7 @@ static const struct rproc_hexagon_res sdm845_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_SDM845, @@ -2299,6 +2369,7 @@ static const struct rproc_hexagon_res msm8998_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_MSM8998, @@ -2337,6 +2408,7 @@ static const struct rproc_hexagon_res msm8996_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_MSM8996, @@ -2371,6 +2443,7 @@ static const struct rproc_hexagon_res msm8909_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_MSM8909, @@ -2416,6 +2489,7 @@ static const struct rproc_hexagon_res msm8916_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_MSM8916, @@ -2451,6 +2525,7 @@ static const struct rproc_hexagon_res msm8953_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_MSM8953, @@ -2503,13 +2578,53 @@ static const struct rproc_hexagon_res msm8974_mss = { .has_mba_logs = false, .has_spare_reg = false, .has_qaccept_regs = false, + .has_ext_bhs_reg = false, .has_ext_cntl_regs = false, .has_vq6 = false, .version = MSS_MSM8974, }; +static const struct rproc_hexagon_res msm8226_mss = { + .hexagon_mba_image = "mba.b00", + .proxy_supply = (struct qcom_mss_reg_res[]) { + { + .supply = "pll", + .uA = 100000, + }, + { + .supply = "mx", + .uV = 1050000, + }, + {} + }, + .proxy_clk_names = (char*[]){ + "xo", + NULL + }, + .active_clk_names = (char*[]){ + "iface", + "bus", + "mem", + NULL + }, + .proxy_pd_names = (char*[]){ + "cx", + NULL + }, + .need_mem_protection = false, + .has_alt_reset = false, + .has_mba_logs = false, + .has_spare_reg = false, + .has_qaccept_regs = false, + .has_ext_bhs_reg = true, + .has_ext_cntl_regs = false, + .has_vq6 = false, + .version = MSS_MSM8226, +}; + static const struct of_device_id q6v5_of_match[] = { { .compatible = "qcom,q6v5-pil", .data = &msm8916_mss}, + { .compatible = "qcom,msm8226-mss-pil", .data = &msm8226_mss}, { .compatible = "qcom,msm8909-mss-pil", .data = &msm8909_mss}, { .compatible = "qcom,msm8916-mss-pil", .data = &msm8916_mss}, { .compatible = "qcom,msm8953-mss-pil", .data = &msm8953_mss}, From patchwork Tue Jan 28 23:35:40 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860471 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 ECC291F5429; Tue, 28 Jan 2025 23:36:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107391; cv=none; b=lld3mHzBOZhMK1Y4RgbCKmg9vEBcD3ZsAiOK+v776qmFViKjjY3ora198SxzYtOy2Cp1R/6NvU0Q8YhTK3k1qE27dITsDy59C6eEnJqsBIcapR578WH5p2zdi06HF+SalBgG27r9ZRtN90oKX9IkyPmzwtI85rCrmQ57xOXLkMg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107391; c=relaxed/simple; bh=c3OdZXsHQl8Hpj942CA3+f4fIQmaWKu9wILF5OxwWc8=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=qAsYm8DwcIYsVzPIW46ec8KDqMelwcRdmDZQHPYarA3ZVBApbbba+TinSrHnreNexfyMZRT4dGnzYSqnwQ+OCspkOYQVoSDAONLcVSrr01yKl0/zyB9uW2pIBZbL4MmKr43XRb4BwBG8AbsWUt0gtm1rPnJjC/zzeQju3+n2nVM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=ENEbtBnA; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="ENEbtBnA" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107380; bh=c3OdZXsHQl8Hpj942CA3+f4fIQmaWKu9wILF5OxwWc8=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=ENEbtBnApFwOyEZgl/RvRPyJnJNQXdNFJfvuxIrXiaGwCjYze2fEFygb56H3N5yrM RVUfEm+M0GIq968YR828vBUxhz4HFqxeqspqEjBogtkwfaTZnLksyOuyL/SDYA/S1f cmf4wIOurJyUMKZC44MuXfDXeAwtMRuUzwI/sbFE= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:40 +0100 Subject: [PATCH v4 08/13] ARM: dts: qcom: msm8226: Add smsm node Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-8-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss , Stephan Gerhold X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1545; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=eoHX87/Yfz6a9HStDewruF7nDlvvxRzf55C1aXv2xuE=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWnsWVmPlupV2EO7nmpGqAuHGmKlmFEnVar/Z niJlh9/DoeJAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp7AAKCRBy2EO4nU3X Vm0oD/4wpnmCr3tOS8kkxeS3mZDg/GSkaXEDtBbe14BnBk8QV6+VJ5joQIg1ysWUd1UkjqnUnfB zAOFf78xCD8vJcppbPci4AeMOc7q2duxRyZgEqOCOcsGvTDkjqkixMBZ4XmywJgJnH49T1+N4Vj ZbbPd6hrnLUzsG0yz+tnF2fTCpiVCl9k9tIpc1dOlxs5pIqxvU261NyVyIqe+4JiVy5xC9CA4Xn 5dzp/+JQqte4nH5W2A+Di59r/TZjRfvHc45Vl+IZ+to9gCq8GsLO0BmVv2fyMSKFatzS5KpjY1S +ok2E8BIFSWjfigMlq1LIV9kQiClVObdNKu9hqsK19+FKrNZh3hkgCtLI09ZrNxbUPoQ3L6Efvv 2e//tSTPAgrsBp8fXtbTGijXT8cpqKQIKHtdb3s6HjHimwbK/jqla3Mobi+ku6cWWsZUvJGcn++ 6y0LuU1oXu535dO1n2M2PPZ6EBPOIRwIWutz2l4MKwSGvomTLCstpOLSFc6ULZOlzV8uginogzQ +PGtZpTbwkBTesICRpRSlaIjNuJKG42dHylt+rG1tOgRI+7KiOAQFjiUbfW4/35oWMLm/554zFZ 0RffCOrGhKybP7RIIvCFY4XIin8Vsuvo39LcO2c2xvE2sBjimd6vqbAarSklq15/AmkkPWlb6Cx lrX5zHN6ziVBXEw== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD From: Matti Lehtimäki Add smsm node for remoteproc cores. Reviewed-by: Stephan Gerhold Signed-off-by: Matti Lehtimäki Co-developed-by: Luca Weiss Signed-off-by: Luca Weiss --- arch/arm/boot/dts/qcom/qcom-msm8226.dtsi | 34 ++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi index caaeeadf289f78d29403312738bbb714eaad74d2..7e0838af6c2d0dc26e0082471b70578bc627491d 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi +++ b/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi @@ -253,6 +253,40 @@ adsp_smp2p_in: slave-kernel { }; }; + smsm { + compatible = "qcom,smsm"; + #address-cells = <1>; + #size-cells = <0>; + + mboxes = <0>, <&apcs 13>, <&apcs 9>, <&apcs 19>; + + apps_smsm: apps@0 { + reg = <0>; + #qcom,smem-state-cells = <1>; + }; + + modem_smsm: modem@1 { + reg = <1>; + interrupts = ; + interrupt-controller; + #interrupt-cells = <2>; + }; + + adsp_smsm: adsp@2 { + reg = <2>; + interrupts = ; + interrupt-controller; + #interrupt-cells = <2>; + }; + + wcnss_smsm: wcnss@7 { + reg = <7>; + interrupts = ; + interrupt-controller; + #interrupt-cells = <2>; + }; + }; + soc: soc { compatible = "simple-bus"; #address-cells = <1>; From patchwork Tue Jan 28 23:35:41 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860468 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 B3BD11F5618; Tue, 28 Jan 2025 23:36:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107393; cv=none; b=G7M1ZSZjDLNDGkTW+3SD39Ec7ZtcXuzWDRlkj+alFXLPuBt5bfayVO1Hspr2QZbeqUuP2DED8VRBWtXBM6MZHTqn9Rwf9ew2O5SqUVyNu0T0atfkLs9Fgon5lFN8amiloUKAp+KD6KdsLUa7X+akgjkNaLq24LAkCAApF9/VNWM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107393; c=relaxed/simple; bh=Xc7uOFazuo8Cvw0LUVcDkOhpsZEdc66R9DmSNN/w4Mw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=BYDQsjmbpMZnerQVBA9X0l5sPC/OojXqeRAth1tdT6VZhn99k9ak0z/Wxw14dztgsXebMasm4vYdpru7RxaH1/bI0KSi35dJav1KeW1OgXI5HP91IDKtZD2w9aljUsA+9IIPPbbabdKfNPSVsR9V7aHefhzfCr5hYZ/Vat/GNTQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=0q38oJ2Y; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="0q38oJ2Y" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107380; bh=Xc7uOFazuo8Cvw0LUVcDkOhpsZEdc66R9DmSNN/w4Mw=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=0q38oJ2YH96awGSqB7PH3p0FivVjbh5eNEsG1SQLg/amOoGJx6go1SUPHmMFAnw5N IdmMnVGe8oJ65hU6uCQ7RgtWqawrydgc/Q2QMQCZpzvIng0LjdFHx9qZFRJ/lMTkJC /k4M1KwaiPDVjRPcflawFT2Fdhvsq4lw3oZ4i3m0= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:41 +0100 Subject: [PATCH v4 09/13] ARM: dts: qcom: msm8226: Add modem remoteproc node Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-9-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss , Stephan Gerhold X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=5369; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=Xc7uOFazuo8Cvw0LUVcDkOhpsZEdc66R9DmSNN/w4Mw=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWntZE5aPniqgs+uBFt5iXC9TU2ij8KyOLrI+ SJQeU/M82SJAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp7QAKCRBy2EO4nU3X VoaID/9bO/jq5cQGQ+jY8iuumlRmjq/PFyRQY7lsfPHbAVPIt1Ibk/y2GMZJsb+mUsXr5AGdV7p yIoawTzcgzvBnbUq2/wWviUCYG53EkCNRuYMGdFlG3MhOqNjfXr1+GpMZk7ucauvOfrNCHSqyOb E4ikpUhPLMoDB+SnhJ6HglU9cP+3TQ5O4IZOJcezcsN3AafjnXOnyOylWbNU6QHSvutEVvu1+vh Ae/1SYiFt1vDhWF7/aob6E3iKOLOszGNCxcx753sxau7DHX9d1OboVsbXhXTQfX0RfcX4t2cIQM t1+1YZk8T6LJnQQLmxnaqz4uzs9BZUUi90eBr0IWSna0QY/n3C4XIM8qtyjonZgURIc+FnSqh4M Ks7UCBZtzYi73cA/JsGKCQRKjHFwyExo9LuaS0kdRgMibENfn1Y6JrMbIg8JnsQQdBbmgy41Kqg b/DehrWB0Hol+c6+XpJ6cT8oPuGS5STjry8+a7/1B8E8oztiguDtjd8rvDs3kA1jFNFOPz9uqGG wi2bKuyTk70I4T3RYtUcJ/j6/0bZHUv6cNDcefRMnbzBoGD7t8VOcHE9xi6DR2HyDCCiuEqCWhk 7bAymsnO8lD3apMSqnzz22Dvfg9V3aJY/Udm2eOBzZgLDyO1cLLzG6GaIWc2QPX5SvRZWH7fJzo qXCS/mhJHk7bwsw== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD Add a node for the modem remoteproc found on MSM8226. Co-developed-by: Matti Lehtimäki Signed-off-by: Matti Lehtimäki Reviewed-by: Stephan Gerhold Signed-off-by: Luca Weiss --- .../dts/qcom/qcom-apq8026-samsung-milletwifi.dts | 2 + .../qcom/qcom-msm8226-samsung-matisse-common.dtsi | 6 +- arch/arm/boot/dts/qcom/qcom-msm8226.dtsi | 82 ++++++++++++++++++++++ arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts | 2 + 4 files changed, 90 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-milletwifi.dts b/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-milletwifi.dts index 7d519156d91d156d801c477711751aba66cc3224..a8543ca7b5569549418683b6be320784eba1768c 100644 --- a/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-milletwifi.dts +++ b/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-milletwifi.dts @@ -12,6 +12,8 @@ #include "pm8226.dtsi" /delete-node/ &adsp_region; +/delete-node/ &mba_region; +/delete-node/ &mpss_region; /delete-node/ &smem_region; / { diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi index a15a44fc0181bf23e7531ecdc8978505ca48189d..fbd568c7d6b7415d240aa1a2329d07cf9135274c 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi +++ b/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi @@ -8,6 +8,8 @@ #include "pm8226.dtsi" /delete-node/ &adsp_region; +/delete-node/ &mba_region; +/delete-node/ &mpss_region; /delete-node/ &smem_region; / { @@ -145,12 +147,12 @@ framebuffer@3200000 { no-map; }; - mpss@8400000 { + mpss_region: mpss@8400000 { reg = <0x08400000 0x1f00000>; no-map; }; - mba@a300000 { + mba_region: mba@a300000 { reg = <0x0a300000 0x100000>; no-map; }; diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi index 7e0838af6c2d0dc26e0082471b70578bc627491d..55bb070dcf489064f5b14902da1acd2762232ef9 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi +++ b/arch/arm/boot/dts/qcom/qcom-msm8226.dtsi @@ -213,6 +213,18 @@ smem_region: smem@3000000 { no-map; }; + mpss_region: mpss@8000000 { + reg = <0x08000000 0x5100000>; + no-map; + status = "disabled"; + }; + + mba_region: mba@d100000 { + reg = <0x0d100000 0x100000>; + no-map; + status = "disabled"; + }; + adsp_region: adsp@dc00000 { reg = <0x0dc00000 0x1900000>; no-map; @@ -253,6 +265,31 @@ adsp_smp2p_in: slave-kernel { }; }; + smp2p-modem { + compatible = "qcom,smp2p"; + qcom,smem = <435>, <428>; + + interrupt-parent = <&intc>; + interrupts = ; + + mboxes = <&apcs 14>; + + qcom,local-pid = <0>; + qcom,remote-pid = <1>; + + modem_smp2p_out: master-kernel { + qcom,entry-name = "master-kernel"; + #qcom,smem-state-cells = <1>; + }; + + modem_smp2p_in: slave-kernel { + qcom,entry-name = "slave-kernel"; + + interrupt-controller; + #interrupt-cells = <2>; + }; + }; + smsm { compatible = "qcom,smsm"; #address-cells = <1>; @@ -879,6 +916,51 @@ spmi_bus: spmi@fc4cf000 { #interrupt-cells = <4>; }; + modem: remoteproc@fc880000 { + compatible = "qcom,msm8226-mss-pil"; + reg = <0xfc880000 0x100>, + <0xfc820000 0x020>; + reg-names = "qdsp6", "rmb"; + + interrupts-extended = <&intc GIC_SPI 24 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 0 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 1 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 2 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 3 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack"; + + clocks = <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>, + <&gcc GCC_MSS_CFG_AHB_CLK>, + <&gcc GCC_BOOT_ROM_AHB_CLK>, + <&xo_board>; + clock-names = "iface", "bus", "mem", "xo"; + + resets = <&gcc GCC_MSS_RESTART>; + reset-names = "mss_restart"; + + power-domains = <&rpmpd MSM8226_VDDCX>; + power-domain-names = "cx"; + + qcom,ext-bhs-reg = <&tcsr_regs_1 0x194>; + qcom,halt-regs = <&tcsr_regs_1 0x180 0x200 0x280>; + + qcom,smem-states = <&modem_smp2p_out 0>; + qcom,smem-state-names = "stop"; + + memory-region = <&mba_region>, <&mpss_region>; + + status = "disabled"; + + smd-edge { + interrupts = ; + + mboxes = <&apcs 12>; + qcom,smd-edge = <0>; + + label = "modem"; + }; + }; + tcsr_mutex: hwlock@fd484000 { compatible = "qcom,msm8226-tcsr-mutex", "qcom,tcsr-mutex"; reg = <0xfd484000 0x1000>; diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts index 3037344eb24055071cc77c9cfce0f1d0f95de921..18396623a91dd4bf4b66f01c1d983c391722f3b5 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts @@ -9,6 +9,8 @@ #include "pm8226.dtsi" /delete-node/ &adsp_region; +/delete-node/ &mba_region; +/delete-node/ &mpss_region; /delete-node/ &smem_region; / { From patchwork Tue Jan 28 23:35:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860467 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 B3C6E1F561F; Tue, 28 Jan 2025 23:36:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107394; cv=none; b=bURhsUZAo/F9DD2+3zhSBgnLKQiSVtKSFzwd3Bo4FdrBe4WWwyI8zUW+rgK5JAzyihnIBSpJS0TbukQxp1oY3xv8wzT4FvwyzPzmHIsS39H/+BGZZMR9PcYt5NTtca/Pt0SILHtkTOiKDhka5k15CMwJJ3R7cMk+0yitAhjN+yI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107394; c=relaxed/simple; bh=jMq6Fhv262rdqErsWSNESQcM/fy7CRUg0JBtOSajj1Y=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ErIL2ksDuNFkAwJk7i/52x6MXJnsKCLbSmNHf0WH3mvLwvm8+ZWMjsM8LOt+HpRPurjMqiib0RL6j4FCvoGPL/D/KIDCAs8AadnUkAv/TSp/jebavLfF4f4HuaWu60VFufIlyMw73iYWfHEb11yTTogU3lIyKnY+HReOAepfdrc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=TxcGZFTi; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="TxcGZFTi" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107381; bh=jMq6Fhv262rdqErsWSNESQcM/fy7CRUg0JBtOSajj1Y=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=TxcGZFTi/yryCohxj66Sl/9b9t+AHny6yymoHzaysUTn2GsH0T3bktJ+dQi0r52cI h6PiTHbyzbrR7B0iOZb3+GZXda5EkqsI+TN6kMY9/NFc87vrOSPXJ84dnmZtKuyHVS bxNcWsea5H4Ccq50QdP2MWdcDgpr7YddbbfFmBJY= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:43 +0100 Subject: [PATCH v4 11/13] ARM: dts: qcom: Introduce dtsi for LTE-capable MSM8926 Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-11-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss , Stephan Gerhold , Konrad Dybcio X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=8009; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=jMq6Fhv262rdqErsWSNESQcM/fy7CRUg0JBtOSajj1Y=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWnvLPh6B7hTcNNR3EHPGELNdHMWjPczqQraQ bHyJbNwN+mJAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp7wAKCRBy2EO4nU3X VsZREACn6ybDMEGJTqNJdRfYQuIsouVdmxhCbDvFeoGxfgMaNiZRYV1HKebcL5+FPmbS1xL17Ln 7a5Wgdil2tn70Mgs67U2bkLbYJo0YyIsGcLjoKs5n40cm0GxoRjvI9FSlHKewI0NztQk3x/zXBK BIjgueBaDmShIcGBOUKgDE/2eTu90FgLjMJE74Tr4CXBboPS7nc6+qVZ3bylKWzrEitQR1v6gJZ Uz+2WnuIkdY0CjcYNJ3DHd9gcfkZp8VfSBoLzGD3OvbQSdCOf90dXWfVUuYMFj784V26or46XWl BOAx8nvzArPWeSZFRuJT5NsCAaZnx37B7fsNRdC2BfGZjfCIrE1mVsKksCD56p4r3YGLQ9V9d+e 8F53I+L9gnMLzyzZkKSzPbFMipzwxVr+R2oy9dmMZKMfF7EZS01x/WPCzQ62/KI1j+xSbwjORAn 4Z2QTkmCoMN42K3LGUAv2WDHcFhFNLJ5VexasFpBGdqUXlGHBvid8Cv8+4hoE5pUG0zOqrZy7yn bdsOnP6LH4wla/RHxn2Spo4T6Q8ktYK066ywCf2DeJqTAObEuni9eVD4pVaENf8F6nkemJVciiK LKNe6pe1Ox7v/RvwZAuamFwlqBkWkHFjodhSPlqS2oapeAeYh4oJjtJwP6FEB/u4prYrN6UQHqQ 3fsA/+JAc5ZIYyw== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD MSM8926, while being 'just' an LTE-capable variant of MSM8226, the dts needs to slightly change since the modem doesn't use the ext-bhs-reg and needs mss-supply, therefore it gets a new compatible. Since we already have two -common.dtsi files which are used on both APQ8026/MSM8226 and MSM8926 devices, change the setup a bit by removing the SoC include from those and requiring the device dts to pick the correct one. Reviewed-by: Stephan Gerhold Reviewed-by: Konrad Dybcio Signed-off-by: Luca Weiss --- arch/arm/boot/dts/qcom/msm8926.dtsi | 11 +++++++++++ arch/arm/boot/dts/qcom/qcom-apq8026-samsung-matisse-wifi.dts | 1 + arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-common.dtsi | 6 +++++- arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-dempsey.dts | 1 + arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-makepeace.dts | 1 + arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-moneypenny.dts | 1 + .../boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi | 6 +++++- arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts | 2 +- .../arm/boot/dts/qcom/qcom-msm8926-microsoft-superman-lte.dts | 1 + arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-tesla.dts | 1 + arch/arm/boot/dts/qcom/qcom-msm8926-motorola-peregrine.dts | 2 +- arch/arm/boot/dts/qcom/qcom-msm8926-samsung-matisselte.dts | 1 + 12 files changed, 30 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/qcom/msm8926.dtsi b/arch/arm/boot/dts/qcom/msm8926.dtsi new file mode 100644 index 0000000000000000000000000000000000000000..629654c525b4bf415e41dca7b3d9fc60a5ee75fd --- /dev/null +++ b/arch/arm/boot/dts/qcom/msm8926.dtsi @@ -0,0 +1,11 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2025, Luca Weiss + */ + +#include "qcom-msm8226.dtsi" + +&modem { + compatible = "qcom,msm8926-mss-pil"; + /delete-property/ qcom,ext-bhs-reg; +}; diff --git a/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-matisse-wifi.dts b/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-matisse-wifi.dts index da3be658e822fb6408738e7e79453b87c39478e1..4546fa8beba46d31345da1ee3eded20e8a853f6b 100644 --- a/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-matisse-wifi.dts +++ b/arch/arm/boot/dts/qcom/qcom-apq8026-samsung-matisse-wifi.dts @@ -5,6 +5,7 @@ /dts-v1/; +#include "qcom-msm8226.dtsi" #include "qcom-msm8226-samsung-matisse-common.dtsi" / { diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-common.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-common.dtsi index ca76bf8af75e463bc3a2a5cfc1c2b574f0ac17f5..d4a32af0ef8f1ca6c0926261d7756a4d6bfba23f 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-common.dtsi +++ b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-common.dtsi @@ -8,7 +8,11 @@ * Copyright (c) 2023, Rayyan Ansari */ -#include "qcom-msm8226.dtsi" +/* + * The .dts should first include qcom-msm8226.dtsi or msm8926.dtsi depending on + * the SoC on the given device. + */ + #include "pm8226.dtsi" #include diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-dempsey.dts b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-dempsey.dts index 2c664b5934ec54b7d53a2e3a8d86a1df864d33a9..f448c908841610bc53cccccb431d5ce50d205fc1 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-dempsey.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-dempsey.dts @@ -8,6 +8,7 @@ /dts-v1/; +#include "qcom-msm8226.dtsi" #include "qcom-msm8226-microsoft-common.dtsi" / { diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-makepeace.dts b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-makepeace.dts index 731c5c3756784677580f09fad31ba28b0533145d..94bf3b1ad1bd1fb926ac5bb7174394965d52609c 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-makepeace.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-makepeace.dts @@ -8,6 +8,7 @@ /dts-v1/; +#include "qcom-msm8226.dtsi" #include "qcom-msm8226-microsoft-common.dtsi" / { diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-moneypenny.dts b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-moneypenny.dts index a28a83cb534055a36a55f907094b34f48b6266be..d8cdb75dfbb8bdafd8bb8fecfe3b9ab3f42b41e4 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-moneypenny.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8226-microsoft-moneypenny.dts @@ -8,6 +8,7 @@ /dts-v1/; +#include "qcom-msm8226.dtsi" #include "qcom-msm8226-microsoft-common.dtsi" /* This device has no magnetometer */ diff --git a/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi b/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi index fbd568c7d6b7415d240aa1a2329d07cf9135274c..0a3147656f36ca2616e0e3cc7c1dd808b55f3a88 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi +++ b/arch/arm/boot/dts/qcom/qcom-msm8226-samsung-matisse-common.dtsi @@ -3,8 +3,12 @@ * Copyright (c) 2022, Matti Lehtimäki */ +/* + * The .dts should first include qcom-msm8226.dtsi or msm8926.dtsi depending on + * the SoC on the given device. + */ + #include -#include "qcom-msm8226.dtsi" #include "pm8226.dtsi" /delete-node/ &adsp_region; diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts index 18396623a91dd4bf4b66f01c1d983c391722f3b5..d6eaa82cee4daf6a1386902f537f1351811d4a06 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts @@ -5,7 +5,7 @@ /dts-v1/; -#include "qcom-msm8226.dtsi" +#include "msm8926.dtsi" #include "pm8226.dtsi" /delete-node/ &adsp_region; diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-superman-lte.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-superman-lte.dts index 9b48661d69c53829c30ece8544ffff97f3032a59..eea4fd8cd9725f1ef629aae446ff7aa6c49fb2fa 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-superman-lte.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-superman-lte.dts @@ -8,6 +8,7 @@ /dts-v1/; +#include "msm8926.dtsi" #include "qcom-msm8226-microsoft-common.dtsi" /* This device has touchscreen on i2c3 instead */ diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-tesla.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-tesla.dts index 55077a5f2e34f84857ee35d22157362759151c5a..f23bbb94cc5e4343f667e53d66bc289228a85134 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-tesla.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-microsoft-tesla.dts @@ -8,6 +8,7 @@ /dts-v1/; +#include "msm8926.dtsi" #include "qcom-msm8226-microsoft-common.dtsi" /* This device has touchscreen on i2c1 instead */ diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-motorola-peregrine.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-motorola-peregrine.dts index 376a33125941028a3977e76373ee96959b08ee3e..db3273c755c2b5480b9c00336314b63900a74cbd 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-motorola-peregrine.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-motorola-peregrine.dts @@ -2,7 +2,7 @@ /dts-v1/; -#include "qcom-msm8226.dtsi" +#include "msm8926.dtsi" #include "pm8226.dtsi" /delete-node/ &smem_region; diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-samsung-matisselte.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-samsung-matisselte.dts index d0e1bc39f8ef700aa648148ac070f59062d049d7..772827cad972ad4ff032cfb9310568c5d2f0170f 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-samsung-matisselte.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-samsung-matisselte.dts @@ -6,6 +6,7 @@ /dts-v1/; +#include "msm8926.dtsi" #include "qcom-msm8226-samsung-matisse-common.dtsi" / { From patchwork Tue Jan 28 23:35:44 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luca Weiss X-Patchwork-Id: 860469 Received: from ahti.lucaweiss.eu (ahti.lucaweiss.eu [128.199.32.197]) (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 7C6841F5608; Tue, 28 Jan 2025 23:36:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=128.199.32.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107392; cv=none; b=HnEwjWbzg+RTnPESQqEQPSeBej/90TaiXpDW2FqqL00bXIy4Tqr2Zn74otI1K1larpr2DZgljCd911EKKjx6c/3Qpa7BRkwXJlKaDaC5QnbDt9bcChlKp/CDoB3aMB/r0q8WHgvT0hVqh54RGMtv0x7F41N4cQjElwRoWkA7he4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1738107392; c=relaxed/simple; bh=DLjfEGxFWMNPCYEaP5OzjsuwOiEesmoVFxG+cMzU00A=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Gy+/2CJd57BGJ7zpr5A/lJMry7mp6ECEHS8NA/hakOvOYSPCteU6I/oJDn1Yng/+IZ+XwK5V8QQJeW6getpdMeuNplZOgs+UKi8BGTixlQeGB6pyF+7nfmuGasT88GlM+fGZn3dUwSfhA1DoCtRYiSEsoDqcBwDvfx9SN2A5WLg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu; spf=pass smtp.mailfrom=lucaweiss.eu; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b=vrxSjhZt; arc=none smtp.client-ip=128.199.32.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lucaweiss.eu Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lucaweiss.eu header.i=@lucaweiss.eu header.b="vrxSjhZt" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=lucaweiss.eu; s=s1; t=1738107381; bh=DLjfEGxFWMNPCYEaP5OzjsuwOiEesmoVFxG+cMzU00A=; h=From:Date:Subject:References:In-Reply-To:To:Cc; b=vrxSjhZtEvM97mqDOsXs4Lvio/jBPiwgbWQRbf5//mrYCXNCVuR6z8mw/7KBl7swD HXcRiVT9jupSYY+aNKa7zN1RbrixmUW+LueMOJ8rmMB5dqPK4zx9mTpEh3qm4f0kvy 46UYc1pnDBadJKZ1RY4YglOrk8ym27EEMLLr25OQ= From: Luca Weiss Date: Wed, 29 Jan 2025 00:35:44 +0100 Subject: [PATCH v4 12/13] ARM: dts: qcom: msm8926-htc-memul: Enable modem Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20250129-msm8226-modem-v4-12-2b02ed7b7f1c@lucaweiss.eu> References: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> In-Reply-To: <20250129-msm8226-modem-v4-0-2b02ed7b7f1c@lucaweiss.eu> To: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Bjorn Andersson , Mathieu Poirier , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Konrad Dybcio , =?utf-8?q?Matti_Lehtim=C3=A4ki?= Cc: linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Weiss , Stephan Gerhold X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=950; i=luca@lucaweiss.eu; h=from:subject:message-id; bh=DLjfEGxFWMNPCYEaP5OzjsuwOiEesmoVFxG+cMzU00A=; b=owEBbQKS/ZANAwAIAXLYQ7idTddWAcsmYgBnmWnw7OClG5N8dfAM31fXMNFFPsX4F6QNcswVt 4ZyQpqp9K+JAjMEAAEIAB0WIQQ5utIvCCzakboVj/py2EO4nU3XVgUCZ5lp8AAKCRBy2EO4nU3X Vhh4D/92gXPvTLaSOPUE0rX6W5pDk0TCocJnSsKajBSiOM2cGT+3D3Hizs7UTDFsgC2DmQGcqbF VLzbKS7eK4jzURgvRe60N/1wZo7XEOP2iGtGOKT20oQqF91FbyikCl12tVDiWHIlHIEsd06BY46 j1Xlh3lrnAxhImQ93j+taclUs+LMX1+AoOwy5KeIHKula8prIghrgMnRRlRqAFXvOE+ZEcHgPtT 21PMqx60D85N+m+1PGChNbzXWIEB8aUKgjGhYQ5lUqPkCWXLr0KihPVtV77qEeOQjZCpfZnIoy1 9opQkjooD6uiXa1KYcghz/d2S3G2c9Ee7Y4VYC1x3jo+kOwW6jMyDtazwR433+Jk2rUFI3BOZTG RVb/xJFFQuoCMexxjP1XdZSkG3rC6NRNX9RYAK7P4LqfA+f7roomvhT7jOQa/uNP0jvPajwwnQk 4mnb9IjPH0g5exqyw5AY0nVUhB4jEsdjsmwB/KWYUOXWr1pysBswVCfCNATzl9AgXYRmev4GY82 ozTLoD1xOSoHEjveSVhbtfKXrkEW0SU+rF161632DOYZ9WbAv3h3R5YIO0sbNuk2XNz+YXLKMON ujRHURUIL6onYxdfCfdps9I57hK+SAQGVqD1zdLG9d8J5UrrM7m/a5IyQGgHp/VAgXGqk/8llIf MLj+83JHnBpHrxg== X-Developer-Key: i=luca@lucaweiss.eu; a=openpgp; fpr=BD04DA24C971B8D587B2B8D7FAF69CF6CD2D02CD Enable the modem found on the MSM8926 HTC One Mini 2. Reviewed-by: Stephan Gerhold Signed-off-by: Luca Weiss --- arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts b/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts index d6eaa82cee4daf6a1386902f537f1351811d4a06..cb571aa13c11598182dc020f064fe8268bcc061f 100644 --- a/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts +++ b/arch/arm/boot/dts/qcom/qcom-msm8926-htc-memul.dts @@ -195,6 +195,16 @@ &blsp1_i2c6 { /* TPS61310 Flash/Torch @ 33 */ }; +&modem { + mx-supply = <&pm8226_l3>; + pll-supply = <&pm8226_l8>; + mss-supply = <&pm8226_s5>; + + firmware-name = "qcom/msm8926/memul/mba.b00", "qcom/msm8926/memul/modem.mdt"; + + status = "okay"; +}; + &pm8226_vib { status = "okay"; };