From patchwork Tue Aug 23 11:29:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 12951971 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 8051AC32772 for ; Tue, 23 Aug 2022 11:31:08 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 9F7E411A7EE; Tue, 23 Aug 2022 11:31:06 +0000 (UTC) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3077F11AF07; Tue, 23 Aug 2022 11:30:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1661254251; x=1692790251; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=2HOoJcm20SZkyrXYw1/MfDsWZQF/it67HYYyFCWAIU8=; b=Bam4fZZsahjcQ5TKTB5OulL4aEvEuiJ0TMO3luvkqvDewAju8ckjfZwR 0FTtnHO9oW6TMAPR0uVRq56/RJ1Uiqw5zg2SqPzi7ilvd55otiJB0Gcg3 oLaxZaCbovcd0v2aaRvMFLDqOUe0UQyxLUwgC2MltED4bJPT/plvZqDJW 3iGgnlSJxFzig3NR294TgVqujiRw8jfmgmd8L9bHj+PR5iz1YvBhZWXtF pPh+Fr3B2JwlCwDkCKxmj6XG+aFrFWrpat9KrrXx7nzWxGuKZBXxFfaTj NTdnuE9ECMiWFMZX0r51z7s13We2j9zamZ8TYDp2MFQEK9jeA7PKfsyOG A==; X-IronPort-AV: E=McAfee;i="6500,9779,10447"; a="379953313" X-IronPort-AV: E=Sophos;i="5.93,257,1654585200"; d="scan'208";a="379953313" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Aug 2022 04:30:48 -0700 X-IronPort-AV: E=Sophos;i="5.93,257,1654585200"; d="scan'208";a="669990847" Received: from fjohn-mobl.ger.corp.intel.com (HELO jhogande-mobl1.ger.corp.intel.com) ([10.249.42.156]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Aug 2022 04:30:46 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org Subject: [PATCH v2 0/4] Fixes for damage clips handling Date: Tue, 23 Aug 2022 14:29:16 +0300 Message-Id: <20220823112920.352563-1-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jani Nikula , Daniel Vetter , =?utf-8?q?Jos=C3=A9_Roberto_de_Souz?= =?utf-8?q?a?= , =?utf-8?q?Ma=C3=ADra_Canal?= , Mika Kahola , =?utf-8?q?Jouni_H=C3=B6gander?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Currently damage clips handling is broken for planes when using big framebuffer + offset in case kms driver adjusts drm_plane_state.src coords. This is because damage clips are using coords relative to original coords from user-space. This patchset is fixing this by using original coords from user-space instead of drm_plane_state.src when iterating damage_clips. v2: Modify drm unit tests accordingly Cc: Daniel Vetter Cc: Maarten Lankhorst Cc: Jani Nikula Cc: Ville Syrjälä Cc: José Roberto de Souza Cc: Mika Kahola Cc: Maíra Canal Jouni Högander (4): drm: Use original src rect while initializing damage iterator drm/i915/display: Use original src in psr2 sel fetch area calculation drm/i915/display: Use drm helper instead of own loop for damage clips drm/tests: Set also mock plane src_x, src_y, src_w and src_h drivers/gpu/drm/drm_damage_helper.c | 11 ++++++---- drivers/gpu/drm/i915/display/intel_psr.c | 20 +++++++------------ .../gpu/drm/tests/drm_damage_helper_test.c | 5 +++++ 3 files changed, 19 insertions(+), 17 deletions(-)