Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 58208b76 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "drm/msm/sde: fix scaler validation in crtc atomic check"

parents 900e7da4 85c4012b
Loading
Loading
Loading
Loading
+7 −6
Original line number Diff line number Diff line
@@ -2470,13 +2470,14 @@ static int _sde_atomic_check_decimation_scaler(struct drm_plane_state *state,
	}

	/* check max scaler capability */
	else if (((src_deci_w * max_upscale) < dst->w) ||
		((src_deci_h * max_upscale) < dst->h) ||
		((dst->w * max_downscale) < src_deci_w) ||
		((dst->h * max_downscale) < src_deci_h)) {
	else if (((scaler_src_w * max_upscale) < dst->w) ||
		((scaler_src_h * max_upscale) < dst->h) ||
		((dst->w * max_downscale) < scaler_src_w) ||
		((dst->h * max_downscale) < scaler_src_h)) {
		SDE_ERROR_PLANE(psde,
			"too much scaling requested %ux%u->%ux%u\n",
			src_deci_w, src_deci_h, dst->w, dst->h);
			"too much scaling requested %ux%u->%ux%u rot:%d\n",
			scaler_src_w, scaler_src_h, dst->w, dst->h,
			inline_rotation);
		ret = -E2BIG;
	} else if (_sde_plane_validate_scaler_v2(psde, pstate, fmt,
				width, height,