Message ID | 20220325000622.1594343-1-sean@poorly.run (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/amd: Re-classify some log messages in commit path | expand |
Am 25.03.22 um 01:06 schrieb Sean Paul: > From: Sean Paul <seanpaul@chromium.org> > > ATOMIC and DRIVER log categories do not typically contain per-frame log > messages. This patch re-classifies some messages in amd to chattier > categories to keep ATOMIC/DRIVER quiet. > > Signed-off-by: Sean Paul <seanpaul@chromium.org> Please use drm/amdgpu for the subject line in the future, apart from that looks like a really clean patch to me. Feel free to add an Acked-by: Christian König <christian.koenig@amd.com> > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 5 +++-- > drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 8 ++++---- > 2 files changed, 7 insertions(+), 6 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > index fae5c1debfad..1fcbab2fd3c3 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > @@ -113,8 +113,9 @@ static void amdgpu_display_flip_work_func(struct work_struct *__work) > spin_unlock_irqrestore(&crtc->dev->event_lock, flags); > > > - DRM_DEBUG_DRIVER("crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", > - amdgpu_crtc->crtc_id, amdgpu_crtc, work); > + drm_dbg_vbl(adev_to_drm(adev), > + "crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", > + amdgpu_crtc->crtc_id, amdgpu_crtc, work); > > } > > diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > index b30656959fd8..45d130f86114 100644 > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > @@ -9248,7 +9248,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, > &bundle->flip_addrs[planes_count].address, > afb->tmz_surface, false); > > - DRM_DEBUG_ATOMIC("plane: id=%d dcc_en=%d\n", > + drm_dbg_state(state->dev, "plane: id=%d dcc_en=%d\n", > new_plane_state->plane->index, > bundle->plane_infos[planes_count].dcc.enable); > > @@ -9282,7 +9282,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, > dc_plane, > bundle->flip_addrs[planes_count].flip_timestamp_in_us); > > - DRM_DEBUG_ATOMIC("%s Flipping to hi: 0x%x, low: 0x%x\n", > + drm_dbg_state(state->dev, "%s Flipping to hi: 0x%x, low: 0x%x\n", > __func__, > bundle->flip_addrs[planes_count].address.grph.addr.high_part, > bundle->flip_addrs[planes_count].address.grph.addr.low_part); > @@ -9624,7 +9624,7 @@ static void amdgpu_dm_atomic_commit_tail(struct drm_atomic_state *state) > dm_new_crtc_state = to_dm_crtc_state(new_crtc_state); > dm_old_crtc_state = to_dm_crtc_state(old_crtc_state); > > - DRM_DEBUG_ATOMIC( > + drm_dbg_state(state->dev, > "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " > "planes_changed:%d, mode_changed:%d,active_changed:%d," > "connectors_changed:%d\n", > @@ -10328,7 +10328,7 @@ static int dm_update_crtc_state(struct amdgpu_display_manager *dm, > if (!drm_atomic_crtc_needs_modeset(new_crtc_state)) > goto skip_modeset; > > - DRM_DEBUG_ATOMIC( > + drm_dbg_state(state->dev, > "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " > "planes_changed:%d, mode_changed:%d,active_changed:%d," > "connectors_changed:%d\n",
On 2022-03-24 20:06, Sean Paul wrote: > From: Sean Paul <seanpaul@chromium.org> > > ATOMIC and DRIVER log categories do not typically contain per-frame log > messages. This patch re-classifies some messages in amd to chattier > categories to keep ATOMIC/DRIVER quiet. > > Signed-off-by: Sean Paul <seanpaul@chromium.org> With the subject line fixed as per Christian's comment this is Reviewed-by: Harry Wentland <harry.wentland@amd.com> Harry > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 5 +++-- > drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 8 ++++---- > 2 files changed, 7 insertions(+), 6 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > index fae5c1debfad..1fcbab2fd3c3 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > @@ -113,8 +113,9 @@ static void amdgpu_display_flip_work_func(struct work_struct *__work) > spin_unlock_irqrestore(&crtc->dev->event_lock, flags); > > > - DRM_DEBUG_DRIVER("crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", > - amdgpu_crtc->crtc_id, amdgpu_crtc, work); > + drm_dbg_vbl(adev_to_drm(adev), > + "crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", > + amdgpu_crtc->crtc_id, amdgpu_crtc, work); > > } > > diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > index b30656959fd8..45d130f86114 100644 > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > @@ -9248,7 +9248,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, > &bundle->flip_addrs[planes_count].address, > afb->tmz_surface, false); > > - DRM_DEBUG_ATOMIC("plane: id=%d dcc_en=%d\n", > + drm_dbg_state(state->dev, "plane: id=%d dcc_en=%d\n", > new_plane_state->plane->index, > bundle->plane_infos[planes_count].dcc.enable); > > @@ -9282,7 +9282,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, > dc_plane, > bundle->flip_addrs[planes_count].flip_timestamp_in_us); > > - DRM_DEBUG_ATOMIC("%s Flipping to hi: 0x%x, low: 0x%x\n", > + drm_dbg_state(state->dev, "%s Flipping to hi: 0x%x, low: 0x%x\n", > __func__, > bundle->flip_addrs[planes_count].address.grph.addr.high_part, > bundle->flip_addrs[planes_count].address.grph.addr.low_part); > @@ -9624,7 +9624,7 @@ static void amdgpu_dm_atomic_commit_tail(struct drm_atomic_state *state) > dm_new_crtc_state = to_dm_crtc_state(new_crtc_state); > dm_old_crtc_state = to_dm_crtc_state(old_crtc_state); > > - DRM_DEBUG_ATOMIC( > + drm_dbg_state(state->dev, > "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " > "planes_changed:%d, mode_changed:%d,active_changed:%d," > "connectors_changed:%d\n", > @@ -10328,7 +10328,7 @@ static int dm_update_crtc_state(struct amdgpu_display_manager *dm, > if (!drm_atomic_crtc_needs_modeset(new_crtc_state)) > goto skip_modeset; > > - DRM_DEBUG_ATOMIC( > + drm_dbg_state(state->dev, > "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " > "planes_changed:%d, mode_changed:%d,active_changed:%d," > "connectors_changed:%d\n",
Thanks. Fixed up the title when I applied it. Alex On Fri, Mar 25, 2022 at 10:55 AM Harry Wentland <harry.wentland@amd.com> wrote: > > On 2022-03-24 20:06, Sean Paul wrote: > > From: Sean Paul <seanpaul@chromium.org> > > > > ATOMIC and DRIVER log categories do not typically contain per-frame log > > messages. This patch re-classifies some messages in amd to chattier > > categories to keep ATOMIC/DRIVER quiet. > > > > Signed-off-by: Sean Paul <seanpaul@chromium.org> > > With the subject line fixed as per Christian's comment this is > Reviewed-by: Harry Wentland <harry.wentland@amd.com> > > Harry > > > --- > > drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 5 +++-- > > drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 8 ++++---- > > 2 files changed, 7 insertions(+), 6 deletions(-) > > > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > > index fae5c1debfad..1fcbab2fd3c3 100644 > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c > > @@ -113,8 +113,9 @@ static void amdgpu_display_flip_work_func(struct work_struct *__work) > > spin_unlock_irqrestore(&crtc->dev->event_lock, flags); > > > > > > - DRM_DEBUG_DRIVER("crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", > > - amdgpu_crtc->crtc_id, amdgpu_crtc, work); > > + drm_dbg_vbl(adev_to_drm(adev), > > + "crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", > > + amdgpu_crtc->crtc_id, amdgpu_crtc, work); > > > > } > > > > diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > > index b30656959fd8..45d130f86114 100644 > > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > > @@ -9248,7 +9248,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, > > &bundle->flip_addrs[planes_count].address, > > afb->tmz_surface, false); > > > > - DRM_DEBUG_ATOMIC("plane: id=%d dcc_en=%d\n", > > + drm_dbg_state(state->dev, "plane: id=%d dcc_en=%d\n", > > new_plane_state->plane->index, > > bundle->plane_infos[planes_count].dcc.enable); > > > > @@ -9282,7 +9282,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, > > dc_plane, > > bundle->flip_addrs[planes_count].flip_timestamp_in_us); > > > > - DRM_DEBUG_ATOMIC("%s Flipping to hi: 0x%x, low: 0x%x\n", > > + drm_dbg_state(state->dev, "%s Flipping to hi: 0x%x, low: 0x%x\n", > > __func__, > > bundle->flip_addrs[planes_count].address.grph.addr.high_part, > > bundle->flip_addrs[planes_count].address.grph.addr.low_part); > > @@ -9624,7 +9624,7 @@ static void amdgpu_dm_atomic_commit_tail(struct drm_atomic_state *state) > > dm_new_crtc_state = to_dm_crtc_state(new_crtc_state); > > dm_old_crtc_state = to_dm_crtc_state(old_crtc_state); > > > > - DRM_DEBUG_ATOMIC( > > + drm_dbg_state(state->dev, > > "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " > > "planes_changed:%d, mode_changed:%d,active_changed:%d," > > "connectors_changed:%d\n", > > @@ -10328,7 +10328,7 @@ static int dm_update_crtc_state(struct amdgpu_display_manager *dm, > > if (!drm_atomic_crtc_needs_modeset(new_crtc_state)) > > goto skip_modeset; > > > > - DRM_DEBUG_ATOMIC( > > + drm_dbg_state(state->dev, > > "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " > > "planes_changed:%d, mode_changed:%d,active_changed:%d," > > "connectors_changed:%d\n", >
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c index fae5c1debfad..1fcbab2fd3c3 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_display.c @@ -113,8 +113,9 @@ static void amdgpu_display_flip_work_func(struct work_struct *__work) spin_unlock_irqrestore(&crtc->dev->event_lock, flags); - DRM_DEBUG_DRIVER("crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", - amdgpu_crtc->crtc_id, amdgpu_crtc, work); + drm_dbg_vbl(adev_to_drm(adev), + "crtc:%d[%p], pflip_stat:AMDGPU_FLIP_SUBMITTED, work: %p,\n", + amdgpu_crtc->crtc_id, amdgpu_crtc, work); } diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index b30656959fd8..45d130f86114 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -9248,7 +9248,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, &bundle->flip_addrs[planes_count].address, afb->tmz_surface, false); - DRM_DEBUG_ATOMIC("plane: id=%d dcc_en=%d\n", + drm_dbg_state(state->dev, "plane: id=%d dcc_en=%d\n", new_plane_state->plane->index, bundle->plane_infos[planes_count].dcc.enable); @@ -9282,7 +9282,7 @@ static void amdgpu_dm_commit_planes(struct drm_atomic_state *state, dc_plane, bundle->flip_addrs[planes_count].flip_timestamp_in_us); - DRM_DEBUG_ATOMIC("%s Flipping to hi: 0x%x, low: 0x%x\n", + drm_dbg_state(state->dev, "%s Flipping to hi: 0x%x, low: 0x%x\n", __func__, bundle->flip_addrs[planes_count].address.grph.addr.high_part, bundle->flip_addrs[planes_count].address.grph.addr.low_part); @@ -9624,7 +9624,7 @@ static void amdgpu_dm_atomic_commit_tail(struct drm_atomic_state *state) dm_new_crtc_state = to_dm_crtc_state(new_crtc_state); dm_old_crtc_state = to_dm_crtc_state(old_crtc_state); - DRM_DEBUG_ATOMIC( + drm_dbg_state(state->dev, "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " "planes_changed:%d, mode_changed:%d,active_changed:%d," "connectors_changed:%d\n", @@ -10328,7 +10328,7 @@ static int dm_update_crtc_state(struct amdgpu_display_manager *dm, if (!drm_atomic_crtc_needs_modeset(new_crtc_state)) goto skip_modeset; - DRM_DEBUG_ATOMIC( + drm_dbg_state(state->dev, "amdgpu_crtc id:%d crtc_state_flags: enable:%d, active:%d, " "planes_changed:%d, mode_changed:%d,active_changed:%d," "connectors_changed:%d\n",