From patchwork Mon Feb 1 05:45:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bilal Wasim X-Patchwork-Id: 12058103 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=-13.7 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham 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 D67DEC433E6 for ; Mon, 1 Feb 2021 05:47:10 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 919CF64E15 for ; Mon, 1 Feb 2021 05:47:10 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 919CF64E15 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe :List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:To:From: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=r4kZ/OYk0Nn+nb/fz17EtuTaJ0hzyMTaUIRjpCf69yQ=; b=eZSGGoHgIgaoAyMdpYHxF7RfvX bXUv4KefOWbF67rkkWDWcETnxCs4vsWq5KBTzmp1nJs51RA8GnRZLhy4THSuxoil3XH/eF52QNbol qghF3BZznK+dr4YKTgHFAlK0D+1Oe9DocupXbn8Z2nMCjsDcJShsa6HltV4BRXbN0LFFUub7rMRPl cxTH3RDgSldm47wXbgdRS3uVQzGFqNQhHytrvOsY3PuzXqCp8y8ekky+uA9scKjqF22by+CGAG3TW 24OHRVxVuS5bEjGbROsGu3wN+MMLKMDhFEJZMcAcQmB4qRI44XuGc9p5ROQM+sQFxvr4j2CTaOXpy bf1QbUKg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l6S25-00060a-F3; Mon, 01 Feb 2021 05:45:53 +0000 Received: from mail-wr1-x436.google.com ([2a00:1450:4864:20::436]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1l6S1z-0005wu-Nd; Mon, 01 Feb 2021 05:45:48 +0000 Received: by mail-wr1-x436.google.com with SMTP id l12so15209138wry.2; Sun, 31 Jan 2021 21:45:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=9xqpeCBfVk8R05gxk9ASEmNGjJ7u5/VBiUnlJBQKPVA=; b=HeEiP4EKNiLQqx/eMp7WsrTlFOoIrvTk4jz31ZbAovOdGS9mO2+TsTuQgN0zsRIqtn YJYsh1fSX1tXL1PX56dwqQb16PHIkbvuAqJpQevRtdbqTYtbgWI65ddse4zgQcbh1UCV REQSDmjynovnXAV+5PC3xOei2iLreX67YQU9IP0FrN+F6hm99Fy129BzTlyWmbeQo3qJ g31GUYGJxoMviG6LpB6NZEctMJFj2391v4DsYv4l+1/I/T0f9tY6j8nNSjDhP9aN4W12 noYjZ7OZHkty7UZIqVnlYJ1hw+PI5AjG6jT0ujpS6btcgFVdjgFxAJR+zDPzMRbTABem lPlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=9xqpeCBfVk8R05gxk9ASEmNGjJ7u5/VBiUnlJBQKPVA=; b=QJW0nHPGKMsH4Bo8t3EPTqX108zgIpDxrrfNobB2Qu7YxZvlQPb0Zxb/5mCYvzfqpI 16qM5QZMz08WsvC4mRaVpLPGhXBBbCsnDApYOFN8avRJPOzLgKw/HYfcZBTa8Tu5lbQH orEeGPE5k+ZEUwfFrqgAspcFFK2qKr4GQDgf+wZK+OU+vnFaaihURcjPsnW4Q2EcuUsW 1E3TNVlaiXOPvcrxIVFWsr/6U1dPgKRcqHD5Zud9I0L7jGyQx/sH6Kmg06NLXvhG9rjA mrMzoca0bp7ZBgBnUxcyM3BWsYhGn+yrsdwBZEQT/lz2232Q6zz8ukGRqYohF5k7p1n5 fi1A== X-Gm-Message-State: AOAM530iHqFwM4PSSsEu8bd8XTBlSYSWZQuC599Bpt/vZ2494bZ64Tkm v02Q/MrU/SimulzII2hGqG6vw5/5aXKv4wqy X-Google-Smtp-Source: ABdhPJx5/3HJTSnShyp3E+2DkQGoHwNB07bsPh2NWECRc1vYO9mVW+Qbk+SioZbcANp+tj3990m7wA== X-Received: by 2002:adf:9f54:: with SMTP id f20mr5611294wrg.362.1612158344996; Sun, 31 Jan 2021 21:45:44 -0800 (PST) Received: from localhost.localdomain (cpc141888-watf13-2-0-cust663.15-2.cable.virginm.net. [86.14.42.152]) by smtp.googlemail.com with ESMTPSA id r25sm27123540wrr.64.2021.01.31.21.45.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 31 Jan 2021 21:45:44 -0800 (PST) From: Bilal Wasim X-Google-Original-From: Bilal Wasim To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, matthias.bgg@gmail.com, enric.balletbo@collabora.com, hsinyi@chromium.org, weiyi.lu@mediatek.com Subject: [PATCH 1/2] soc: mediatek: pm-domains: Use correct mask for bus_prot_clr Date: Mon, 1 Feb 2021 10:45:41 +0500 Message-Id: <20210201054542.1470695-2-Bilal.Wasim@imgtec.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210201054542.1470695-1-Bilal.Wasim@imgtec.com> References: <20210201054542.1470695-1-Bilal.Wasim@imgtec.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210201_004547_795392_FE4C4BC1 X-CRM114-Status: GOOD ( 12.86 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org When "bus_prot_reg_update" is false, the driver should use INFRA_TOPAXI_PROTECTEN for both setting and clearing the bus protection. However, the driver does not use this mask for clearing bus protection which causes failure when booting the imgtec gpu. Corrected and tested with mt8173 chromebook. Signed-off-by: Bilal Wasim Reviewed-by: Hsin-Yi Wang --- drivers/soc/mediatek/mtk-pm-domains.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soc/mediatek/mtk-pm-domains.h b/drivers/soc/mediatek/mtk-pm-domains.h index 141dc76054e6..7454c0b4f768 100644 --- a/drivers/soc/mediatek/mtk-pm-domains.h +++ b/drivers/soc/mediatek/mtk-pm-domains.h @@ -60,7 +60,7 @@ #define BUS_PROT_UPDATE_TOPAXI(_mask) \ BUS_PROT_UPDATE(_mask, \ INFRA_TOPAXI_PROTECTEN, \ - INFRA_TOPAXI_PROTECTEN_CLR, \ + INFRA_TOPAXI_PROTECTEN, \ INFRA_TOPAXI_PROTECTSTA1) struct scpsys_bus_prot_data { From patchwork Mon Feb 1 05:45:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bilal Wasim X-Patchwork-Id: 12058105 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=-13.7 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham 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 E4E8AC433DB for ; Mon, 1 Feb 2021 05:47:13 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A3F3C60C41 for ; Mon, 1 Feb 2021 05:47:13 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A3F3C60C41 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe :List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:To:From: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=yg5x5K0mJXxt2U2yh/95ngv+bUOHSTkCTQag6+CLZSQ=; b=ncH/h7x2Hx4mpZl37w3r7m4S9f lAC9FQTdL1FxwCMkLdJMX/JnhClufOJ6SnvwUt7/Wc/qwvTCZU6M1mzkda9edJLnWZ4pAXhCdKIPo YsUjG0jYCSrKxJYmC1rrazc5AnHdZ4pu2PqMUVyNWzPnBqrggUIyrkchmfskh4+rZN6hgY00x+1Y4 rzsJZyCSHpP+MqxECTV7qwQqkfwKLXNk0PdTjs9IEkuUtr9+b7d4oMz2P6NsZ2bK7ESKQy6J7NDRS sB4DDvx8xj06N89gn9VaoypFteyU6zUOz2LFDCYB1GFQZQQ9R6ZE1DOmld7VECth23rofPi0gsx+a KkcRiCNQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l6S2D-00063J-An; Mon, 01 Feb 2021 05:46:01 +0000 Received: from mail-wr1-x42a.google.com ([2a00:1450:4864:20::42a]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1l6S20-0005xB-IW; Mon, 01 Feb 2021 05:45:49 +0000 Received: by mail-wr1-x42a.google.com with SMTP id l12so15209153wry.2; Sun, 31 Jan 2021 21:45:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=A6nqzjnju0Qhug1o/Lp3c3yaK8vd09BbFSgR2jNN2os=; b=HUOIhEGcfxfn8L446WEypesTISgace3Zfj3t+CN+U/snn6XBaUek7PLugfoeumpQ+Z fG4zsr/ifmE8CcogDYGl3Da5H9HkEOrQRQBSwFN7yxjFdVjbEW8wlFrtEo2StbTI5V2Y AFCsf/caRliaM7KrrPshjo0+qUakjaOGzLSZCeyn8XhFLSKFxuqBd9ajLYl/1zre19Vu e10M3HnuiSz/Kns30zB99QcwxBQpwk/kfN2n5i5ZmRoDAK2YJL/r9Ekw15eoZWaj7qhl aAGjkHlRReIyR27VjmHgS+dTLNmAoHWchraYcK6TKt0L1H6Hh+3wKm4FMAWS8iYUEzb6 cvbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=A6nqzjnju0Qhug1o/Lp3c3yaK8vd09BbFSgR2jNN2os=; b=RKn65ULQhoXqt2Zof4s8UlTTmiL6CKmRpFfWHfvhDZQgPzKkCyhtvxtKH5ec6E2ukn 538XU4czcT5ffhiudROo/NhLIIs6uRMQMa4XCb3F7FfKUpTOO6u72MeKzhepFwGguSEG 7T23sax+O4aiMWf+SQjbDMZywni8FkYTMwG4IOBKlvxLMeLgIBnzVUc+Cpd53Q2nzMXm eEFy75jiCUedlscjKgFt2m0bMclogTcWjoK+wa+Y3oO8plqDWQptLXc2irK+LEiAAK9c 3sDmbnX3DGIS6k5oPnIfAUvV0SFTxKpMNax44yJMj1pxTws8gAJNvemc5k7s+4Wp41rs llbg== X-Gm-Message-State: AOAM531r81RYsVQUCpJrCboXacFMVnUQB8mDRciODhdOmszyIcI6tyfv pqgYcumrM4y4BNrj5qRUbptfqyktxJ+j5txR X-Google-Smtp-Source: ABdhPJwOxoNhyRFfFK7IapulMZIkG3cro5Uw/IVmbj1j9tqBC7WXrQU5KVCjAjt5m/pcL4Tu5cv/gQ== X-Received: by 2002:a5d:50c1:: with SMTP id f1mr16556956wrt.235.1612158345806; Sun, 31 Jan 2021 21:45:45 -0800 (PST) Received: from localhost.localdomain (cpc141888-watf13-2-0-cust663.15-2.cable.virginm.net. [86.14.42.152]) by smtp.googlemail.com with ESMTPSA id r25sm27123540wrr.64.2021.01.31.21.45.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 31 Jan 2021 21:45:45 -0800 (PST) From: Bilal Wasim X-Google-Original-From: Bilal Wasim To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, matthias.bgg@gmail.com, enric.balletbo@collabora.com, hsinyi@chromium.org, weiyi.lu@mediatek.com Subject: [PATCH 2/2] soc: mediatek: pm-domains: Add domain_supply cap for mfg_async PD Date: Mon, 1 Feb 2021 10:45:42 +0500 Message-Id: <20210201054542.1470695-3-Bilal.Wasim@imgtec.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210201054542.1470695-1-Bilal.Wasim@imgtec.com> References: <20210201054542.1470695-1-Bilal.Wasim@imgtec.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210201_004548_646723_D2762AE0 X-CRM114-Status: GOOD ( 11.33 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The mfg_async power domain in mt8173 is used to power up imgtec gpu. This domain requires the da9211 regulator to be enabled before the power domain can be enabled successfully. Signed-off-by: Bilal Wasim Reviewed-by: Hsin-Yi Wang Reported-by: kernel test robot --- drivers/soc/mediatek/mt8173-pm-domains.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/soc/mediatek/mt8173-pm-domains.h b/drivers/soc/mediatek/mt8173-pm-domains.h index 3e8ee5dabb43..065b8195e7d6 100644 --- a/drivers/soc/mediatek/mt8173-pm-domains.h +++ b/drivers/soc/mediatek/mt8173-pm-domains.h @@ -63,6 +63,7 @@ static const struct scpsys_domain_data scpsys_domain_data_mt8173[] = { .ctl_offs = SPM_MFG_ASYNC_PWR_CON, .sram_pdn_bits = GENMASK(11, 8), .sram_pdn_ack_bits = 0, + .caps = MTK_SCPD_DOMAIN_SUPPLY, }, [MT8173_POWER_DOMAIN_MFG_2D] = { .sta_mask = PWR_STATUS_MFG_2D,