From patchwork Tue Apr 11 13:47:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 81978 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2600242vqo; Tue, 11 Apr 2023 07:04:53 -0700 (PDT) X-Google-Smtp-Source: AKy350aw+zuk7xGJQz+vz4enwKFSVJSm5H0Jnu2FBv0pKuab1sjhhbYc01ICUsyAnrkjhGejFOHh X-Received: by 2002:a05:6402:1806:b0:4ac:b6b2:1233 with SMTP id g6-20020a056402180600b004acb6b21233mr11324164edy.30.1681221892804; Tue, 11 Apr 2023 07:04:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681221892; cv=none; d=google.com; s=arc-20160816; b=zGtXxvJYnUzpTk/bkjO6b3Ds5UGTIHxExbd301w2yThYqJF/2GdBZ8pHpVCy7XmRR4 KISYgkry/r8xPhAc8SzS40a0nowns1IRGpR/7Bqd5LRe+C4ECIWufXTJK2InkCbNE3A6 RoomyKnKvOMxc1B+rEwU7t14I1VG4VNpZDvsH5tfsQzz3hU8kxjH5adjO6Uroaqa+MJs QNmTEx6alK8kiFyHCS/W4ysblrLJWSmiGBL3Jfqdy1PtQ4DurIR6pc0T691aFE69SQwy oF6CoWVnRpqugN+67xYMC7ddlKr5SjIB91inUzJr5ezjNS7DrE5S48JtN4Re7aVnF/Tn jvzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=7u3cWIrv9ii7tk7AluAyAc28Sz76nQ4EdYUWb/87faI=; b=B+kUqMDLHJtVR5hYAtG6evDx3I4C1r+nBl9n7wH9yg+doW0ZHpJ8tNP2PfKg91q6Rt bP1Iaw65GjniAG4tYW+zuRZyTivZKuI0AYJTbB+UGBJ6nahirpZQ1soEhJBEKzvyRUQr CKUTpZ4scS0Wda2z0ZuSVpaYifWfNfejTUP2CrOoQ0/UqbI2VRbqrP7EcnFiW0/Gn4Qn V1N1+Jz9ez7WBVGdTokvvcN9ZEGXYwHUoq5VrVV3ZkSrvRNjVo51n9LGtIrjcRxsRAdm On4hTcuLCAzGdmeaw54cvb/Tfu5VXIUw+4Za4zYI/BXjTBFEwb6JbU55JPotDVNG2xjH mGMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jFgb4agX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v15-20020aa7d80f000000b004ab162a8415si12512596edq.283.2023.04.11.07.04.16; Tue, 11 Apr 2023 07:04:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jFgb4agX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230372AbjDKNr0 (ORCPT + 99 others); Tue, 11 Apr 2023 09:47:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33760 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230347AbjDKNrW (ORCPT ); Tue, 11 Apr 2023 09:47:22 -0400 Received: from mail-lj1-x230.google.com (mail-lj1-x230.google.com [IPv6:2a00:1450:4864:20::230]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D89192D4E for ; Tue, 11 Apr 2023 06:47:21 -0700 (PDT) Received: by mail-lj1-x230.google.com with SMTP id b33so4208080ljf.2 for ; Tue, 11 Apr 2023 06:47:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681220840; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=7u3cWIrv9ii7tk7AluAyAc28Sz76nQ4EdYUWb/87faI=; b=jFgb4agX4lazt4/ZszyG08ELsETbvW3xLfgM0i1ouStqSP+Y9JAqhQoEJTrvSt438F FOmWYogsRPjMbzL6YUfgpUW1Olfo6C6I38OQq2hHrFm+L9c7NiEPB6YwEabMc2LJUOV9 o7cLSMREy8g3A5Dip9viKPO4t7XiVYL16IJ61tPrVmcLiyVbh2EPhaXzhuGgh1oL0Qzr m83uDro7GKL2aLlOhS1O0j51QekunK/Ur2DUp9ICMDZLp+czYGbvaYNcFTLNlnGHqLA+ 8R0gSWs4D0r3507poUVxpYLjxWckZBpSNqf+oaOPGYLS6mpBXZuyJdtyEDUTPOvaliHP pZ1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681220840; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=7u3cWIrv9ii7tk7AluAyAc28Sz76nQ4EdYUWb/87faI=; b=s+gPLHA3rg2Qg21KFpjEmJbeHcuMOtnu0JwBPiU0z6o8PTb/27YnJetT4Fw9+/dyPt qL4lYhGbKaQA5lc7NyzjxuKWmIYzCx4a/vy+GkKMM7Mst7wC1ZR9hI5PciDNN63CtrHr OJdplKjEcnqEaTvKZpP6Jk0+LkUJD9u7BEIqbrlQuBFtE+wOC6fmxz/cxEAtBV0/hHAJ 9i4GtOAd/O1ovAEHWe2Sg+XqJ9LVUSBwfI54wn7Z17s1GIqPDy3TrQbxK581zel0BDUO LRvUKNWaxfpKEIYfzlz0qa+AE5aGEQEi/HFWgZgQPNkJtnIixrA27xClSoBbgtrgIFpW NtJQ== X-Gm-Message-State: AAQBX9d/Q4qIcK+40pvoy1WVAQlkYotAJEEkS1s0agkz6tQUKWfPi3YN lLQ39tgt7Xx74WECvs9w4MYc0A== X-Received: by 2002:a05:651c:86:b0:2a7:8544:1e71 with SMTP id 6-20020a05651c008600b002a785441e71mr1007706ljq.3.1681220840146; Tue, 11 Apr 2023 06:47:20 -0700 (PDT) Received: from [192.168.1.101] (abxj23.neoplus.adsl.tpnet.pl. [83.9.3.23]) by smtp.gmail.com with ESMTPSA id c10-20020a2e680a000000b002a77583b718sm1245887lja.12.2023.04.11.06.47.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Apr 2023 06:47:19 -0700 (PDT) From: Konrad Dybcio Date: Tue, 11 Apr 2023 15:47:15 +0200 Subject: [PATCH v2 1/3] dt-bindings: power: qcom,rpmpd: Add SA8155P MIME-Version: 1.0 Message-Id: <20230411-topic-hanaau-v2-1-fd3d70844b31@linaro.org> References: <20230411-topic-hanaau-v2-0-fd3d70844b31@linaro.org> In-Reply-To: <20230411-topic-hanaau-v2-0-fd3d70844b31@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski , Bhupesh Sharma , Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1681220837; l=1558; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=oNW0CgFyxBXeievXT87JHE+KppSisz4HMgd5P1GQgyc=; b=1gOb3wAz8sBLrYX3/bS5JEeK4J5PuGFWkLeVjGnuGJoLuky+eOYnSAc6VULEQjLEUBTpPCf8JMUF Sh/t7bqlDncO5N7MseZ90ARv39biQHBUWccpuA55CBT4K+ihKTin X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762888927394454137?= X-GMAIL-MSGID: =?utf-8?q?1762888927394454137?= Add a compatible for SA8155P platforms and relevant defines to the include file. Signed-off-by: Konrad Dybcio Acked-by: Krzysztof Kozlowski --- Documentation/devicetree/bindings/power/qcom,rpmpd.yaml | 1 + include/dt-bindings/power/qcom-rpmpd.h | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/Documentation/devicetree/bindings/power/qcom,rpmpd.yaml b/Documentation/devicetree/bindings/power/qcom,rpmpd.yaml index afad3135ed67..f9c211a9a938 100644 --- a/Documentation/devicetree/bindings/power/qcom,rpmpd.yaml +++ b/Documentation/devicetree/bindings/power/qcom,rpmpd.yaml @@ -29,6 +29,7 @@ properties: - qcom,qcm2290-rpmpd - qcom,qcs404-rpmpd - qcom,qdu1000-rpmhpd + - qcom,sa8155p-rpmhpd - qcom,sa8540p-rpmhpd - qcom,sa8775p-rpmhpd - qcom,sdm660-rpmpd diff --git a/include/dt-bindings/power/qcom-rpmpd.h b/include/dt-bindings/power/qcom-rpmpd.h index 1bf8e87ecd7e..867b18e041ea 100644 --- a/include/dt-bindings/power/qcom-rpmpd.h +++ b/include/dt-bindings/power/qcom-rpmpd.h @@ -90,6 +90,15 @@ #define SM8150_MMCX 9 #define SM8150_MMCX_AO 10 +/* SA8155P is a special case, kept for backwards compatibility */ +#define SA8155P_CX SM8150_CX +#define SA8155P_CX_AO SM8150_CX_AO +#define SA8155P_EBI SM8150_EBI +#define SA8155P_GFX SM8150_GFX +#define SA8155P_MSS SM8150_MSS +#define SA8155P_MX SM8150_MX +#define SA8155P_MX_AO SM8150_MX_AO + /* SM8250 Power Domain Indexes */ #define SM8250_CX 0 #define SM8250_CX_AO 1 From patchwork Tue Apr 11 13:47:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 81985 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2604593vqo; Tue, 11 Apr 2023 07:09:29 -0700 (PDT) X-Google-Smtp-Source: AKy350Y/DQewsDmU/zGZQxuyTyKHVcLR7kPmmD+UC3Kw4AvALpUBDo05xKjYjL74zCBO9P+TkEH1 X-Received: by 2002:a05:6a20:bf09:b0:ea:fd23:8ad4 with SMTP id gc9-20020a056a20bf0900b000eafd238ad4mr2755214pzb.57.1681222169578; Tue, 11 Apr 2023 07:09:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681222169; cv=none; d=google.com; s=arc-20160816; b=ukMmDPbhg/Wz3k0VKrrfDtccieUry8kk6eM/j0czshHPTP6LHhyB/9olQxsuI5l+av 7LI9eP3keC9wF1kKDpQSpqDuvGBwkwpdDXQ2p8KBzJCTQwmxHCyz3zNJtPX1OMpWRA8O CaMgk1bIv1+ccNUty0SwesfTxwL/KcJmd0RGyqxjMV/7X/CAhvOf4zQyzn+/A9kvLVdk MNrQcOMdIgM/fo06Ypia0Y3rE1nT/tGB+YzrVzNDI4MNiTm9d+48LGRhDPFr6rcze3QY kCST8juCMz9jq8VAclEIe/Z87ZwagKBxetbMi0E61cSNPE196vMdjJEbSmOvuFeUYVLO DvcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=aMpFnRGQLpD0/uI8QbJICzvLZYwTAUaXXk9QdFEBIQM=; b=Hp8fWoGeeXnX8q6cWSAhWYVuzQEBn7mblP5eJ+eDUZjh+7vvtp/+NuocJBctRQcn/g vxrPRORE6MqCmqBHbMJN+uembXqwye7nJVu2KsC+NbPXfvf/bkwn350mu3FPCtwWfmY2 6jOoCTj+5dtd71xSX4j/sDf2qgemMbGRpFdfLFQy3sVZRKvsvJ/bslwfOjWEDTAJjK+j EaUrqtF7M5ZM1M6v2eYaKR/RSM5io5y5bNlmC+U2TZ2c4Q8ufqkydb9xJHkBmcCKPfRS u0CLWkvvLbDl22gbDxbGoXFQynOlH2J+yfbltTD5mVX2ZC2/sdPH67IAbnouKGlrwQ5c +11w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ih1pAVET; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o11-20020a65614b000000b005002c94ff28si13080733pgv.495.2023.04.11.07.09.16; Tue, 11 Apr 2023 07:09:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ih1pAVET; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230233AbjDKNr3 (ORCPT + 99 others); Tue, 11 Apr 2023 09:47:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33802 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230364AbjDKNrY (ORCPT ); Tue, 11 Apr 2023 09:47:24 -0400 Received: from mail-lj1-x235.google.com (mail-lj1-x235.google.com [IPv6:2a00:1450:4864:20::235]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D8D1CBB for ; Tue, 11 Apr 2023 06:47:22 -0700 (PDT) Received: by mail-lj1-x235.google.com with SMTP id a29so9308418ljq.0 for ; Tue, 11 Apr 2023 06:47:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681220841; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=aMpFnRGQLpD0/uI8QbJICzvLZYwTAUaXXk9QdFEBIQM=; b=Ih1pAVETpfX6vFjZzsrU0nhzd9ooOsv4UtGhKo1SJ6Wb6JpfMUiUXnjPv8nyHl3Lj0 RGYILeR9gOPvstCnLS7AEkDv+HSTXSrCX4TOGAkF52s074/+NzvsrofUDJqCXaFC+Kj4 /pI0SU/zWbwGfVanqnk8XLgfMoS3got5TfRnQ34NYJ1rYZzoYWjc5BKSiNMt9nlwFKfa +biZlJH3jPZWiRnXEDefTGSYlIaB5jxFM1/dxJmuHFbpySiblP+5gNwo/whO3O5DI9j9 g4I1kZfgkEzmSJzsYaR+iCjHTzhxgrEDnUqtg9LLiiqbM1yOHjTGM/8mOkFO9ETPOh3Y BJwQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681220841; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=aMpFnRGQLpD0/uI8QbJICzvLZYwTAUaXXk9QdFEBIQM=; b=NUS0g6jLNqcrpVASfFRxxhMUjsA6y/HTIIQPoKKfy6kMfjw6uyO6vh+mobSJZxFmOQ Lsa763OB9lGcdy6wLzk0trj8u8C7tDwm7PWxhpHPjBNX4ujR0Zl+yEpoCHPALC/EeiGc MfzjB+rXWT0rievZX70MZuQdTOePln+orlnTmWXZvvh3Z72uPy0Ecl09d3imCvq/odHw CgnYILPztzOGtpGpdiShoGaPuU03Vjk+NbrxUJdgwrpZIZ3D65JKCLpcG88HoVjw4dFi xVQ2/Px8CmOxzHcLT+dctbdryxgBdE+UAsSDsG/uVpVVrUcgWUk4Fz73BqbqIpdRCmlr Ra6g== X-Gm-Message-State: AAQBX9chJ8Oq5D4FEZZ6m+3r2n6LvpaxWR3+4i1+8gj3a8mV74UR1gUR rJSYDWntkb6sGuPapvwiZ0Sv1Q== X-Received: by 2002:a05:651c:86:b0:2a7:8544:1e71 with SMTP id 6-20020a05651c008600b002a785441e71mr1007719ljq.3.1681220841307; Tue, 11 Apr 2023 06:47:21 -0700 (PDT) Received: from [192.168.1.101] (abxj23.neoplus.adsl.tpnet.pl. [83.9.3.23]) by smtp.gmail.com with ESMTPSA id c10-20020a2e680a000000b002a77583b718sm1245887lja.12.2023.04.11.06.47.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Apr 2023 06:47:21 -0700 (PDT) From: Konrad Dybcio Date: Tue, 11 Apr 2023 15:47:16 +0200 Subject: [PATCH v2 2/3] soc: qcom: rpmhpd: Add SA8155P power domains MIME-Version: 1.0 Message-Id: <20230411-topic-hanaau-v2-2-fd3d70844b31@linaro.org> References: <20230411-topic-hanaau-v2-0-fd3d70844b31@linaro.org> In-Reply-To: <20230411-topic-hanaau-v2-0-fd3d70844b31@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski , Bhupesh Sharma , Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1681220837; l=1539; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=aleVgKoikHUj3PFLGGlVddGgNibZMFZrpZpiNyXETRk=; b=sTkfdoeJEh0DLv2zaqWJnb+oFxlftDT0WFj/i98DJa74JgErgzZhzI5waUUQ52rYEuoiWN5KaCsP L1IDuRb0DIARcCWp8ANRzoBTScTDCf/bC6qqT3HnqCeX9OgOhRMr X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762889217618064715?= X-GMAIL-MSGID: =?utf-8?q?1762889217618064715?= Add the power domains exposed by RPMh in the Qualcomm SA8155P platform. Turns out they differ from SM8150. Signed-off-by: Konrad Dybcio --- drivers/soc/qcom/rpmhpd.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/drivers/soc/qcom/rpmhpd.c b/drivers/soc/qcom/rpmhpd.c index f20e2a49a669..63c35a32065b 100644 --- a/drivers/soc/qcom/rpmhpd.c +++ b/drivers/soc/qcom/rpmhpd.c @@ -342,6 +342,21 @@ static const struct rpmhpd_desc sm8150_desc = { .num_pds = ARRAY_SIZE(sm8150_rpmhpds), }; +static struct rpmhpd *sa8155p_rpmhpds[] = { + [SA8155P_CX] = &cx_w_mx_parent, + [SA8155P_CX_AO] = &cx_ao_w_mx_parent, + [SA8155P_EBI] = &ebi, + [SA8155P_GFX] = &gfx, + [SA8155P_MSS] = &mss, + [SA8155P_MX] = &mx, + [SA8155P_MX_AO] = &mx_ao, +}; + +static const struct rpmhpd_desc sa8155p_desc = { + .rpmhpds = sa8155p_rpmhpds, + .num_pds = ARRAY_SIZE(sa8155p_rpmhpds), +}; + /* SM8250 RPMH powerdomains */ static struct rpmhpd *sm8250_rpmhpds[] = { [SM8250_CX] = &cx_w_mx_parent, @@ -519,6 +534,7 @@ static const struct rpmhpd_desc sc8280xp_desc = { static const struct of_device_id rpmhpd_match_table[] = { { .compatible = "qcom,qdu1000-rpmhpd", .data = &qdu1000_desc }, + { .compatible = "qcom,sa8155p-rpmhpd", .data = &sa8155p_desc }, { .compatible = "qcom,sa8540p-rpmhpd", .data = &sa8540p_desc }, { .compatible = "qcom,sa8775p-rpmhpd", .data = &sa8775p_desc }, { .compatible = "qcom,sc7180-rpmhpd", .data = &sc7180_desc }, From patchwork Tue Apr 11 13:47:17 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 81982 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2603082vqo; Tue, 11 Apr 2023 07:07:50 -0700 (PDT) X-Google-Smtp-Source: AKy350b07IAo5m32bshFMHhMbcrubj9tExl+BTT87QDOypMdd7aRDTSLRU59XbOPdxX0ArAigGcH X-Received: by 2002:aa7:97a2:0:b0:637:2019:c04a with SMTP id d2-20020aa797a2000000b006372019c04amr7493861pfq.15.1681222070262; Tue, 11 Apr 2023 07:07:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681222070; cv=none; d=google.com; s=arc-20160816; b=bJL9ahYOTTGqHmXm9Wi+uTGaeZENmuTB6UHUuxPCqZq7CvrvAukx9MoMXSJDf2ozVh AEzSeyobFiloxbWON90CXst7eog7y1AOUnGrYS5lzx8kE7FXies1t8/H9LKc1f1/i9ra uOkSe1Gu5e7y4CUljNgT/F/AxERHsF/PJwwKL5fhRvoBG5fPixrrg9yw81kmpKuW3PE/ puoPjVj8gDgpdxIo+dodevzV+bq+XV15/KtacrrXwLk18oCzAmKb2PW/mKsi8yBnqO3d eZrl8EvXTgeRqUzUlxKVlDZ7dl4WgIYFhbgzRF6zdwiQ/QDsO2EBSDrGulJk5qsMtWXd ZRkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=lnOa1rnUIW+VOH2jrUKXRz6zTj4Kf4Fep5TGBDQYvsQ=; b=xkRwTmbReDukWQ7rQAz/vFRqYV2enYlJ+sDNyRadlhYhieCqx7btIypm09deEih4/N TLFqFRGOFJlvFwcDvp+0urd1TeQlNNgyMjW1UoADwBXx2a0NYdo5gzQbcu0OGSDSBh5A /nlI4wEQpEcN7WB286Euk/LWEfu+uSDC/Pwg1qK/y0qmX0BrwHz+JXP9VlHKkT3nDtOx 6EpibqjlnvN+3AC4yayQWVFD3k4HC+FXe34SEWwL8s8Q7XR/jX9ZmtbKzywfWEii9T0P gbql57q39KU6P856u91/WzpT+x+AKEyw6nmknSHd2pJaQnJ9pSwcsQBnuPG39hei7L4U 0hxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=k5dSAhm5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g25-20020a635659000000b00513234112a7si4990690pgm.883.2023.04.11.07.07.34; Tue, 11 Apr 2023 07:07:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=k5dSAhm5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230450AbjDKNrc (ORCPT + 99 others); Tue, 11 Apr 2023 09:47:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33826 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230305AbjDKNrZ (ORCPT ); Tue, 11 Apr 2023 09:47:25 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2F857196 for ; Tue, 11 Apr 2023 06:47:24 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id a29so9308495ljq.0 for ; Tue, 11 Apr 2023 06:47:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681220842; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=lnOa1rnUIW+VOH2jrUKXRz6zTj4Kf4Fep5TGBDQYvsQ=; b=k5dSAhm5qHMWnCH2FNZJ51zDDkW5l7jKxuKcwwGlLqCG9z9X8FeAxp3DVocNrWpUAz HeRV6hY8oD99WT26OLXsHK/v7fTEiIEc6DhEHtt0q+wVSYzRxOzYRA2xyD4pFdWzNtJM DkbwD1D6WV2ke3I9ns/rE2+Zt4MZhUM5cdnB0pPKCmfj9jLwcsQnOwmwTcJXgIvoiQ4O kBCugDzNdOp+S9pT4pP+to4dhveDhL5m6Ksy1YdxUK0dblmSgAOFfa+nflArPPelj39y W6S6zEpNzlD3g2HD0DJbLizz5FpZdGZDxPlt0S4tRkjk7RZl7VbT2UkXfms7XBkVkJKb tDVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681220842; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=lnOa1rnUIW+VOH2jrUKXRz6zTj4Kf4Fep5TGBDQYvsQ=; b=3veHcQuX04i46u5XtLNdwn4tNVNIBInclxXulYtvdflaeoBl4wpkmQXq05p9ZJ7xHr kP/SoBSvvrB20Lx9Vw7IZV7/vl8xJy5fO4P4NTP2kDwVGBm4w+XCxNW923X7KZqdDVm2 YK9lPyTUP9Mh4qkUqIt8DQSTanyd1d6M01SYd8EVP776SrxpyEYqa2GJGb0pFMH2g6qe 6eM9V4xsBl6ouXKGxpw5NjX+YxlbBGqx5UQpwv8B2N68DWEzmhR9ft6xdRyXGDDd5bgZ 9eShhaoLo3r0r0TfWO0zVvhSDKiE6u1iLNF0+ankCv74O9Dniv343RQkhSViaAEpGqmS nzLg== X-Gm-Message-State: AAQBX9fAmlpl/FmP2w+xV8jUOBUnHaFv8mPXrosRub/TcLIhR3i7z6J2 thaeF8kHeUX6RbJq5scUL7PfDg== X-Received: by 2002:a2e:920b:0:b0:2a7:7b5e:271 with SMTP id k11-20020a2e920b000000b002a77b5e0271mr651740ljg.24.1681220842452; Tue, 11 Apr 2023 06:47:22 -0700 (PDT) Received: from [192.168.1.101] (abxj23.neoplus.adsl.tpnet.pl. [83.9.3.23]) by smtp.gmail.com with ESMTPSA id c10-20020a2e680a000000b002a77583b718sm1245887lja.12.2023.04.11.06.47.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Apr 2023 06:47:22 -0700 (PDT) From: Konrad Dybcio Date: Tue, 11 Apr 2023 15:47:17 +0200 Subject: [PATCH v2 3/3] arm64: dts: qcom: Split out SA8155P and use correct RPMh power domains MIME-Version: 1.0 Message-Id: <20230411-topic-hanaau-v2-3-fd3d70844b31@linaro.org> References: <20230411-topic-hanaau-v2-0-fd3d70844b31@linaro.org> In-Reply-To: <20230411-topic-hanaau-v2-0-fd3d70844b31@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski Cc: Marijn Suijten , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski , Bhupesh Sharma , Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1681220837; l=2119; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=GTxTzfHDkLcCspsXqSwwuRYb2T4ZqC5yjZaaQlxphPk=; b=rGen8sT5XjdbxkaKlembBhwUlJG9cvFLwnBLZgGvlrDk0vTG0pSChCVlSvyincyAJApnpLzvzqmn bp5/4k1tC/1SmWyCyIDP9M4jbjGcJ8jKEswNLy7TL1/NKp5KaGBP X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762889113411905676?= X-GMAIL-MSGID: =?utf-8?q?1762889113411905676?= The RPMhPD setup on SA8155P is different compared to SM8150. Correct it to ensure the platform will not try accessing forbidden/missing RPMh entries at boot, as a bad vote will hang the machine. Signed-off-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/sa8155p-adp.dts | 2 +- arch/arm64/boot/dts/qcom/sa8155p.dtsi | 40 ++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/sa8155p-adp.dts b/arch/arm64/boot/dts/qcom/sa8155p-adp.dts index 339fea522509..15e1ae1c1a97 100644 --- a/arch/arm64/boot/dts/qcom/sa8155p-adp.dts +++ b/arch/arm64/boot/dts/qcom/sa8155p-adp.dts @@ -7,7 +7,7 @@ #include #include -#include "sm8150.dtsi" +#include "sa8155p.dtsi" #include "pmm8155au_1.dtsi" #include "pmm8155au_2.dtsi" diff --git a/arch/arm64/boot/dts/qcom/sa8155p.dtsi b/arch/arm64/boot/dts/qcom/sa8155p.dtsi new file mode 100644 index 000000000000..ffb7ab695213 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/sa8155p.dtsi @@ -0,0 +1,40 @@ +// SPDX-License-Identifier: BSD-3-Clause +/* + * Copyright (c) 2023, Linaro Limited + * + * SA8155P is an automotive variant of SM8150, with some minor changes. + * Most notably, the RPMhPD setup differs: MMCX and LCX/LMX rails are gone, + * though the cmd-db doesn't reflect that and access attemps result in a bite. + */ + +#include "sm8150.dtsi" + +&dispcc { + power-domains = <&rpmhpd SA8155P_CX>; +}; + +&mdss_dsi0 { + power-domains = <&rpmhpd SA8155P_CX>; +}; + +&mdss_dsi1 { + power-domains = <&rpmhpd SA8155P_CX>; +}; + +&mdss_mdp { + power-domains = <&rpmhpd SA8155P_CX>; +}; + +&remoteproc_slpi { + power-domains = <&rpmhpd SA8155P_CX>, + <&rpmhpd SA8155P_MX>; +}; + +&rpmhpd { + /* + * The bindings were crafted such that SA8155P PDs match their + * SM8150 counterparts to make it more maintainable and only + * necessitate adjusting entries that actually differ + */ + compatible = "qcom,sa8155p-rpmhpd"; +};