aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/tilcdc/tilcdc_plane.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/tilcdc/tilcdc_plane.c')
-rw-r--r--drivers/gpu/drm/tilcdc/tilcdc_plane.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/gpu/drm/tilcdc/tilcdc_plane.c b/drivers/gpu/drm/tilcdc/tilcdc_plane.c
index 2f681a713815..389c80a5873c 100644
--- a/drivers/gpu/drm/tilcdc/tilcdc_plane.c
+++ b/drivers/gpu/drm/tilcdc/tilcdc_plane.c
@@ -21,48 +21,48 @@ static const struct drm_plane_funcs tilcdc_plane_funcs = {
};
static int tilcdc_plane_atomic_check(struct drm_plane *plane,
- struct drm_plane_state *state)
+ struct drm_plane_state *new_state)
{
struct drm_crtc_state *crtc_state;
struct drm_plane_state *old_state = plane->state;
unsigned int pitch;
- if (!state->crtc)
+ if (!new_state->crtc)
return 0;
- if (WARN_ON(!state->fb))
+ if (WARN_ON(!new_state->fb))
return -EINVAL;
- if (state->crtc_x || state->crtc_y) {
+ if (new_state->crtc_x || new_state->crtc_y) {
dev_err(plane->dev->dev, "%s: crtc position must be zero.",
__func__);
return -EINVAL;
}
- crtc_state = drm_atomic_get_existing_crtc_state(state->state,
- state->crtc);
+ crtc_state = drm_atomic_get_existing_crtc_state(new_state->state,
+ new_state->crtc);
/* we should have a crtc state if the plane is attached to a crtc */
if (WARN_ON(!crtc_state))
return 0;
- if (crtc_state->mode.hdisplay != state->crtc_w ||
- crtc_state->mode.vdisplay != state->crtc_h) {
+ if (crtc_state->mode.hdisplay != new_state->crtc_w ||
+ crtc_state->mode.vdisplay != new_state->crtc_h) {
dev_err(plane->dev->dev,
"%s: Size must match mode (%dx%d == %dx%d)", __func__,
crtc_state->mode.hdisplay, crtc_state->mode.vdisplay,
- state->crtc_w, state->crtc_h);
+ new_state->crtc_w, new_state->crtc_h);
return -EINVAL;
}
pitch = crtc_state->mode.hdisplay *
- state->fb->format->cpp[0];
- if (state->fb->pitches[0] != pitch) {
+ new_state->fb->format->cpp[0];
+ if (new_state->fb->pitches[0] != pitch) {
dev_err(plane->dev->dev,
"Invalid pitch: fb and crtc widths must be the same");
return -EINVAL;
}
- if (old_state->fb && state->fb->format != old_state->fb->format) {
+ if (old_state->fb && new_state->fb->format != old_state->fb->format) {
dev_dbg(plane->dev->dev,
"%s(): pixel format change requires mode_change\n",
__func__);