mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH next] drm/tests: Fix a test in drm_test_check_valid_clones()
@ 2025-02-12 15:24 Dan Carpenter
  2025-02-13  8:56 ` Maxime Ripard
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2025-02-12 15:24 UTC (permalink / raw)
  To: Jessica Zhang
  Cc: Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann,
	David Airlie, Simona Vetter, Dmitry Baryshkov, Abhinav Kumar,
	dri-devel, linux-kernel, kernel-janitors

The drm_atomic_get_crtc_state() function returns error pointers and not
NULL.  Update the check to check for error pointers as well as NULL.

Fixes: 88849f24e2ab ("drm/tests: Add test for drm_atomic_helper_check_modeset()")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
---
 drivers/gpu/drm/tests/drm_atomic_state_test.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/tests/drm_atomic_state_test.c b/drivers/gpu/drm/tests/drm_atomic_state_test.c
index 0ab5d9ec4a75..5945c3298901 100644
--- a/drivers/gpu/drm/tests/drm_atomic_state_test.c
+++ b/drivers/gpu/drm/tests/drm_atomic_state_test.c
@@ -283,7 +283,7 @@ static void drm_test_check_valid_clones(struct kunit *test)
 	KUNIT_ASSERT_NOT_ERR_OR_NULL(test, state);
 
 	crtc_state = drm_atomic_get_crtc_state(state, priv->crtc);
-	KUNIT_ASSERT_NOT_NULL(test, crtc_state);
+	KUNIT_ASSERT_NOT_ERR_OR_NULL(test, crtc_state);
 
 	crtc_state->encoder_mask = param->encoder_mask;
 
-- 
2.47.2


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH next] drm/tests: Fix a test in drm_test_check_valid_clones()
  2025-02-12 15:24 [PATCH next] drm/tests: Fix a test in drm_test_check_valid_clones() Dan Carpenter
@ 2025-02-13  8:56 ` Maxime Ripard
  0 siblings, 0 replies; 2+ messages in thread
From: Maxime Ripard @ 2025-02-13  8:56 UTC (permalink / raw)
  To: Jessica Zhang, Dan Carpenter
  Cc: Maxime Ripard, Maarten Lankhorst, Thomas Zimmermann,
	David Airlie, Simona Vetter, Dmitry Baryshkov, Abhinav Kumar,
	dri-devel, linux-kernel, kernel-janitors

On Wed, 12 Feb 2025 18:24:09 +0300, Dan Carpenter wrote:
> The drm_atomic_get_crtc_state() function returns error pointers and not
> NULL.  Update the check to check for error pointers as well as NULL.
> 
> 

Applied to misc/kernel.git (drm-misc-next).

Thanks!
Maxime

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-02-13  8:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-02-12 15:24 [PATCH next] drm/tests: Fix a test in drm_test_check_valid_clones() Dan Carpenter
2025-02-13  8:56 ` Maxime Ripard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®