From patchwork Thu May 26 08:34:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaron Ma X-Patchwork-Id: 1635766 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=QnBQiFw/; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4L81Tg5M8wz9s75 for ; Thu, 26 May 2022 18:35:18 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1nu8xZ-0004ZT-S6; Thu, 26 May 2022 08:35:09 +0000 Received: from smtp-relay-canonical-0.internal ([10.131.114.83] helo=smtp-relay-canonical-0.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1nu8xY-0004Y9-5h for kernel-team@lists.ubuntu.com; Thu, 26 May 2022 08:35:08 +0000 Received: from localhost.localdomain (unknown [222.129.35.96]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-0.canonical.com (Postfix) with ESMTPSA id C18953F5FD for ; Thu, 26 May 2022 08:35:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1653554108; bh=IlKkbJds2/59rDY1RENCNqJs1A275+zLiXaROUjF4hI=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=QnBQiFw/gDzqs18XcGCNC4EyK4PjE9yIEarWrH4NPP6lmyIn2ajjDY72oqOjtSgcG P/8+6QckDFCQ/zk32EmLpqAIqsn5bQeylTjCnyP5qOCkSoOp9fgYPxP/zwFm674Y+Q N2ok97EwOFUGPmfuWiktWZf/QOsllEAncxFsh+U2ym5c0u1DYATi/wtGD+vSLqp/ol 8zWMsi7FMhcm6vz0l7hvAiwS/+C0fQemtKywlxGmC0SmE0Nx6c4ul9f8MRu2+1ReuL ++6qjHwLd2mGFpnX/wZaVHuKmXXD5fFECkG1G9SPzzVFhgEyWEiwqFIrvbcYP2CvB8 DSjJuyHJxYNFA== From: Aaron Ma To: kernel-team@lists.ubuntu.com Subject: [OEM-5.14/J][PATCH 1/2] Revert "drm/amd/pm: keep the BACO feature enabled for suspend" Date: Thu, 26 May 2022 16:34:57 +0800 Message-Id: <20220526083458.321813-2-aaron.ma@canonical.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220526083458.321813-1-aaron.ma@canonical.com> References: <20220526083458.321813-1-aaron.ma@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: Alex Deucher BugLink: https://bugs.launchpad.net/bugs/1975804 This reverts commit eaa090538e8d21801c6d5f94590c3799e6a528b5. Commit ebc002e3ee78 ("drm/amdgpu: don't use BACO for reset in S3") stops using BACO for reset during suspend, so it's no longer necessary to leave BACO enabled during suspend. This fixes resume from suspend on the navy flounder dGPU in the ASUS ROG Strix G513QY. Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/2008 Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1982 Reviewed-by: Lijo Lazar Reviewed-by: Mario Limonciello Signed-off-by: Alex Deucher Cc: stable@vger.kernel.org (cherry picked from commit a56f445f807b0276fc0660c330bf93a9ea78e8ea) Signed-off-by: Aaron Ma --- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c index 730c16e956ad4..8aacc6c97dca4 100644 --- a/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c +++ b/drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c @@ -1363,14 +1363,8 @@ static int smu_disable_dpms(struct smu_context *smu) { struct amdgpu_device *adev = smu->adev; int ret = 0; - /* - * TODO: (adev->in_suspend && !adev->in_s0ix) is added to pair - * the workaround which always reset the asic in suspend. - * It's likely that workaround will be dropped in the future. - * Then the change here should be dropped together. - */ bool use_baco = !smu->is_apu && - (((amdgpu_in_reset(adev) || (adev->in_suspend && !adev->in_s0ix)) && + ((amdgpu_in_reset(adev) && (amdgpu_asic_reset_method(adev) == AMD_RESET_METHOD_BACO)) || ((adev->in_runpm || adev->in_s4) && amdgpu_asic_supports_baco(adev)));