drm/i915: Fix crtc_y assignment in intel_find_initial_plane_obj()
Subsystems (2)
PATCH 1/1 drm/i915: Fix crtc_y assignment in intel_find_initial_plane_obj()
From: Ville Syrjälä <[email protected]>
Let's set crtc_y to 0 instead of setting src_y twice.
Multiple assignments in one statement is a good way to hide bugs. Please don't do that.
--- drivers/gpu/drm/i915/intel_display.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/gpu/drm/i915/intel_display.c +4 -2
@@ -2640,11 +2640,13 @@ intel_find_initial_plane_obj(struct intel_crtc *intel_crtc,return ; valid_fb: - plane_state->src_x = plane_state->src_y =0 ; + plane_state->src_x =0 ; + plane_state->src_y =0 ; plane_state->src_w = fb->width <<16 ; plane_state->src_h = fb->height <<16 ; - plane_state->crtc_x = plane_state->src_y =0 ; + plane_state->crtc_x =0 ; + plane_state->crtc_y =0 ; plane_state->crtc_w = fb->width; plane_state->crtc_h = fb->height;
Signature · 6 lines
2.4.10 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Jani Nikula
maintainerQuoted 9 lines · On Fri, 13 Nov 2015, [email protected] wrote:
From: Ville Syrjälä <[email protected]>
Let's set
crtc_yto 0 instead of settingsrc_ytwice.Multiple assignments in one statement is a good way to hide bugs. Please don't do that.
Cc Maarten Lankhorst <[email protected]>Fixes be5651f2d581 ("drm/i915: Update missing properties in find_initial_plane_obj")
right?
Quoted 24 lines
Signed-off-by Ville Syrjälä <[email protected]>--- drivers/gpu/drm/i915/intel_display.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)drivers/gpu/drm/i915/intel_display.c +4
-2@@ -2640,11 +2640,13 @@ intel_find_initial_plane_obj(struct intel_crtc *intel_crtc,return ; valid_fb: - plane_state->src_x = plane_state->src_y =0 ; + plane_state->src_x =0 ; + plane_state->src_y =0 ; plane_state->src_w = fb->width <<16 ; plane_state->src_h = fb->height <<16 ; - plane_state->crtc_x = plane_state->src_y =0 ; + plane_state->crtc_x =0 ; + plane_state->crtc_y =0 ; plane_state->crtc_w = fb->width; plane_state->crtc_h = fb->height;
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 8 lines · Jani Nikula
Quoted 7 lines · On Fri, 13 Nov 2015, [email protected] wrote:
From: Ville Syrjälä <[email protected]>
Let's set
crtc_yto 0 instead of settingsrc_ytwice.Multiple assignments in one statement is a good way to hide bugs. Please don't do that.
Quoted 6 lines
Quoted 2 lines
Cc Maarten Lankhorst <[email protected]>Fixes be5651f2d581 ("drm/i915: Update missing properties in find_initial_plane_obj")Cc [email protected] # v4.3+right?
I think the state is kzalloc()ed, so there's probably no real bug here. Should have mentioned that in the commit message I suppose.
Quoted 29 lines
Quoted 26 lines
Signed-off-by Ville Syrjälä <[email protected]>--- drivers/gpu/drm/i915/intel_display.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)drivers/gpu/drm/i915/intel_display.c +4
-2@@ -2640,11 +2640,13 @@ intel_find_initial_plane_obj(struct intel_crtc *intel_crtc,return ; valid_fb: - plane_state->src_x = plane_state->src_y =0 ; + plane_state->src_x =0 ; + plane_state->src_y =0 ; plane_state->src_w = fb->width <<16 ; plane_state->src_h = fb->height <<16 ; - plane_state->crtc_x = plane_state->src_y =0 ; + plane_state->crtc_x =0 ; + plane_state->crtc_y =0 ; plane_state->crtc_w = fb->width; plane_state->crtc_h = fb->height;Signature · 1 line
Jani Nikula, Intel Open Source Technology Center
Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Op 13-11-15 om 18:16 schreef [email protected]:
Quoted 11 lines
From: Ville Syrjälä <[email protected]>
Let's set
crtc_yto 0 instead of settingsrc_ytwice.Multiple assignments in one statement is a good way to hide bugs. Please don't do that.
Cc Maarten Lankhorst <[email protected]>Fixes be5651f2d581 ("drm/i915: Update missing properties in find_initial_plane_obj")Signed-off-by Ville Syrjälä <[email protected]>
Oops.
R-b
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 8 lines · Maarten Lankhorst
Op 13-11-15 om 18:16 schreef [email protected]:
Quoted 7 lines
From: Ville Syrjälä <[email protected]>
Let's set
crtc_yto 0 instead of settingsrc_ytwice.Multiple assignments in one statement is a good way to hide bugs. Please don't do that.
Quoted 7 lines
Quoted 4 lines
Cc Maarten Lankhorst <[email protected]>Fixes be5651f2d581 ("drm/i915: Update missing properties in find_initial_plane_obj")Signed-off-by Ville Syrjälä <[email protected]>Oops.
R-b
Pushed to drm-intel-fixes, thanks for the patch and review.
Maarten, please give Damien and our tooling a chance and spell out the R-b...
BR,
Jani.
Quoted 4 lines
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx