[PATCH 1/2] drm/amdgpu/display: revert random whitespace changes
Alex Deucher
alexander.deucher at amd.com
Mon May 17 19:08:08 UTC 2021
Commit 458ef68e972878 ("drm/amd/display: Add get_current_time interface to dmub_srv")
introduced a bunch of random whitespace changes which lead
to compiler warnings. Revert those changes to fix the warning
and keep the code readable. No intended functional change.
Fixes: 458ef68e972878 ("drm/amd/display: Add get_current_time interface to dmub_srv")
Signed-off-by: Alex Deucher <alexander.deucher at amd.com>
Cc: Wyatt Wood <wyatt.wood at amd.com>
---
drivers/gpu/drm/amd/display/dc/core/dc.c | 36 +++++++++----------
.../gpu/drm/amd/display/dc/dcn21/dcn21_hubp.c | 8 ++---
drivers/gpu/drm/amd/display/dc/dm_services.h | 1 +
3 files changed, 23 insertions(+), 22 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c
index b4aa20250301..ef157b83bacd 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc.c
@@ -2636,14 +2636,14 @@ static void commit_planes_for_stream(struct dc *dc,
top_pipe_to_program->stream_res.tg);
}
- if ((update_type != UPDATE_TYPE_FAST) && dc->hwss.interdependent_update_lock)
- dc->hwss.interdependent_update_lock(dc, context, true);
- else
- /* Lock the top pipe while updating plane addrs, since freesync requires
- * plane addr update event triggers to be synchronized.
- * top_pipe_to_program is expected to never be NULL
- */
- dc->hwss.pipe_control_lock(dc, top_pipe_to_program, true);
+ if ((update_type != UPDATE_TYPE_FAST) && dc->hwss.interdependent_update_lock)
+ dc->hwss.interdependent_update_lock(dc, context, true);
+ else
+ /* Lock the top pipe while updating plane addrs, since freesync requires
+ * plane addr update event triggers to be synchronized.
+ * top_pipe_to_program is expected to never be NULL
+ */
+ dc->hwss.pipe_control_lock(dc, top_pipe_to_program, true);
// Stream updates
if (stream_update)
@@ -2659,10 +2659,10 @@ static void commit_planes_for_stream(struct dc *dc,
if (dc->hwss.program_front_end_for_ctx)
dc->hwss.program_front_end_for_ctx(dc, context);
- if ((update_type != UPDATE_TYPE_FAST) && dc->hwss.interdependent_update_lock)
- dc->hwss.interdependent_update_lock(dc, context, false);
- else
- dc->hwss.pipe_control_lock(dc, top_pipe_to_program, false);
+ if ((update_type != UPDATE_TYPE_FAST) && dc->hwss.interdependent_update_lock)
+ dc->hwss.interdependent_update_lock(dc, context, false);
+ else
+ dc->hwss.pipe_control_lock(dc, top_pipe_to_program, false);
dc->hwss.post_unlock_program_front_end(dc, context);
return;
}
@@ -2789,10 +2789,10 @@ static void commit_planes_for_stream(struct dc *dc,
}
- if ((update_type != UPDATE_TYPE_FAST) && dc->hwss.interdependent_update_lock)
- dc->hwss.interdependent_update_lock(dc, context, false);
- else
- dc->hwss.pipe_control_lock(dc, top_pipe_to_program, false);
+ if ((update_type != UPDATE_TYPE_FAST) && dc->hwss.interdependent_update_lock)
+ dc->hwss.interdependent_update_lock(dc, context, false);
+ else
+ dc->hwss.pipe_control_lock(dc, top_pipe_to_program, false);
if ((update_type != UPDATE_TYPE_FAST) && stream->update_flags.bits.dsc_changed)
if (top_pipe_to_program->stream_res.tg->funcs->lock_doublebuffer_enable) {
@@ -2838,8 +2838,8 @@ static void commit_planes_for_stream(struct dc *dc,
pipe_ctx->plane_state->skip_manual_trigger)
continue;
- if (pipe_ctx->stream_res.tg->funcs->program_manual_trigger)
- pipe_ctx->stream_res.tg->funcs->program_manual_trigger(pipe_ctx->stream_res.tg);
+ if (pipe_ctx->stream_res.tg->funcs->program_manual_trigger)
+ pipe_ctx->stream_res.tg->funcs->program_manual_trigger(pipe_ctx->stream_res.tg);
}
}
diff --git a/drivers/gpu/drm/amd/display/dc/dcn21/dcn21_hubp.c b/drivers/gpu/drm/amd/display/dc/dcn21/dcn21_hubp.c
index e7c56df8f762..b0c9180b808f 100644
--- a/drivers/gpu/drm/amd/display/dc/dcn21/dcn21_hubp.c
+++ b/drivers/gpu/drm/amd/display/dc/dcn21/dcn21_hubp.c
@@ -795,10 +795,10 @@ bool hubp21_program_surface_flip_and_addr(
flip_regs.tmz_surface = address->tmz_surface;
flip_regs.immediate = flip_immediate;
- if (hubp->ctx->dc->debug.enable_dmcub_surface_flip && address->type == PLN_ADDR_TYPE_VIDEO_PROGRESSIVE)
- dmcub_PLAT_54186_wa(hubp, &flip_regs);
- else
- program_surface_flip_and_addr(hubp, &flip_regs);
+ if (hubp->ctx->dc->debug.enable_dmcub_surface_flip && address->type == PLN_ADDR_TYPE_VIDEO_PROGRESSIVE)
+ dmcub_PLAT_54186_wa(hubp, &flip_regs);
+ else
+ program_surface_flip_and_addr(hubp, &flip_regs);
hubp->request_address = *address;
diff --git a/drivers/gpu/drm/amd/display/dc/dm_services.h b/drivers/gpu/drm/amd/display/dc/dm_services.h
index 7a3beaecd19d..9a3f2a44f882 100644
--- a/drivers/gpu/drm/amd/display/dc/dm_services.h
+++ b/drivers/gpu/drm/amd/display/dc/dm_services.h
@@ -264,6 +264,7 @@ static inline unsigned long long dm_get_timestamp(struct dc_context *ctx)
unsigned long long dm_get_elapse_time_in_ns(struct dc_context *ctx,
unsigned long long current_time_stamp,
unsigned long long last_time_stamp);
+
/*
* performance tracing
*/
--
2.31.1
More information about the amd-gfx
mailing list