diff mbox

[7/7] drm/i915: Drop unused position fields

Message ID 1415904206-22548-8-git-send-email-matthew.d.roper@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Matt Roper Nov. 13, 2014, 6:43 p.m. UTC
The userspace-requested plane coordinates are now stored in
plane->state.base (and the i915-adjusted values are stored in
plane->state), so we no longer use the coordinate fields in intel_plane
or the orig_{src,dst} fields in intel_plane_state.  Drop them.

Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
---
 drivers/gpu/drm/i915/intel_display.c | 16 ----------------
 drivers/gpu/drm/i915/intel_drv.h     |  6 ------
 drivers/gpu/drm/i915/intel_sprite.c  |  8 --------
 3 files changed, 30 deletions(-)

Comments

Paauwe, Bob J Nov. 13, 2014, 9:28 p.m. UTC | #1
On Thu, 13 Nov 2014 10:43:26 -0800
Matt Roper <matthew.d.roper@intel.com> wrote:

> The userspace-requested plane coordinates are now stored in
> plane->state.base (and the i915-adjusted values are stored in
> plane->state), so we no longer use the coordinate fields in intel_plane
> or the orig_{src,dst} fields in intel_plane_state.  Drop them.
> 
> Signed-off-by: Matt Roper <matthew.d.roper@intel.com>

Reviewed-by: Bob Paauwe <bob.j.paauwe@intel.com>

> ---
>  drivers/gpu/drm/i915/intel_display.c | 16 ----------------
>  drivers/gpu/drm/i915/intel_drv.h     |  6 ------
>  drivers/gpu/drm/i915/intel_sprite.c  |  8 --------
>  3 files changed, 30 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 8d5a3b4..a595a58 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -11526,14 +11526,6 @@ intel_commit_primary_plane(struct drm_plane *plane,
>  	crtc->x = src->x1;
>  	crtc->y = src->y1;
>  
> -	intel_plane->crtc_x = state->orig_dst.x1;
> -	intel_plane->crtc_y = state->orig_dst.y1;
> -	intel_plane->crtc_w = drm_rect_width(&state->orig_dst);
> -	intel_plane->crtc_h = drm_rect_height(&state->orig_dst);
> -	intel_plane->src_x = state->orig_src.x1;
> -	intel_plane->src_y = state->orig_src.y1;
> -	intel_plane->src_w = drm_rect_width(&state->orig_src);
> -	intel_plane->src_h = drm_rect_height(&state->orig_src);
>  	intel_plane->obj = obj;
>  
>  	if (intel_crtc->active) {
> @@ -11748,14 +11740,6 @@ intel_commit_cursor_plane(struct drm_plane *plane,
>  	crtc->cursor_x = state->base.crtc_x;
>  	crtc->cursor_y = state->base.crtc_y;
>  
> -	intel_plane->crtc_x = state->orig_dst.x1;
> -	intel_plane->crtc_y = state->orig_dst.y1;
> -	intel_plane->crtc_w = drm_rect_width(&state->orig_dst);
> -	intel_plane->crtc_h = drm_rect_height(&state->orig_dst);
> -	intel_plane->src_x = state->orig_src.x1;
> -	intel_plane->src_y = state->orig_src.y1;
> -	intel_plane->src_w = drm_rect_width(&state->orig_src);
> -	intel_plane->src_h = drm_rect_height(&state->orig_src);
>  	intel_plane->obj = obj;
>  
>  	if (fb != crtc->cursor->fb) {
> diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
> index 1882de1..fdebeea 100644
> --- a/drivers/gpu/drm/i915/intel_drv.h
> +++ b/drivers/gpu/drm/i915/intel_drv.h
> @@ -248,8 +248,6 @@ struct intel_plane_state {
>  	struct drm_rect src;
>  	struct drm_rect dst;
>  	struct drm_rect clip;
> -	struct drm_rect orig_src;
> -	struct drm_rect orig_dst;
>  	bool visible;
>  };
>  
> @@ -485,10 +483,6 @@ struct intel_plane {
>  	struct drm_i915_gem_object *obj;
>  	bool can_scale;
>  	int max_downscale;
> -	int crtc_x, crtc_y;
> -	unsigned int crtc_w, crtc_h;
> -	uint32_t src_x, src_y;
> -	uint32_t src_w, src_h;
>  	unsigned int rotation;
>  
>  	/* Since we need to change the watermarks before/after
> diff --git a/drivers/gpu/drm/i915/intel_sprite.c b/drivers/gpu/drm/i915/intel_sprite.c
> index 28ccaf7..9c00b68 100644
> --- a/drivers/gpu/drm/i915/intel_sprite.c
> +++ b/drivers/gpu/drm/i915/intel_sprite.c
> @@ -1282,14 +1282,6 @@ intel_commit_sprite_plane(struct drm_plane *plane,
>  	primary_enabled = !drm_rect_equals(dst, clip) || colorkey_enabled(intel_plane);
>  	WARN_ON(!primary_enabled && !state->visible && intel_crtc->active);
>  
> -	intel_plane->crtc_x = state->orig_dst.x1;
> -	intel_plane->crtc_y = state->orig_dst.y1;
> -	intel_plane->crtc_w = drm_rect_width(&state->orig_dst);
> -	intel_plane->crtc_h = drm_rect_height(&state->orig_dst);
> -	intel_plane->src_x = state->orig_src.x1;
> -	intel_plane->src_y = state->orig_src.y1;
> -	intel_plane->src_w = drm_rect_width(&state->orig_src);
> -	intel_plane->src_h = drm_rect_height(&state->orig_src);
>  	intel_plane->obj = obj;
>  
>  	if (intel_crtc->active) {
Shuang He Nov. 14, 2014, 7:28 a.m. UTC | #2
Tested-By: PRC QA PRTS (Patch Regression Test System Contact: shuang.he@intel.com)
-------------------------------------Summary-------------------------------------
Platform: baseline_drm_intel_nightly_pass_rate->patch_applied_pass_rate
BYT: pass/total=291/291->290/291
PNV: pass/total=356/356->356/356
ILK: pass/total=372/372->371/372
IVB: pass/total=544/546->524/546
SNB: pass/total=423/425->418/425
HSW: pass/total=579/579->570/579
BDW: pass/total=433/435->434/435
-------------------------------------Detailed-------------------------------------
test_platform: test_suite, test_case, result_with_drm_intel_nightly(count, machine_id...)...->result_with_patch_applied(count, machine_id)...
BYT: Intel_gpu_tools, igt_kms_setmode_invalid-clone-single-crtc, TIMEOUT(18, M36M31)PASS(1, M38) -> TIMEOUT(4, M36)
ILK: Intel_gpu_tools, igt_kms_setmode_invalid-clone-single-crtc, FAIL(6, M26)DMESG_FAIL(1, M26)TIMEOUT(33, M37M6M26)PASS(1, M26) -> TIMEOUT(4, M6)
IVB: Intel_gpu_tools, igt_gem_bad_reloc_negative-reloc, NSPT(9, M4M21M34M45)PASS(16, M21M34M4M45) -> NSPT(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-128x128-onscreen, DMESG_WARN(3, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-128x128-random, DMESG_WARN(1, M21)TIMEOUT(2, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-128x128-sliding, DMESG_WARN(2, M21)TIMEOUT(1, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-256x256-offscreen, DMESG_WARN(3, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-256x256-onscreen, DMESG_WARN(3, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-256x256-random, DMESG_WARN(3, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-256x256-sliding, DMESG_WARN(2, M21)TIMEOUT(1, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-64x64-offscreen, DMESG_WARN(3, M21)PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-64x64-onscreen, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-64x64-random, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_cursor_crc_cursor-64x64-sliding, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_mmio_vs_cs_flip_setplane_vs_cs_flip, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-A-plane-1, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-B-plane-1, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-C-plane-1, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-A-plane-1, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-A-plane-2, PASS(1, M4) -> TIMEOUT(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-B-plane-1, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-C-plane-1, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_rotation_crc_primary-rotation, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
IVB: Intel_gpu_tools, igt_kms_rotation_crc_sprite-rotation, PASS(1, M4) -> DMESG_WARN(1, M21)PASS(3, M21)
SNB: Intel_gpu_tools, igt_gem_concurrent_blit_gpuX-bcs-overwrite-source-forked, FAIL(1, M22)PASS(21, M35M22) -> PASS(4, M22)
SNB: Intel_gpu_tools, igt_kms_mmio_vs_cs_flip_setplane_vs_cs_flip, DMESG_WARN(3, M22)PASS(1, M22) -> DMESG_WARN(1, M22)PASS(3, M22)
SNB: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-B-plane-1, DMESG_WARN(3, M22)PASS(1, M22) -> DMESG_WARN(1, M22)PASS(3, M22)
SNB: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-A-plane-1, DMESG_WARN(3, M22)PASS(1, M22) -> DMESG_WARN(1, M22)PASS(3, M22)
SNB: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-B-plane-1, DMESG_WARN(3, M22)PASS(1, M22) -> DMESG_WARN(1, M22)PASS(3, M22)
SNB: Intel_gpu_tools, igt_kms_rotation_crc_sprite-rotation, DMESG_WARN(3, M22)PASS(1, M22) -> DMESG_WARN(1, M22)PASS(3, M22)
SNB: Intel_gpu_tools, igt_pm_rpm_cursor, DMESG_WARN(3, M22)PASS(1, M35) -> DMESG_WARN(1, M22)PASS(3, M22)
HSW: Intel_gpu_tools, igt_kms_mmio_vs_cs_flip_setplane_vs_cs_flip, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-A-plane-1, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-B-plane-1, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_kms_plane_plane-position-covered-pipe-C-plane-1, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-B-plane-1, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_kms_plane_plane-position-hole-pipe-C-plane-2, TIMEOUT(1, M19)PASS(3, M39M19) -> TIMEOUT(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_kms_rotation_crc_primary-rotation, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_pm_rpm_cursor, DMESG_WARN(2, M19)TIMEOUT(1, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
HSW: Intel_gpu_tools, igt_pm_rpm_cursor-dpms, DMESG_WARN(3, M19)PASS(1, M39) -> DMESG_WARN(1, M19)PASS(3, M19)
BDW: Intel_gpu_tools, igt_gem_reset_stats_ban-bsd, DMESG_WARN(1, M30)PASS(24, M30M42M28) -> PASS(4, M28)
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 8d5a3b4..a595a58 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -11526,14 +11526,6 @@  intel_commit_primary_plane(struct drm_plane *plane,
 	crtc->x = src->x1;
 	crtc->y = src->y1;
 
-	intel_plane->crtc_x = state->orig_dst.x1;
-	intel_plane->crtc_y = state->orig_dst.y1;
-	intel_plane->crtc_w = drm_rect_width(&state->orig_dst);
-	intel_plane->crtc_h = drm_rect_height(&state->orig_dst);
-	intel_plane->src_x = state->orig_src.x1;
-	intel_plane->src_y = state->orig_src.y1;
-	intel_plane->src_w = drm_rect_width(&state->orig_src);
-	intel_plane->src_h = drm_rect_height(&state->orig_src);
 	intel_plane->obj = obj;
 
 	if (intel_crtc->active) {
@@ -11748,14 +11740,6 @@  intel_commit_cursor_plane(struct drm_plane *plane,
 	crtc->cursor_x = state->base.crtc_x;
 	crtc->cursor_y = state->base.crtc_y;
 
-	intel_plane->crtc_x = state->orig_dst.x1;
-	intel_plane->crtc_y = state->orig_dst.y1;
-	intel_plane->crtc_w = drm_rect_width(&state->orig_dst);
-	intel_plane->crtc_h = drm_rect_height(&state->orig_dst);
-	intel_plane->src_x = state->orig_src.x1;
-	intel_plane->src_y = state->orig_src.y1;
-	intel_plane->src_w = drm_rect_width(&state->orig_src);
-	intel_plane->src_h = drm_rect_height(&state->orig_src);
 	intel_plane->obj = obj;
 
 	if (fb != crtc->cursor->fb) {
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
index 1882de1..fdebeea 100644
--- a/drivers/gpu/drm/i915/intel_drv.h
+++ b/drivers/gpu/drm/i915/intel_drv.h
@@ -248,8 +248,6 @@  struct intel_plane_state {
 	struct drm_rect src;
 	struct drm_rect dst;
 	struct drm_rect clip;
-	struct drm_rect orig_src;
-	struct drm_rect orig_dst;
 	bool visible;
 };
 
@@ -485,10 +483,6 @@  struct intel_plane {
 	struct drm_i915_gem_object *obj;
 	bool can_scale;
 	int max_downscale;
-	int crtc_x, crtc_y;
-	unsigned int crtc_w, crtc_h;
-	uint32_t src_x, src_y;
-	uint32_t src_w, src_h;
 	unsigned int rotation;
 
 	/* Since we need to change the watermarks before/after
diff --git a/drivers/gpu/drm/i915/intel_sprite.c b/drivers/gpu/drm/i915/intel_sprite.c
index 28ccaf7..9c00b68 100644
--- a/drivers/gpu/drm/i915/intel_sprite.c
+++ b/drivers/gpu/drm/i915/intel_sprite.c
@@ -1282,14 +1282,6 @@  intel_commit_sprite_plane(struct drm_plane *plane,
 	primary_enabled = !drm_rect_equals(dst, clip) || colorkey_enabled(intel_plane);
 	WARN_ON(!primary_enabled && !state->visible && intel_crtc->active);
 
-	intel_plane->crtc_x = state->orig_dst.x1;
-	intel_plane->crtc_y = state->orig_dst.y1;
-	intel_plane->crtc_w = drm_rect_width(&state->orig_dst);
-	intel_plane->crtc_h = drm_rect_height(&state->orig_dst);
-	intel_plane->src_x = state->orig_src.x1;
-	intel_plane->src_y = state->orig_src.y1;
-	intel_plane->src_w = drm_rect_width(&state->orig_src);
-	intel_plane->src_h = drm_rect_height(&state->orig_src);
 	intel_plane->obj = obj;
 
 	if (intel_crtc->active) {