From patchwork Fri Feb 5 01:52:04 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Li X-Patchwork-Id: 12069143 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2493CC433E6 for ; Fri, 5 Feb 2021 01:53:39 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C13EF64FB2 for ; Fri, 5 Feb 2021 01:53:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229529AbhBEBx2 (ORCPT ); Thu, 4 Feb 2021 20:53:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60480 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229466AbhBEBxX (ORCPT ); Thu, 4 Feb 2021 20:53:23 -0500 Received: from mail-pf1-x42b.google.com (mail-pf1-x42b.google.com [IPv6:2607:f8b0:4864:20::42b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DB22CC06178C for ; Thu, 4 Feb 2021 17:52:42 -0800 (PST) Received: by mail-pf1-x42b.google.com with SMTP id q20so3288090pfu.8 for ; Thu, 04 Feb 2021 17:52:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=squareup.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=tDdfcsBZJuJtkpBOSJDEI0wgJxTXViUcOD8MHou6QmE=; b=UNllgY9o6Zzj174wA73LqGonWn6zXEg/nLHpYeKA/TVksgv4J/R0FtpB8pALL2N5rz p86HW3l6UuuNeoOpsKo/5uIxRxhzrCtqcI2ez9sEncG3knq3HGOGk0n67iIp5QC2QHnc KzvuXymqpnAffLPotK9GOEJiPsrrQLZ/kfyrk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=tDdfcsBZJuJtkpBOSJDEI0wgJxTXViUcOD8MHou6QmE=; b=EsjEP/AyhyzrZgUyx0KNwjwkwPptdqHJNWr9eIYO1+/VX6z9xjeePfjR9hMZ425WGC WhWVyu7bOGTfzX8HvkiMFUfeujDULUJXuCWL8w+WOOpxEAL/3poecTOC/xZ/hLvtMnQd 3rezXANAonI84iZLz/fJOWqySQM/mnXB7qlFl9zygPzz4DrJ1miw2A4aL9myXRvhq+sm s9Tb63EfgD5g1tC4IyXzV3jaq48UpZ9vRsoHU/C/xr7l/Myf+KSVPAMZU7NzIlQ/83OB D1mOr8JHqa7BuUCpjIoZh8m6py2MZYEFKEnphZawNAH5ttVjHepeAYRphR0Z4CI0MftW dQtw== X-Gm-Message-State: AOAM533Kt3x+SDlPGOnqbhzf16UveQd7f0166lMS9IcN8FZJqAKq53ef o/lXiRI11kMHOQopqemwnKh3FA== X-Google-Smtp-Source: ABdhPJwLComfvN7kPjNjD0EXVFbUIvYluUGScCCMqUv57Xn5xQlBosQGg3qC6KqznEdWp6yW4uZhfg== X-Received: by 2002:a62:6202:0:b029:1bb:a811:da59 with SMTP id w2-20020a6262020000b02901bba811da59mr1896539pfb.27.1612489962411; Thu, 04 Feb 2021 17:52:42 -0800 (PST) Received: from localhost (162-207-206-139.lightspeed.sntcca.sbcglobal.net. [162.207.206.139]) by smtp.gmail.com with ESMTPSA id a188sm7596357pfb.108.2021.02.04.17.52.40 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 04 Feb 2021 17:52:41 -0800 (PST) From: Benjamin Li To: Georgi Djakov , Jun Nie Cc: kernel@squareup.com, Benjamin Li , Andy Gross , Bjorn Andersson , Georgi Djakov , linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/2] interconnect: qcom: icc-rpm: record slave RPM id in error log Date: Thu, 4 Feb 2021 17:52:04 -0800 Message-Id: <20210205015205.22947-2-benl@squareup.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210205015205.22947-1-benl@squareup.com> References: <20210205015205.22947-1-benl@squareup.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add slave RPM ID to assist with identifying incorrect RPM config. Signed-off-by: Benjamin Li --- drivers/interconnect/qcom/icc-rpm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/interconnect/qcom/icc-rpm.c b/drivers/interconnect/qcom/icc-rpm.c index cc6095492cbe..54de49ca7808 100644 --- a/drivers/interconnect/qcom/icc-rpm.c +++ b/drivers/interconnect/qcom/icc-rpm.c @@ -59,8 +59,8 @@ static int qcom_icc_set(struct icc_node *src, struct icc_node *dst) qn->slv_rpm_id, sum_bw); if (ret) { - pr_err("qcom_icc_rpm_smd_send slv error %d\n", - ret); + pr_err("qcom_icc_rpm_smd_send slv %d error %d\n", + qn->slv_rpm_id, ret); return ret; } } From patchwork Fri Feb 5 01:52:05 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Li X-Patchwork-Id: 12069145 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 38F00C433DB for ; Fri, 5 Feb 2021 01:54:25 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id CB5F364EE2 for ; Fri, 5 Feb 2021 01:54:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229745AbhBEByO (ORCPT ); Thu, 4 Feb 2021 20:54:14 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60618 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229513AbhBEByA (ORCPT ); Thu, 4 Feb 2021 20:54:00 -0500 Received: from mail-pf1-x430.google.com (mail-pf1-x430.google.com [IPv6:2607:f8b0:4864:20::430]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EEB8FC061797 for ; Thu, 4 Feb 2021 17:52:46 -0800 (PST) Received: by mail-pf1-x430.google.com with SMTP id f63so3274827pfa.13 for ; Thu, 04 Feb 2021 17:52:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=squareup.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=dbop8oOXb3CIgxFtxFxfz6HESSuLiJPucRa+5GXJ/bo=; b=fQMaSLXGZBrcPVrSQYclJC9FHcowZVqyYZUFs6lyFiNZAI7A4ub83yhp274+9RAeE9 Ps2u2TNuh/38BXmQAKsKOfP0eJjWsAciFmHtJY+z4xy2fJe+3tcLPuGHGkBUftTjNwyp IZ/tng9+CFkS0CzCXTqAddrqT/SsnL2JqjM+w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=dbop8oOXb3CIgxFtxFxfz6HESSuLiJPucRa+5GXJ/bo=; b=N9oDkHos2Ms6Ogj9SFMFQJY+nycwloU5ZJiGnpMfeeARq024QRQJka2dAUdEPK2fCD LH/oNH1LcGLe2a2XN52I+IQbuAREx0YmemYdd/P+55lfzQob8EgxiA43soilKa6QuaTj G3fljVumJUrHv/flwPQougHT7EcQKm0UGL8IUL3XC5OADH8EkRrCj9FlNQNnaPBvwUBF xflGiDwW5906npMBdwf39i5uB8AFiOLTegbt427t4spL4lYXdrg0ZzJc6G1PKnnAwZ+d kgH2Fsc0UhyjBUuLqHycbIHsLKaQUKrXSLN5wWfyYgeHxmybcp6nUIsLd1SxJbRqOtJe B00A== X-Gm-Message-State: AOAM5300MFLs2k1uTra/WOtIzs4FqG8+PkDesidKPvRUK1d8cwNg/FEo WvHUAUO7NFv0FiMHH7XG4oLEkQ== X-Google-Smtp-Source: ABdhPJx/CcA9hQR9m5B0/zVA9D6H4PJOG1ikKfcj7pc81C6qci/SwTbWYYrQYcuBgw5/v22eJWpGng== X-Received: by 2002:a65:620f:: with SMTP id d15mr1885160pgv.218.1612489966483; Thu, 04 Feb 2021 17:52:46 -0800 (PST) Received: from localhost (162-207-206-139.lightspeed.sntcca.sbcglobal.net. [162.207.206.139]) by smtp.gmail.com with ESMTPSA id n4sm6319302pgg.68.2021.02.04.17.52.44 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 04 Feb 2021 17:52:45 -0800 (PST) From: Benjamin Li To: Georgi Djakov , Jun Nie Cc: kernel@squareup.com, Benjamin Li , Andy Gross , Bjorn Andersson , Georgi Djakov , linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/2] interconnect: qcom: msm8939: remove rpm-ids from non-RPM nodes Date: Thu, 4 Feb 2021 17:52:05 -0800 Message-Id: <20210205015205.22947-3-benl@squareup.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210205015205.22947-1-benl@squareup.com> References: <20210205015205.22947-1-benl@squareup.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Some nodes are incorrectly marked as RPM-controlled (they have RPM master and slave ids assigned), but are actually controlled by the application CPU instead. The RPM complains when we send requests for resources that it can't control. Let's fix this by replacing the IDs, with the default "-1" in which case no requests are sent. See commit c497f9322af9 ("interconnect: qcom: msm8916: Remove rpm-ids from non-RPM nodes") where this was done for msm8916. Signed-off-by: Benjamin Li --- drivers/interconnect/qcom/msm8939.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/interconnect/qcom/msm8939.c b/drivers/interconnect/qcom/msm8939.c index dfbec30ed149..20f31a1b4192 100644 --- a/drivers/interconnect/qcom/msm8939.c +++ b/drivers/interconnect/qcom/msm8939.c @@ -131,7 +131,7 @@ DEFINE_QNODE(mas_pcnoc_sdcc_1, MSM8939_MASTER_SDCC_1, 8, -1, -1, MSM8939_PNOC_IN DEFINE_QNODE(mas_pcnoc_sdcc_2, MSM8939_MASTER_SDCC_2, 8, -1, -1, MSM8939_PNOC_INT_1); DEFINE_QNODE(mas_qdss_bam, MSM8939_MASTER_QDSS_BAM, 8, -1, -1, MSM8939_SNOC_QDSS_INT); DEFINE_QNODE(mas_qdss_etr, MSM8939_MASTER_QDSS_ETR, 8, -1, -1, MSM8939_SNOC_QDSS_INT); -DEFINE_QNODE(mas_snoc_cfg, MSM8939_MASTER_SNOC_CFG, 4, 20, -1, MSM8939_SLAVE_SRVC_SNOC); +DEFINE_QNODE(mas_snoc_cfg, MSM8939_MASTER_SNOC_CFG, 4, -1, -1, MSM8939_SLAVE_SRVC_SNOC); DEFINE_QNODE(mas_spdm, MSM8939_MASTER_SPDM, 4, -1, -1, MSM8939_PNOC_MAS_0); DEFINE_QNODE(mas_tcu0, MSM8939_MASTER_TCU0, 16, -1, -1, MSM8939_SLAVE_EBI_CH0, MSM8939_BIMC_SNOC_MAS, MSM8939_SLAVE_AMPSS_L2); DEFINE_QNODE(mas_usb_hs1, MSM8939_MASTER_USB_HS1, 4, -1, -1, MSM8939_PNOC_MAS_1); @@ -156,14 +156,14 @@ DEFINE_QNODE(pcnoc_snoc_mas, MSM8939_PNOC_SNOC_MAS, 8, 29, -1, MSM8939_PNOC_SNOC DEFINE_QNODE(pcnoc_snoc_slv, MSM8939_PNOC_SNOC_SLV, 8, -1, 45, MSM8939_SNOC_INT_0, MSM8939_SNOC_INT_BIMC, MSM8939_SNOC_INT_1); DEFINE_QNODE(qdss_int, MSM8939_SNOC_QDSS_INT, 8, -1, -1, MSM8939_SNOC_INT_0, MSM8939_SNOC_INT_BIMC); DEFINE_QNODE(slv_apps_l2, MSM8939_SLAVE_AMPSS_L2, 16, -1, -1, 0); -DEFINE_QNODE(slv_apss, MSM8939_SLAVE_APSS, 4, -1, 20, 0); +DEFINE_QNODE(slv_apss, MSM8939_SLAVE_APSS, 4, -1, -1, 0); DEFINE_QNODE(slv_audio, MSM8939_SLAVE_LPASS, 4, -1, -1, 0); DEFINE_QNODE(slv_bimc_cfg, MSM8939_SLAVE_BIMC_CFG, 4, -1, -1, 0); DEFINE_QNODE(slv_blsp_1, MSM8939_SLAVE_BLSP_1, 4, -1, -1, 0); DEFINE_QNODE(slv_boot_rom, MSM8939_SLAVE_BOOT_ROM, 4, -1, -1, 0); DEFINE_QNODE(slv_camera_cfg, MSM8939_SLAVE_CAMERA_CFG, 4, -1, -1, 0); -DEFINE_QNODE(slv_cats_0, MSM8939_SLAVE_CATS_128, 16, -1, 106, 0); -DEFINE_QNODE(slv_cats_1, MSM8939_SLAVE_OCMEM_64, 8, -1, 107, 0); +DEFINE_QNODE(slv_cats_0, MSM8939_SLAVE_CATS_128, 16, -1, -1, 0); +DEFINE_QNODE(slv_cats_1, MSM8939_SLAVE_OCMEM_64, 8, -1, -1, 0); DEFINE_QNODE(slv_clk_ctl, MSM8939_SLAVE_CLK_CTL, 4, -1, -1, 0); DEFINE_QNODE(slv_crypto_0_cfg, MSM8939_SLAVE_CRYPTO_0_CFG, 4, -1, -1, 0); DEFINE_QNODE(slv_dehr_cfg, MSM8939_SLAVE_DEHR_CFG, 4, -1, -1, 0); @@ -187,20 +187,20 @@ DEFINE_QNODE(slv_sdcc_2, MSM8939_SLAVE_SDCC_2, 4, -1, -1, 0); DEFINE_QNODE(slv_security, MSM8939_SLAVE_SECURITY, 4, -1, -1, 0); DEFINE_QNODE(slv_snoc_cfg, MSM8939_SLAVE_SNOC_CFG, 4, -1, -1, 0); DEFINE_QNODE(slv_spdm, MSM8939_SLAVE_SPDM, 4, -1, -1, 0); -DEFINE_QNODE(slv_srvc_snoc, MSM8939_SLAVE_SRVC_SNOC, 8, -1, 29, 0); +DEFINE_QNODE(slv_srvc_snoc, MSM8939_SLAVE_SRVC_SNOC, 8, -1, -1, 0); DEFINE_QNODE(slv_tcsr, MSM8939_SLAVE_TCSR, 4, -1, -1, 0); DEFINE_QNODE(slv_tlmm, MSM8939_SLAVE_TLMM, 4, -1, -1, 0); DEFINE_QNODE(slv_usb_hs1, MSM8939_SLAVE_USB_HS1, 4, -1, -1, 0); DEFINE_QNODE(slv_usb_hs2, MSM8939_SLAVE_USB_HS2, 4, -1, -1, 0); DEFINE_QNODE(slv_venus_cfg, MSM8939_SLAVE_VENUS_CFG, 4, -1, -1, 0); -DEFINE_QNODE(snoc_bimc_0_mas, MSM8939_SNOC_BIMC_0_MAS, 16, 3, -1, MSM8939_SNOC_BIMC_0_SLV); -DEFINE_QNODE(snoc_bimc_0_slv, MSM8939_SNOC_BIMC_0_SLV, 16, -1, 24, MSM8939_SLAVE_EBI_CH0); +DEFINE_QNODE(snoc_bimc_0_mas, MSM8939_SNOC_BIMC_0_MAS, 16, -1, -1, MSM8939_SNOC_BIMC_0_SLV); +DEFINE_QNODE(snoc_bimc_0_slv, MSM8939_SNOC_BIMC_0_SLV, 16, -1, -1, MSM8939_SLAVE_EBI_CH0); DEFINE_QNODE(snoc_bimc_1_mas, MSM8939_SNOC_BIMC_1_MAS, 16, 76, -1, MSM8939_SNOC_BIMC_1_SLV); DEFINE_QNODE(snoc_bimc_1_slv, MSM8939_SNOC_BIMC_1_SLV, 16, -1, 104, MSM8939_SLAVE_EBI_CH0); DEFINE_QNODE(snoc_bimc_2_mas, MSM8939_SNOC_BIMC_2_MAS, 16, -1, -1, MSM8939_SNOC_BIMC_2_SLV); DEFINE_QNODE(snoc_bimc_2_slv, MSM8939_SNOC_BIMC_2_SLV, 16, -1, -1, MSM8939_SLAVE_EBI_CH0); DEFINE_QNODE(snoc_int_0, MSM8939_SNOC_INT_0, 8, 99, 130, MSM8939_SLAVE_QDSS_STM, MSM8939_SLAVE_IMEM, MSM8939_SNOC_PNOC_MAS); -DEFINE_QNODE(snoc_int_1, MSM8939_SNOC_INT_1, 8, 100, 131, MSM8939_SLAVE_APSS, MSM8939_SLAVE_CATS_128, MSM8939_SLAVE_OCMEM_64); +DEFINE_QNODE(snoc_int_1, MSM8939_SNOC_INT_1, 8, -1, -1, MSM8939_SLAVE_APSS, MSM8939_SLAVE_CATS_128, MSM8939_SLAVE_OCMEM_64); DEFINE_QNODE(snoc_int_bimc, MSM8939_SNOC_INT_BIMC, 8, 101, 132, MSM8939_SNOC_BIMC_1_MAS); DEFINE_QNODE(snoc_pcnoc_mas, MSM8939_SNOC_PNOC_MAS, 8, -1, -1, MSM8939_SNOC_PNOC_SLV); DEFINE_QNODE(snoc_pcnoc_slv, MSM8939_SNOC_PNOC_SLV, 8, -1, -1, MSM8939_PNOC_INT_0);