From mboxrd@z Thu Jan 1 00:00:00 1970 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 B6132EB64DC for ; Thu, 6 Jul 2023 12:35:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230195AbjGFMfJ (ORCPT ); Thu, 6 Jul 2023 08:35:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42062 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229501AbjGFMfH (ORCPT ); Thu, 6 Jul 2023 08:35:07 -0400 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 92DE51990 for ; Thu, 6 Jul 2023 05:35:06 -0700 (PDT) Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-3fbc59de009so6593155e9.3 for ; Thu, 06 Jul 2023 05:35:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20221208.gappssmtp.com; s=20221208; t=1688646905; x=1691238905; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=2lGRta1DFJWgP2Ka3XUK1qfLkVKYTy4OhAMOsxkgoyQ=; b=t9T2EPPp9hbOjIHqqad9elRw73dzrHEK2qBF+VJuC8f9Y3/9oMFx31mNw37w8ibwcy 52cdAg0Y7/Ozjn2LCoU9JJLD0kixWVjLFoeQwcSOWnSOGDJyiaHna6kf1NGSlP6EIHNB AWQQ573f791IbjtZMj4Pfai38KjablEBnkRW3fTVKJ9tmjDz+St1xrbdQjmcLwdKig/H wOIWU+6EHF/+4IvIFfRhyvcFdIwTfhJ5gK2gYQ4JfTH8N8yWiflC09nqE4vx2xuNmfLA W3KxngHtkuQWfYwyJN78GH7JZ3H3mggVoHkYCrGMzYmf0lEXaPqioQaGUnzRQqm6kN+g 3I5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688646905; x=1691238905; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=2lGRta1DFJWgP2Ka3XUK1qfLkVKYTy4OhAMOsxkgoyQ=; b=h5qqs8r3QVlehmoeY/z/eGV6GQXVa2QGiWZoxfS0CXbLblAncbTr8TjfHw/6vMnxlv +EsFYjIq1wEmdOyhKIISZ5kBIB3jygC3J67w1gdrlZfxg23ofQyvQU/8VmoSVOSnKq8w A/gQG09KQQgUFLxaRbT+/x7NGhkTbifXBPkpRRUdsxO269417SnJZ3JWKavIm5iGqe1m dEJlhxz6RboEULP8vKjcXPyaZ+xLM5/82nyDg0uNhcYKV48YhugTLj4Q6UYAdsGvqkoB +WRYxOB8nWcOYI255Kk4U3VkP9au/ylYChqbiKKZRuyJJsvBCPPEVee30R5pvOEHBRG6 DV0g== X-Gm-Message-State: ABy/qLY9/78b2YdHvZqYNLKO8cPoL8FC31HQcwY2HSbdo/WNY9x2aWgt VqgVFH3723sFwxPQ4O1KJo5IGQ== X-Google-Smtp-Source: APBJJlFztCovuW8wVvfjzKQVaVRs6Fs31fNA/tQYgjyyw5T1md8AvL7PKf82FqXbSOSfVivrPPxFsQ== X-Received: by 2002:a5d:618d:0:b0:30f:c7e4:d207 with SMTP id j13-20020a5d618d000000b0030fc7e4d207mr1293596wru.61.1688646904933; Thu, 06 Jul 2023 05:35:04 -0700 (PDT) Received: from [192.168.1.172] ([93.5.22.158]) by smtp.gmail.com with ESMTPSA id j14-20020a056000124e00b0031274a184d5sm1764357wrx.109.2023.07.06.05.35.03 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 06 Jul 2023 05:35:04 -0700 (PDT) Message-ID: <67e02d84-3b51-9973-225a-cf11fcd1aaf2@baylibre.com> Date: Thu, 6 Jul 2023 14:35:03 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH] arm64: dts: mediatek: mt8195: Fix PM suspend/resume with venc clocks Content-Language: en-US To: AngeloGioacchino Del Regno , matthias.bgg@gmail.com Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, yong.wu@mediatek.com, tinghan.shen@mediatek.com, weiyi.lu@mediatek.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, kernel@collabora.com References: <20230706095841.109315-1-angelogioacchino.delregno@collabora.com> From: Alexandre Mergnat In-Reply-To: <20230706095841.109315-1-angelogioacchino.delregno@collabora.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/07/2023 11:58, AngeloGioacchino Del Regno wrote: > Before suspending the LARBs we're making sure that any operation is > done: this never happens because we are unexpectedly unclocking the > LARB20 before executing the suspend handler for the MediaTek Smart > Multimedia Interface (SMI) and the cause of this is incorrect clocks > on this LARB. > > Fix this issue by changing the Local Arbiter 20 (used by the video > encoder secondary core) apb clock to CLK_VENC_CORE1_VENC; > furthermore, in order to make sure that both the PM resume and video > encoder operation is stable, add the CLK_VENC(_CORE1)_LARB clock to > the VENC (main core) and VENC_CORE1 power domains, as this IP cannot > communicate with the rest of the system (the AP) without local > arbiter clocks being operational. Reviewed-by: Alexandre Mergnat -- Regards, Alexandre From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5B048EB64DC for ; Thu, 6 Jul 2023 12:35:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: Content-Transfer-Encoding:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To:Subject: MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=OZE4hQRfFSBzlLd+1IOBxCpbRBOaNtIIfk1idOPYRUU=; b=YwOmuvMnufBktT RV0+9vGOGJ0gNcqsQGT7Im078KELfqLMGGbCnaE5/jkEeC5RIX9J2WK/gJziW7NJq7r7d+vWn6yEM 6231WxQ4GoAYITT3Ej/RHxb+M4PKOSqbTAQnVfAoXiP5ZydzCdl+vnpOjr88fQsRTHMKsN0oRm3t8 JtjrN7nDQXGqEG37NxJ0DIvirvLVhGweCeq2EXXuCPlhacsHomKKP4X9GxujOk6rsWfIMSa8wYTN+ Iid04HrlDqgxXiiyK0m9b4B/AavCFOP3yUbU3xFEAfqepC/37otYeAeeKN8H7Anqs/Jz6XEDrc4Tu R1zPVLDbPwqbndAumrQA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qHOCU-001eIG-2M; Thu, 06 Jul 2023 12:35:10 +0000 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qHOCR-001eGT-2T for linux-arm-kernel@lists.infradead.org; Thu, 06 Jul 2023 12:35:09 +0000 Received: by mail-wr1-x433.google.com with SMTP id ffacd0b85a97d-3141c3a7547so569316f8f.2 for ; Thu, 06 Jul 2023 05:35:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20221208.gappssmtp.com; s=20221208; t=1688646905; x=1691238905; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=2lGRta1DFJWgP2Ka3XUK1qfLkVKYTy4OhAMOsxkgoyQ=; b=t9T2EPPp9hbOjIHqqad9elRw73dzrHEK2qBF+VJuC8f9Y3/9oMFx31mNw37w8ibwcy 52cdAg0Y7/Ozjn2LCoU9JJLD0kixWVjLFoeQwcSOWnSOGDJyiaHna6kf1NGSlP6EIHNB AWQQ573f791IbjtZMj4Pfai38KjablEBnkRW3fTVKJ9tmjDz+St1xrbdQjmcLwdKig/H wOIWU+6EHF/+4IvIFfRhyvcFdIwTfhJ5gK2gYQ4JfTH8N8yWiflC09nqE4vx2xuNmfLA W3KxngHtkuQWfYwyJN78GH7JZ3H3mggVoHkYCrGMzYmf0lEXaPqioQaGUnzRQqm6kN+g 3I5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1688646905; x=1691238905; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=2lGRta1DFJWgP2Ka3XUK1qfLkVKYTy4OhAMOsxkgoyQ=; b=iOyu44+58rOyC0GO559eGe2TsOu+PVL1qv6DEkUfU/tkNWzOpybUXwyGtGATH5baet cehPYatdmBKO/WASlmwZlg/A9Kdu0CVrdmTjCA8JLu/PWmfGbqJrUGxTqwzGNqN2gusL kCbn7KjhjOxG0Lp7Duv1VDSeiNeRwtWzl8M5DXuSoJbqHsyF3y0M7fXe0+LZe9Zu6hg2 0srhsTYsPHZqvL+5q1iQ7hA/UystgVdPBJ/qEXU5CLevVIOZWjRoUVWksOO83o+jdUeu wKg3+PON92kVKpYDE3zinORwdOH+lfGSR8vX3fJo6EmgUFBGxSFHb/ZqRbdjwu160xaX OrGA== X-Gm-Message-State: ABy/qLb3+2l1KymWMSnhtXPEMjebKQszYANjeh9pay5qEBbsEFts3ZlX mv5DKHWIWCB2S6W2QIJ1HpeJ9R84BJ2H5zYqBmc= X-Google-Smtp-Source: APBJJlFztCovuW8wVvfjzKQVaVRs6Fs31fNA/tQYgjyyw5T1md8AvL7PKf82FqXbSOSfVivrPPxFsQ== X-Received: by 2002:a5d:618d:0:b0:30f:c7e4:d207 with SMTP id j13-20020a5d618d000000b0030fc7e4d207mr1293596wru.61.1688646904933; Thu, 06 Jul 2023 05:35:04 -0700 (PDT) Received: from [192.168.1.172] ([93.5.22.158]) by smtp.gmail.com with ESMTPSA id j14-20020a056000124e00b0031274a184d5sm1764357wrx.109.2023.07.06.05.35.03 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 06 Jul 2023 05:35:04 -0700 (PDT) Message-ID: <67e02d84-3b51-9973-225a-cf11fcd1aaf2@baylibre.com> Date: Thu, 6 Jul 2023 14:35:03 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH] arm64: dts: mediatek: mt8195: Fix PM suspend/resume with venc clocks Content-Language: en-US To: AngeloGioacchino Del Regno , matthias.bgg@gmail.com Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, yong.wu@mediatek.com, tinghan.shen@mediatek.com, weiyi.lu@mediatek.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, kernel@collabora.com References: <20230706095841.109315-1-angelogioacchino.delregno@collabora.com> From: Alexandre Mergnat In-Reply-To: <20230706095841.109315-1-angelogioacchino.delregno@collabora.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230706_053507_801534_2FD87915 X-CRM114-Status: GOOD ( 12.82 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 06/07/2023 11:58, AngeloGioacchino Del Regno wrote: > Before suspending the LARBs we're making sure that any operation is > done: this never happens because we are unexpectedly unclocking the > LARB20 before executing the suspend handler for the MediaTek Smart > Multimedia Interface (SMI) and the cause of this is incorrect clocks > on this LARB. > > Fix this issue by changing the Local Arbiter 20 (used by the video > encoder secondary core) apb clock to CLK_VENC_CORE1_VENC; > furthermore, in order to make sure that both the PM resume and video > encoder operation is stable, add the CLK_VENC(_CORE1)_LARB clock to > the VENC (main core) and VENC_CORE1 power domains, as this IP cannot > communicate with the rest of the system (the AP) without local > arbiter clocks being operational. Reviewed-by: Alexandre Mergnat -- Regards, Alexandre _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel