From patchwork Wed Oct 19 08:22:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 4566 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp204847wrs; Wed, 19 Oct 2022 01:47:31 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7C2n7u6qX4lq6RyR6HikbZ2aKWLP/62182Ogd1nJP4J3FNjYgQUbSocKFxluvmPnMPZn84 X-Received: by 2002:a17:90a:6883:b0:20a:d58b:d690 with SMTP id a3-20020a17090a688300b0020ad58bd690mr44624481pjd.241.1666169251685; Wed, 19 Oct 2022 01:47:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666169251; cv=none; d=google.com; s=arc-20160816; b=PphkjbjKZ1chMBHogKQoRYR9o0nofueHyvNoV8ze4DUojouDEOtb4B2WtdimI78tqE mP/lZp1tARLZswutD+pwNjbxL3beIvtnzbbSAmnGfKHRMljCQ0IgCbGmiDTGbdq14gP6 JQ+y1r/9oyc3Di03a4/0NwH23xaDephj07uplLL9J3dC9ByIqByDDJ/bQ8Lj4OabXubQ y5dT8dSJeHMFH1V/c9vrkMuC7UK9SEKtbsZmktCmNPlDEUasIfR6nHBeJ6I9HYskn0Xo wKuP47RprVON8jJstEBdihJK2oNyXbWIttJDgGMA+D8y1Tdrwu/mpY5Zy92rZ51nS2+a k77g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=m7THLKAQtE9miVW7RvCR+g9+bmTeQ2jR8Rt750+/Mfg=; b=hhMq5Whnjiluwe+MCqCKFPOkogDNL4HvniZ4kJ7AEGJqaBRY0TkDK1VEY9NDYBbtCB uALKJuqTxvzaDJavg/8FMBjFtm5JSuoc5eFf/G6SQByBzzccr9TDTDYnyZ1W8GO6uR5Z SwOYLgHAU5JeRalS6NYvcC3qMMQP8Vzei1iabkYq9eLFks8tbL//2qBQeLI1BD5Icx+3 QdZy0R51twoT2Iq9Batju2x/JKKLmYtWnoZkifvirpcv0imyDZUlXhvXPssPAXp9oLj7 muSXtbNS8u/C71Hrdmkn/m2DuYH7DGKU+bDsakHwSeFaq5M/9OfkUwPmNW+Xb7AYpHv9 M3gg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=KPBGNx11; 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=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t185-20020a6381c2000000b00437e609414dsi16822194pgd.563.2022.10.19.01.47.18; Wed, 19 Oct 2022 01:47:31 -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=@linuxfoundation.org header.s=korg header.b=KPBGNx11; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231444AbiJSIqy (ORCPT + 99 others); Wed, 19 Oct 2022 04:46:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44040 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231415AbiJSIpT (ORCPT ); Wed, 19 Oct 2022 04:45:19 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1863783204; Wed, 19 Oct 2022 01:43:56 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 83F16B82256; Wed, 19 Oct 2022 08:40:57 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id ECF34C433D6; Wed, 19 Oct 2022 08:40:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666168856; bh=J4GXFMdeRLZix8AZSV4/nBwMjiWe1xjgzdQTqZP/uF0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KPBGNx11kGqhHHgvIynAmBOxJ23NFj3rkwCYbiA39eBRkSdJVx3JA4M3hMzydJW2M TDrt64JHrdTyekVCevszTV6AHl4F33b1nHcpj8B3svMeTfVoIRzN9rntPbdlU9QUnU f2npV52gcTugcECeptU4XzhzDXo0s4v4k+/hFuBE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hamza Mahfooz , Alex Deucher Subject: [PATCH 6.0 069/862] Revert "drm/amdgpu: use dirty framebuffer helper" Date: Wed, 19 Oct 2022 10:22:36 +0200 Message-Id: <20221019083252.970352308@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221019083249.951566199@linuxfoundation.org> References: <20221019083249.951566199@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham 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?1747105088982863380?= X-GMAIL-MSGID: =?utf-8?q?1747105088982863380?= From: Hamza Mahfooz commit 17d819e2828cacca2e4c909044eb9798ed379cd2 upstream. This reverts commit 66f99628eb24409cb8feb5061f78283c8b65f820. Unfortunately, that commit causes performance regressions on non-PSR setups. So, just revert it until FB_DAMAGE_CLIPS support can be added. Cc: stable@vger.kernel.org Link: https://gitlab.freedesktop.org/drm/amd/-/issues/2189 Link: https://bugzilla.kernel.org/show_bug.cgi?id=216554 Fixes: 66f99628eb2440 ("drm/amdgpu: use dirty framebuffer helper") Fixes: abbc7a3dafb91b ("drm/amdgpu: don't register a dirty callback for non-atomic") Signed-off-by: Hamza Mahfooz Acked-by: Alex Deucher Signed-off-by: Alex Deucher Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c @@ -38,8 +38,6 @@ #include #include #include -#include -#include #include #include #include @@ -500,12 +498,6 @@ static const struct drm_framebuffer_func .create_handle = drm_gem_fb_create_handle, }; -static const struct drm_framebuffer_funcs amdgpu_fb_funcs_atomic = { - .destroy = drm_gem_fb_destroy, - .create_handle = drm_gem_fb_create_handle, - .dirty = drm_atomic_helper_dirtyfb, -}; - uint32_t amdgpu_display_supported_domains(struct amdgpu_device *adev, uint64_t bo_flags) { @@ -1108,10 +1100,8 @@ static int amdgpu_display_gem_fb_verify_ if (ret) goto err; - if (drm_drv_uses_atomic_modeset(dev)) - ret = drm_framebuffer_init(dev, &rfb->base, &amdgpu_fb_funcs_atomic); - else - ret = drm_framebuffer_init(dev, &rfb->base, &amdgpu_fb_funcs); + ret = drm_framebuffer_init(dev, &rfb->base, &amdgpu_fb_funcs); + if (ret) goto err;