From patchwork Mon Oct 16 12:47:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nia Espera X-Patchwork-Id: 735826 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8DA75CDB485 for ; Mon, 16 Oct 2023 12:47:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233502AbjJPMrU (ORCPT ); Mon, 16 Oct 2023 08:47:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34602 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233491AbjJPMrR (ORCPT ); Mon, 16 Oct 2023 08:47:17 -0400 Received: from fanzine2.igalia.com (fanzine.igalia.com [178.60.130.6]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5AE15F5; Mon, 16 Oct 2023 05:47:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Cc:To:In-Reply-To:References:Message-Id: Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date:From:Sender: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=PJALcNBz9ImCFUk6lytLPYTwt4DBsHnDsm7gSz1x8lo=; b=ff3G7CT6bnQycp0nllKxCQQDhD zeSvojJucET6lcblBDwzfvLHu3iWKjSLvwEQYdTY3IWhOcYXe6JkIlmgz50IJ/QoAghxE2FRD8g2u W8osi/fZoZwcV3GSP12kypy6EfNmCda56Im0EAFNfYMawfpSXazqeSeoZoN5i2H1wcjb1xXoQX4W+ xp3mWJndP8nIFjLcNHKXQRQcmlMTb2+nuz6shzg+/bWm0trpuUSob0pyUXvGG9OzNnpOh4e41F0v7 enNWAejnwCwmhUN2qRg4fHB5t97+T6K+119V1JM1v40DDTJK2tozppe6pzU+zh2JU7w+TsmcT0cr0 U+EeXRYw==; Received: from re-byods-146-50-198-227.wireless.uva.nl ([146.50.198.227]) by fanzine2.igalia.com with esmtpsa (Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim) id 1qsN02-0013kp-Ah; Mon, 16 Oct 2023 14:47:10 +0200 From: Nia Espera Date: Mon, 16 Oct 2023 14:47:01 +0200 Subject: [PATCH 1/5] iio: adc: add smb139x bindings MIME-Version: 1.0 Message-Id: <20231016-nia-sm8350-for-upstream-v1-1-bb557a0af2e9@igalia.com> References: <20231016-nia-sm8350-for-upstream-v1-0-bb557a0af2e9@igalia.com> In-Reply-To: <20231016-nia-sm8350-for-upstream-v1-0-bb557a0af2e9@igalia.com> To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Jonathan Cameron , Lars-Peter Clausen , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Kees Cook , Tony Luck , "Guilherme G. Piccoli" Cc: linux-arm-msm@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, phone-devel@vger.kernel.org, Rob , Clayton Craft , ~postmarketos/upstreaming@lists.sr.ht, Nia Espera X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=openpgp-sha256; l=1119; i=nespera@igalia.com; h=from:subject:message-id; bh=JHRfmZAZO9Oy7nubEEb+3rg3Tspx6ftNhCKm1jVHvjY=; b=owEB7QES/pANAwAIAfIkzsI3VuKtAcsmYgBlLTDMffV0GpejRx7QmlbEg2PlwXRVuPTe6tPP8 xqD1HE7EEmJAbMEAAEIAB0WIQSBPDomug3slDJEnubyJM7CN1birQUCZS0wzAAKCRDyJM7CN1bi rTsWC/0XeieJo2IcVNzUcx9Jsfe9cTj9Up0k1WgcjRrpMwX3+DYKzDOLW1vEeoz/tAasmpNODWT 9EGUTEsIzLwb7BNuR8VyNfR7ynOcXKb+2uB5FRzHTAirulWrTebIcIv27mQy5LDxtLdBK6U5PNv cONwZgTu/w+I++iBvdsq0wVxsKSiP2umK05khO6WWVrc09sVrhvv+yhL9R5VcNP2aHaMzKVFIFv 7gcxaT5Hb3CJkEgCE0rEa2VsD/0ROVB8F0EOjrhXgZ13jMWH9SEPB3Y6mSRsqz+iGMOxu+hDAcz 03+yxQruoE0eLyxxts26bAthoZ1PcA5UjWzPGFLw3p9e46KOxtCVo1wGcFoxiS0fIApZwjg+UdA oARxtd6LgeliRR1E0JxgHEv95LrAWt9yQDkZY6XePf3M/PZGsG0jkh6b6GhnwRplMW9jOQ+bvGM nKMhn1HTb0imE0G/upd7QG0K5XMkQBbd4+760su63q955yRqObKsuQYxwiTvCPdqoLBeM= X-Developer-Key: i=nespera@igalia.com; a=openpgp; fpr=813C3A26BA0DEC9432449EE6F224CEC23756E2AD Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Bindings for a charger controller chip found on sm8350 Signed-off-by: Nia Espera --- include/dt-bindings/iio/qcom,spmi-adc7-smb139x.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/include/dt-bindings/iio/qcom,spmi-adc7-smb139x.h b/include/dt-bindings/iio/qcom,spmi-adc7-smb139x.h new file mode 100644 index 000000000000..fe163cd8bbdd --- /dev/null +++ b/include/dt-bindings/iio/qcom,spmi-adc7-smb139x.h @@ -0,0 +1,17 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/* + * Copyright (c) 2020 The Linux Foundation. All rights reserved. + */ + +#ifndef _DT_BINDINGS_QCOM_SPMI_VADC_SMB139X_H +#define _DT_BINDINGS_QCOM_SPMI_VADC_SMB139X_H + +#define SMB139x_1_ADC7_SMB_TEMP (SMB139x_1_SID << 8 | 0x06) +#define SMB139x_1_ADC7_ICHG_SMB (SMB139x_1_SID << 8 | 0x18) +#define SMB139x_1_ADC7_IIN_SMB (SMB139x_1_SID << 8 | 0x19) + +#define SMB139x_2_ADC7_SMB_TEMP (SMB139x_2_SID << 8 | 0x06) +#define SMB139x_2_ADC7_ICHG_SMB (SMB139x_2_SID << 8 | 0x18) +#define SMB139x_2_ADC7_IIN_SMB (SMB139x_2_SID << 8 | 0x19) + +#endif From patchwork Mon Oct 16 12:47:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nia Espera X-Patchwork-Id: 735825 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0884ACDB48A for ; Mon, 16 Oct 2023 12:47:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233581AbjJPMrV (ORCPT ); Mon, 16 Oct 2023 08:47:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34614 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233499AbjJPMrS (ORCPT ); Mon, 16 Oct 2023 08:47:18 -0400 Received: from fanzine2.igalia.com (fanzine.igalia.com [178.60.130.6]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EF985AB; Mon, 16 Oct 2023 05:47:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Cc:To:In-Reply-To:References:Message-Id: Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date:From:Sender: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=efNuveP4VSQprhkHQkpwOHrplziHFsZy17voswzgGok=; b=oA1Gxot/Wn84Xqdp2axfR3lh8/ qxIRkM6hdqp4MOTXpd2xJ0hbH5RtgijelO/9/8mazQmFqhqE8l2NJVuPcgLuLEJiULGzzcLPda/7G HVErL+6+Wts7qAv7jAeErAxt+NetFEN2L3CyNno2SwH/j1OdgpQZrDk77LqIPtWPNkTNhK3wETItz e1PC3U9XKRHZ6zW2gYKH03iRUbHzZlAzToMoQ2jNhApsNNh1U04IKUyC8bGk854VfxjyvamGj1veN c/KSXDKkwCW3fJSNXge7B3qDASi0JKR1oQrq2Z1Ckk317iCpR2gOuc9St0y9qzvUm3VGh8ftQAcla L/A6iTwg==; Received: from re-byods-146-50-198-227.wireless.uva.nl ([146.50.198.227]) by fanzine2.igalia.com with esmtpsa (Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim) id 1qsN04-0013kp-OF; Mon, 16 Oct 2023 14:47:12 +0200 From: Nia Espera Date: Mon, 16 Oct 2023 14:47:04 +0200 Subject: [PATCH 4/5] arm64: dts: qcom: sm8350: Fix remoteproc interrupt type MIME-Version: 1.0 Message-Id: <20231016-nia-sm8350-for-upstream-v1-4-bb557a0af2e9@igalia.com> References: <20231016-nia-sm8350-for-upstream-v1-0-bb557a0af2e9@igalia.com> In-Reply-To: <20231016-nia-sm8350-for-upstream-v1-0-bb557a0af2e9@igalia.com> To: Andy Gross , Bjorn Andersson , Konrad Dybcio , Jonathan Cameron , Lars-Peter Clausen , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Kees Cook , Tony Luck , "Guilherme G. Piccoli" Cc: linux-arm-msm@vger.kernel.org, linux-iio@vger.kernel.org, devicetree@vger.kernel.org, phone-devel@vger.kernel.org, Rob , Clayton Craft , ~postmarketos/upstreaming@lists.sr.ht, Nia Espera X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=openpgp-sha256; l=2332; i=nespera@igalia.com; h=from:subject:message-id; bh=2PFXMWXBlmj0rQF2r2HKHb1q9m6vmsAuphNOSZ7iliw=; b=owEB7QES/pANAwAIAfIkzsI3VuKtAcsmYgBlLTDMr64l6MLHf5aiEWMAqZ9PXu3oPY0It062a QarwAUm+0WJAbMEAAEIAB0WIQSBPDomug3slDJEnubyJM7CN1birQUCZS0wzAAKCRDyJM7CN1bi rQcADACUCuXjFvLkvcXmHWlMIDsPJXEArIW9tmbRnIINcMWbeHSMRRotF+IDgh1bgcHZVsU9IVh 1K91K+MstHUrWOFoZ8LRuL9rQXXtNucCSnxlJ8sdiB9n+TR8GGV7czb4XRqQZW4a8Yp22KgT8Bx WuPYegzBobnXzoeQR9sK34BVNSrQYhyHtr+rRi0pCVSnyD77OjuKyHG4HbYW2v2KUWaVh5XEf4C GLsLw/E/qZjRRvzK8Q+KJoEGQqH5a04dzVmXb+5OLINSu+s1Y3boOkaNcw9QtKaboioQCPepwse mjFZEi9FkPZc2Iy0gyzzHI2qyKQs+3FpX419Gwv8IuPP8omVGRMPC2UgFE7OtcUXgz5af5qj2y+ x0HUve6qtz+dbjCpxrq1bqQlNnrnTEqGtffkd1WfFet9V16krCijS1jixLR1p7ddq4mfO0Fs4pl /u52SMW7udGeAypNSCaZuZCoKM/IJUMaR7jW5bnBUVXMWu50Ve0gXXMlTC9y8e3teHXgo= X-Developer-Key: i=nespera@igalia.com; a=openpgp; fpr=813C3A26BA0DEC9432449EE6F224CEC23756E2AD Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org In a similar vein to https://lore.kernel.org/lkml/20220530080842.37024-3-manivannan.sadhasivam@linaro.org/, the remote processors on sm8350 fail to initialize with the 'correct' (i.e., specified in downstream) IRQ type. Change this to EDGE_RISING. Signed-off-by: Nia Espera --- arch/arm64/boot/dts/qcom/sm8350.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm8350.dtsi b/arch/arm64/boot/dts/qcom/sm8350.dtsi index 6d12066389fa..7d5ea338a870 100644 --- a/arch/arm64/boot/dts/qcom/sm8350.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8350.dtsi @@ -2020,7 +2020,7 @@ mpss: remoteproc@4080000 { compatible = "qcom,sm8350-mpss-pas"; reg = <0x0 0x04080000 0x0 0x4040>; - interrupts-extended = <&intc GIC_SPI 264 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&intc GIC_SPI 264 IRQ_TYPE_EDGE_RISING>, <&smp2p_modem_in 0 IRQ_TYPE_EDGE_RISING>, <&smp2p_modem_in 1 IRQ_TYPE_EDGE_RISING>, <&smp2p_modem_in 2 IRQ_TYPE_EDGE_RISING>, @@ -2062,7 +2062,7 @@ slpi: remoteproc@5c00000 { compatible = "qcom,sm8350-slpi-pas"; reg = <0 0x05c00000 0 0x4000>; - interrupts-extended = <&pdc 9 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&pdc 9 IRQ_TYPE_EDGE_RISING>, <&smp2p_slpi_in 0 IRQ_TYPE_EDGE_RISING>, <&smp2p_slpi_in 1 IRQ_TYPE_EDGE_RISING>, <&smp2p_slpi_in 2 IRQ_TYPE_EDGE_RISING>, @@ -3206,7 +3206,7 @@ adsp: remoteproc@17300000 { compatible = "qcom,sm8350-adsp-pas"; reg = <0 0x17300000 0 0x100>; - interrupts-extended = <&pdc 6 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&pdc 6 IRQ_TYPE_EDGE_RISING>, <&smp2p_adsp_in 0 IRQ_TYPE_EDGE_RISING>, <&smp2p_adsp_in 1 IRQ_TYPE_EDGE_RISING>, <&smp2p_adsp_in 2 IRQ_TYPE_EDGE_RISING>, @@ -3511,7 +3511,7 @@ cdsp: remoteproc@98900000 { compatible = "qcom,sm8350-cdsp-pas"; reg = <0 0x98900000 0 0x1400000>; - interrupts-extended = <&intc GIC_SPI 578 IRQ_TYPE_LEVEL_HIGH>, + interrupts-extended = <&intc GIC_SPI 578 IRQ_TYPE_EDGE_RISING>, <&smp2p_cdsp_in 0 IRQ_TYPE_EDGE_RISING>, <&smp2p_cdsp_in 1 IRQ_TYPE_EDGE_RISING>, <&smp2p_cdsp_in 2 IRQ_TYPE_EDGE_RISING>,