Unverified Commit 46064348 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!14161 drm/rockchip: vop: Fix a dereferenced before check warning

parents 6a6a6975 5e1ca6e3
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -1076,10 +1076,10 @@ static int vop_plane_atomic_async_check(struct drm_plane *plane,
	if (!plane->state->fb)
		return -EINVAL;

	if (state)
		crtc_state = drm_atomic_get_existing_crtc_state(state,
								new_plane_state->crtc);
	else /* Special case for asynchronous cursor updates. */
	crtc_state = drm_atomic_get_existing_crtc_state(state, new_plane_state->crtc);

	/* Special case for asynchronous cursor updates. */
	if (!crtc_state)
		crtc_state = plane->crtc->state;

	return drm_atomic_helper_check_plane_state(plane->state, crtc_state,