lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20251007054528.2900905-6-suraj.kandpal@intel.com>
Date: Tue,  7 Oct 2025 11:15:27 +0530
From: Suraj Kandpal <suraj.kandpal@...el.com>
To: linux-arm-msm@...r.kernel.org,
	freedreno@...ts.freedesktop.org,
	dri-devel@...ts.freedesktop.org,
	intel-xe@...ts.freedesktop.org,
	intel-gfx@...ts.freedesktop.org,
	kernel-list@...pberrypi.com,
	amd-gfx@...ts.freedesktop.org,
	linux-kernel@...r.kernel.org,
	linux-renesas-soc@...r.kernel.org
Cc: dmitry.baryshkov@....qualcomm.com,
	ankit.k.nautiyal@...el.com,
	arun.r.murthy@...el.com,
	uma.shankar@...el.com,
	jani.nikula@...el.com,
	harry.wentland@....com,
	siqueira@...lia.com,
	alexander.deucher@....com,
	christian.koenig@....com,
	airlied@...il.com,
	simona@...ll.ch,
	liviu.dudau@....com,
	maarten.lankhorst@...ux.intel.com,
	mripard@...nel.org,
	robin.clark@....qualcomm.com,
	abhinav.kumar@...ux.dev,
	tzimmermann@...e.de,
	jessica.zhang@....qualcomm.com,
	sean@...rly.run,
	marijn.suijten@...ainline.org,
	laurent.pinchart+renesas@...asonboard.com,
	mcanal@...lia.com,
	dave.stevenson@...pberrypi.com,
	tomi.valkeinen+renesas@...asonboard.com,
	kieran.bingham+renesas@...asonboard.com,
	louis.chauvet@...tlin.com,
	Suraj Kandpal <suraj.kandpal@...el.com>
Subject: [PATCH v2 5/7] drm: writeback: Modify params for drm_writeback_get_out_fence

Use drm_connector instead of drm_writeback_connector since it now
resides within drm_connector and also helps make sure
drm_wrtieback_connector is being modified mostly by drm core
provided helpers.

Signed-off-by: Suraj Kandpal <suraj.kandpal@...el.com>
---
V1 -> V2: Use &connector->writeback (Dmitry)
---
 drivers/gpu/drm/drm_atomic_uapi.c | 4 +---
 drivers/gpu/drm/drm_writeback.c   | 6 +++---
 include/drm/drm_writeback.h       | 2 +-
 3 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/drivers/gpu/drm/drm_atomic_uapi.c b/drivers/gpu/drm/drm_atomic_uapi.c
index a102738a8733..c38dfc61fb88 100644
--- a/drivers/gpu/drm/drm_atomic_uapi.c
+++ b/drivers/gpu/drm/drm_atomic_uapi.c
@@ -1271,7 +1271,6 @@ static int prepare_signaling(struct drm_device *dev,
 	}
 
 	for_each_new_connector_in_state(state, conn, conn_state, i) {
-		struct drm_writeback_connector *wb_conn;
 		struct drm_out_fence_state *f;
 		struct dma_fence *fence;
 		s32 __user *fence_ptr;
@@ -1293,8 +1292,7 @@ static int prepare_signaling(struct drm_device *dev,
 		f[*num_fences].out_fence_ptr = fence_ptr;
 		*fence_state = f;
 
-		wb_conn = &conn->writeback;
-		fence = drm_writeback_get_out_fence(wb_conn);
+		fence = drm_writeback_get_out_fence(conn);
 		if (!fence)
 			return -ENOMEM;
 
diff --git a/drivers/gpu/drm/drm_writeback.c b/drivers/gpu/drm/drm_writeback.c
index da7be54f5b13..da2acb932ac0 100644
--- a/drivers/gpu/drm/drm_writeback.c
+++ b/drivers/gpu/drm/drm_writeback.c
@@ -529,11 +529,11 @@ drm_writeback_signal_completion(struct drm_connector *connector,
 EXPORT_SYMBOL(drm_writeback_signal_completion);
 
 struct dma_fence *
-drm_writeback_get_out_fence(struct drm_writeback_connector *wb_connector)
+drm_writeback_get_out_fence(struct drm_connector *connector)
 {
 	struct dma_fence *fence;
-	struct drm_connector *connector =
-		drm_writeback_to_connector(wb_connector);
+	struct drm_writeback_connector *wb_connector =
+		&connector->writeback;
 
 	if (WARN_ON(connector->connector_type !=
 		    DRM_MODE_CONNECTOR_WRITEBACK))
diff --git a/include/drm/drm_writeback.h b/include/drm/drm_writeback.h
index 5e8ab51c2da4..2afa48ea7c00 100644
--- a/include/drm/drm_writeback.h
+++ b/include/drm/drm_writeback.h
@@ -104,5 +104,5 @@ drm_writeback_signal_completion(struct drm_connector *connector,
 				int status);
 
 struct dma_fence *
-drm_writeback_get_out_fence(struct drm_writeback_connector *wb_connector);
+drm_writeback_get_out_fence(struct drm_connector *connector);
 #endif
-- 
2.34.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ