From patchwork Sat Oct 22 07:19:02 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 7192 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4242:0:0:0:0:0 with SMTP id s2csp1089457wrr; Sat, 22 Oct 2022 00:43:27 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6fQ0T33ztwiZWmL93MSy5oXHQR4kcnAcDOQRDZ8EE0pEc9cmYCiri3dguMeX3IKviJz6ZW X-Received: by 2002:aa7:810a:0:b0:55b:674d:d123 with SMTP id b10-20020aa7810a000000b0055b674dd123mr23831011pfi.52.1666424607507; Sat, 22 Oct 2022 00:43:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666424607; cv=none; d=google.com; s=arc-20160816; b=cuV9QDRLd4UwQDSqOvhjbLGFxjWfZXtHAgqz6TwU6BCVQRprGaM/zI3WLcQamJ1eH4 8Mqqlv2ztaqfyn/KFNWORyQUsO+vCd55Ep7MCO83YG8xZSR65nPBknDFU0H+yuSY2xCl iqsg6FTGB42H7eAAJr1oNbFusECONGtK1JQvzICJrgFehyahPV1R3G1elTOkxd4spIcq DSAZlOkpQ9H0pGGGZPCmRyxln8zuAxkJPQ5wA2fRuSmNLP6p8EuohwQr1oJA2KgKXMNf FEc2nuYxDxcS2T8+sFAufRqrQPNG69md+A5DCit6RnST7/sAOZ5bBTmAAyoLxFzKgkzS 5M6w== 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=Wf2h7nM5/2WZ+cZoV0KuWoKJth6XvQPMnYZvdgIF+3w=; b=tsMI+60B0MIJnFIjnSTNgpugtUYqF4k04cUG+E8V0gxk2h4VShXLYAitNtm5cMCZ/0 nhoyA6kVT+jDXXs6t6g4nN6y4uVBWosryv6+FBkS7rQ2mZLjFBPlVnBTvi3lijeExC/f NOh4q5et5qWxHOtbCDSKp7j5OD5aPUrejYMttDHAhISAPD9t6g6M7E0t8dqglcPr7XKe MgZmvhr5F8QyHjrwwq3lnH7qa/GqJnlPm9G5YD0wY1DEK4lVkX8aQMpC4QsH87hNly5g quubJYVR5wAKxfuIetdXAhCVndlOoKtIQD1aBlf2FBxebQXkEwiNDSEEncSiu8xx6g9g 7hOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=FpxxfuRk; 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 e128-20020a636986000000b00460a5961827si27651639pgc.651.2022.10.22.00.43.15; Sat, 22 Oct 2022 00:43:27 -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=FpxxfuRk; 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 S231279AbiJVHm4 (ORCPT + 99 others); Sat, 22 Oct 2022 03:42:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43010 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231127AbiJVHmP (ORCPT ); Sat, 22 Oct 2022 03:42:15 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [IPv6:2604:1380:40e1:4800::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 58AB6192999; Sat, 22 Oct 2022 00:40:41 -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 sin.source.kernel.org (Postfix) with ESMTPS id 107A8CE1D33; Sat, 22 Oct 2022 07:37:16 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2F4ACC433C1; Sat, 22 Oct 2022 07:37:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666424234; bh=1YuiLaIm3NwYdhiIKtcy3eB0YOyxO/hJJ4MIYrNFV1E=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FpxxfuRkmD2WYJ9HKpkgpWUbovef/NQLOcJNX+HoYwdShjBtGU7a1zvn6oBnq3uYJ GBJgKvJHDWbpXj1HAQkwIyqNhmM9PwZwiah2t2BELsyCldSm6B/iYnYvROY93I86iq bnvpUaljxgbM6acyos181mNwqhU4UGrkf13fnjQg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hamza Mahfooz , Alex Deucher Subject: [PATCH 5.19 063/717] Revert "drm/amdgpu: use dirty framebuffer helper" Date: Sat, 22 Oct 2022 09:19:02 +0200 Message-Id: <20221022072426.257868782@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221022072415.034382448@linuxfoundation.org> References: <20221022072415.034382448@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.3 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?1747372849237370078?= X-GMAIL-MSGID: =?utf-8?q?1747372849237370078?= 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 @@ -35,8 +35,6 @@ #include #include #include -#include -#include #include #include #include @@ -497,12 +495,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) { @@ -1077,10 +1069,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;