From patchwork Sun Sep 26 19:06:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yassine Oudjana X-Patchwork-Id: 12518421 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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6DEAAC433F5 for ; Sun, 26 Sep 2021 19:06:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5352660F44 for ; Sun, 26 Sep 2021 19:06:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229885AbhIZTIG (ORCPT ); Sun, 26 Sep 2021 15:08:06 -0400 Received: from mail-4325.protonmail.ch ([185.70.43.25]:14425 "EHLO mail-4325.protonmail.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229814AbhIZTIG (ORCPT ); Sun, 26 Sep 2021 15:08:06 -0400 Date: Sun, 26 Sep 2021 19:06:22 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1632683187; bh=LdGDg/NBcAqIMdIuneUdujL/LJH1Ulm1hfpZVp1FwMU=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=ZtRFfojbOzl1fHV7Y+CbJ/OOPOsheYXpFS9R4z96mru8g+9HLVsZgzfoYrJW9aN66 /BN3MPC9RDuuScoqLsMeWetDXE3Wi6iLlrjWSM7cj+EaaaaKLsn/9KdvDI5Krc4AN6 M3dLWUwNWDldKk1TKt1mXG8nz9Tee4W0nqz+hYAo= To: Andy Gross , Bjorn Andersson , Ohad Ben-Cohen , Mathieu Poirier , Rob Herring From: Yassine Oudjana Cc: Yassine Oudjana , AngeloGioacchino Del Regno , Konrad Dybcio , Raffaele Tranquillini , linux-arm-msm@vger.kernel.org, linux-remoteproc@vger.kernel.org, devicetree@vger.kernel.org, phone-devel@vger.kernel.org, linux-kernel@vger.kernel.org Reply-To: Yassine Oudjana Subject: [PATCH v2 2/5] remoteproc: qcom: pas: Use the same init resources for MSM8996 and MSM8998 Message-ID: <20210926190555.278589-3-y.oudjana@protonmail.com> In-Reply-To: <20210926190555.278589-1-y.oudjana@protonmail.com> References: <20210926190555.278589-1-y.oudjana@protonmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org The resources for MSM8996 are missing power domains, and adding them makes the resources identical to the MSM8998 ones. Rename msm8998_adsp_resource to msm8996_adsp_resource then use it for both chips. Also add power domains to slpi_resource_init and use it for both chips. Signed-off-by: Yassine Oudjana --- drivers/remoteproc/qcom_q6v5_pas.c | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) diff --git a/drivers/remoteproc/qcom_q6v5_pas.c b/drivers/remoteproc/qcom_q6v5_pas.c index 401b1ec90785..5e862401b66e 100644 --- a/drivers/remoteproc/qcom_q6v5_pas.c +++ b/drivers/remoteproc/qcom_q6v5_pas.c @@ -585,7 +585,7 @@ static const struct adsp_data sm8350_adsp_resource = { .ssctl_id = 0x14, }; -static const struct adsp_data msm8998_adsp_resource = { +static const struct adsp_data msm8996_adsp_resource = { .crash_reason_smem = 423, .firmware_name = "adsp.mdt", .pas_id = 1, @@ -714,6 +714,10 @@ static const struct adsp_data slpi_resource_init = { .pas_id = 12, .has_aggre2_clk = true, .auto_boot = true, + .proxy_pd_names = (char*[]){ + "ssc_cx", + NULL + }, .ssr_name = "dsps", .sysmon_name = "slpi", .ssctl_id = 0x16, @@ -779,21 +783,6 @@ static const struct adsp_data sm8350_slpi_resource = { .ssctl_id = 0x16, }; -static const struct adsp_data msm8998_slpi_resource = { - .crash_reason_smem = 424, - .firmware_name = "slpi.mdt", - .pas_id = 12, - .has_aggre2_clk = true, - .auto_boot = true, - .proxy_pd_names = (char*[]){ - "ssc_cx", - NULL - }, - .ssr_name = "dsps", - .sysmon_name = "slpi", - .ssctl_id = 0x16, -}; - static const struct adsp_data wcss_resource_init = { .crash_reason_smem = 421, .firmware_name = "wcnss.mdt", @@ -822,10 +811,10 @@ static const struct adsp_data sdx55_mpss_resource = { static const struct of_device_id adsp_of_match[] = { { .compatible = "qcom,msm8974-adsp-pil", .data = &adsp_resource_init}, - { .compatible = "qcom,msm8996-adsp-pil", .data = &adsp_resource_init}, + { .compatible = "qcom,msm8996-adsp-pil", .data = &msm8996_adsp_resource}, { .compatible = "qcom,msm8996-slpi-pil", .data = &slpi_resource_init}, - { .compatible = "qcom,msm8998-adsp-pas", .data = &msm8998_adsp_resource}, - { .compatible = "qcom,msm8998-slpi-pas", .data = &msm8998_slpi_resource}, + { .compatible = "qcom,msm8998-adsp-pas", .data = &msm8996_adsp_resource}, + { .compatible = "qcom,msm8998-slpi-pas", .data = &slpi_resource_init}, { .compatible = "qcom,qcs404-adsp-pas", .data = &adsp_resource_init }, { .compatible = "qcom,qcs404-cdsp-pas", .data = &cdsp_resource_init }, { .compatible = "qcom,qcs404-wcss-pas", .data = &wcss_resource_init },