From patchwork Thu Jan 19 06:31:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AceLan Kao X-Patchwork-Id: 1728579 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.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=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=mBDxq3mp; dkim-atps=neutral Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NyCTY3Pbwz23h6 for ; Thu, 19 Jan 2023 17:32:00 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1pIOSg-0004E1-88; Thu, 19 Jan 2023 06:31:46 +0000 Received: from mail-pf1-f176.google.com ([209.85.210.176]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1pIOSd-0004Dd-Ht for kernel-team@lists.ubuntu.com; Thu, 19 Jan 2023 06:31:43 +0000 Received: by mail-pf1-f176.google.com with SMTP id w2so718122pfc.11 for ; Wed, 18 Jan 2023 22:31:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=vmaGyY4Q8uFWycCTaPWPs8PNaRfQ9EYtNY138QfzD7Q=; b=mBDxq3mpbho5LxqiCZCp3sV98zmUP5cG82jJlFqwMhvya3uudHi6pf6MfdAaUE34nq Zy7RirsTvINwP9FBwHgwjJ6oi3392b8w7hOyMIvOzxgyoxQkoHB9WRjYxAtlGgSHjeue ZFBXET/ZhFFdGxOt0YGg2w0YbBeEhRODt0QEzkRjIUSUsb9LoE7VSrv4ueUTVuex5e05 dmCUwCAoNK5TeVY1M1teR0WM4y3uWfDK/ZEmmtGhr8gZNmsqBAFaaM2NUq5o7Tt10rAA tc3/wonNxNk7UDpBE/AypvOzRdAXtgyinT+X2BoAmZzyFVOJ5K/+MDwgLZNdTWuKtsB8 dXiw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:sender:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=vmaGyY4Q8uFWycCTaPWPs8PNaRfQ9EYtNY138QfzD7Q=; b=rTJL5Y3OC+hEfwqpN7TJ7XLhZm0kbZnQNv0JA/bZTft1CQ1BIzE8kmJOJ7Mlp+zwZu GjQxC5duUiJ1SninioWt9FNfwvNtnOoa61MUDxMFXSOL3hedqrTykGrOTJrYGPDsM74A 7rWd7wV+p0lqM4W6t/mwJ7GWPRnj807QGJjSRbkZ0dBt9Jq0/76YcyEHlpL7LWoOC7UN f7bIesaF+oLjrotSvAqBLY5UEb4Znq4j+MDzuTpVSqaxVr/5VmbwC8wc0y/99tsylRQb +VFTSfvXtkDjc96K//udLQ4B5Uorxz4xCqGjOJF5qauom4pcNf2w2SW0yamv/ActW4Ry sY8A== X-Gm-Message-State: AFqh2kr/lH5U2pbrKjIdZR3dy1Ta34XAmb3ZKlxxVIfU000bwlScn900 fK43YZIq4nJMQf/nh0Q1bZNuJbbgnG4= X-Google-Smtp-Source: AMrXdXurpBkFsVL1WG+3llniIZjiq1ra5wZGm1FflYSELHWOEu96mS1VsYvy5Sno0o44B5j0C651+A== X-Received: by 2002:a62:63c6:0:b0:576:ddd4:6a02 with SMTP id x189-20020a6263c6000000b00576ddd46a02mr10138999pfb.22.1674109901653; Wed, 18 Jan 2023 22:31:41 -0800 (PST) Received: from localhost (211-75-139-217.hinet-ip.hinet.net. [211.75.139.217]) by smtp.gmail.com with ESMTPSA id r15-20020aa79ecf000000b0056c2e497b02sm7907068pfq.173.2023.01.18.22.31.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Jan 2023 22:31:41 -0800 (PST) From: AceLan Kao To: kernel-team@lists.ubuntu.com Subject: [PATCH 1/1][SRU][OEM-5.17] Revert "drm/amdgpu: make sure to init common IP before gmc" Date: Thu, 19 Jan 2023 14:31:37 +0800 Message-Id: <20230119063137.92490-2-acelan.kao@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230119063137.92490-1-acelan.kao@canonical.com> References: <20230119063137.92490-1-acelan.kao@canonical.com> MIME-Version: 1.0 Received-SPF: pass client-ip=209.85.210.176; envelope-from=acelan@gmail.com; helo=mail-pf1-f176.google.com 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: "Chia-Lin Kao (AceLan)" BugLink: https://launchpad.net/bugs/2002467 This reverts commit 224dffc89a957e2f006de3202d12c09bf348f992. This commit introduce an regression leads to the eDP turns black after bootup. --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index ce352aad42ff3..7956089ed95a3 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c @@ -2357,16 +2357,8 @@ static int amdgpu_device_ip_init(struct amdgpu_device *adev) } adev->ip_blocks[i].status.sw = true; - if (adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_COMMON) { - /* need to do common hw init early so everything is set up for gmc */ - r = adev->ip_blocks[i].version->funcs->hw_init((void *)adev); - if (r) { - DRM_ERROR("hw_init %d failed %d\n", i, r); - goto init_failed; - } - adev->ip_blocks[i].status.hw = true; - } else if (adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_GMC) { - /* need to do gmc hw init early so we can allocate gpu mem */ + /* need to do gmc hw init early so we can allocate gpu mem */ + if (adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_GMC) { /* Try to reserve bad pages early */ if (amdgpu_sriov_vf(adev)) amdgpu_virt_exchange_data(adev); @@ -3024,8 +3016,8 @@ static int amdgpu_device_ip_reinit_early_sriov(struct amdgpu_device *adev) int i, r; static enum amd_ip_block_type ip_order[] = { - AMD_IP_BLOCK_TYPE_COMMON, AMD_IP_BLOCK_TYPE_GMC, + AMD_IP_BLOCK_TYPE_COMMON, AMD_IP_BLOCK_TYPE_PSP, AMD_IP_BLOCK_TYPE_IH, };