From: "Kazlauskas, Nicholas" <nicholas.kazlauskas@amd.com> To: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Cc: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>, Hersen Wu <hersenxs.wu@amd.com>, dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org Subject: Re: [PATCH 5/7] drm/amd/display: Reset plane for anything that's not a FAST update Date: Thu, 6 Aug 2020 14:27:26 -0400 [thread overview] Message-ID: <fbd81eb9-0fec-6b5f-190e-49c3d4b40600@amd.com> (raw) In-Reply-To: <20200805204557.slkhfawjexrqzawu@outlook.office365.com> On 2020-08-05 4:45 p.m., Rodrigo Siqueira wrote: > On 07/30, Nicholas Kazlauskas wrote: >> [Why] >> MEDIUM or FULL updates can require global validation or affect >> bandwidth. By treating these all simply as surface updates we aren't >> actually passing this through DC global validation. >> >> [How] >> There's currently no way to pass surface updates through DC global >> validation, nor do I think it's a good idea to change the interface >> to accept these. >> >> DC global validation itself is currently stateless, and we can move >> our update type checking to be stateless as well by duplicating DC >> surface checks in DM based on DRM properties. >> >> We wanted to rely on DC automatically determining this since DC knows >> best, but DM is ultimately what fills in everything into DC plane >> state so it does need to know as well. >> >> There are basically only three paths that we exercise in DM today: >> >> 1) Cursor (async update) >> 2) Pageflip (fast update) >> 3) Full pipe programming (medium/full updates) >> >> Which means that anything that's more than a pageflip really needs to >> go down path #3. >> >> So this change duplicates all the surface update checks based on DRM >> state instead inside of should_reset_plane(). >> >> Next step is dropping dm_determine_update_type_for_commit and we no >> longer require the old DC state at all for global validation. >> >> Optimization can come later so we don't reset DC planes at all for >> MEDIUM udpates and avoid validation, but we might require some extra >> checks in DM to achieve this. > > How about adding this optimization description in our TODO list > under-display folder? > > Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Sure, I'll make another patch to clean up some of the TODO items in the text file. Regards, Nicholas Kazlauskas > >> Cc: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com> >> Cc: Hersen Wu <hersenxs.wu@amd.com> >> Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com> >> --- >> .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 25 +++++++++++++++++++ >> 1 file changed, 25 insertions(+) >> >> 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 0d5f45742bb5..2cbb29199e61 100644 >> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c >> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c >> @@ -8336,6 +8336,31 @@ static bool should_reset_plane(struct drm_atomic_state *state, >> if (old_other_state->crtc != new_other_state->crtc) >> return true; >> >> + /* Src/dst size and scaling updates. */ >> + if (old_other_state->src_w != new_other_state->src_w || >> + old_other_state->src_h != new_other_state->src_h || >> + old_other_state->crtc_w != new_other_state->crtc_w || >> + old_other_state->crtc_h != new_other_state->crtc_h) >> + return true; >> + >> + /* Rotation / mirroring updates. */ >> + if (old_other_state->rotation != new_other_state->rotation) >> + return true; >> + >> + /* Blending updates. */ >> + if (old_other_state->pixel_blend_mode != >> + new_other_state->pixel_blend_mode) >> + return true; >> + >> + /* Alpha updates. */ >> + if (old_other_state->alpha != new_other_state->alpha) >> + return true; >> + >> + /* Colorspace changes. */ >> + if (old_other_state->color_range != new_other_state->color_range || >> + old_other_state->color_encoding != new_other_state->color_encoding) >> + return true; >> + >> /* Framebuffer checks fall at the end. */ >> if (!old_other_state->fb || !new_other_state->fb) >> continue; >> -- >> 2.25.1 >> >> _______________________________________________ >> amd-gfx mailing list >> amd-gfx@lists.freedesktop.org >> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&data=02%7C01%7CRodrigo.Siqueira%40amd.com%7Ccc095e7ce6164f529e2708d834c86d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637317382766607890&sdata=omLC%2BizXVEjjGe6IylBpniZzyUGlzTATrgRoWEo6dHc%3D&reserved=0 > _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel
WARNING: multiple messages have this Message-ID (diff)
From: "Kazlauskas, Nicholas" <nicholas.kazlauskas@amd.com> To: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Cc: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>, Hersen Wu <hersenxs.wu@amd.com>, dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org Subject: Re: [PATCH 5/7] drm/amd/display: Reset plane for anything that's not a FAST update Date: Thu, 6 Aug 2020 14:27:26 -0400 [thread overview] Message-ID: <fbd81eb9-0fec-6b5f-190e-49c3d4b40600@amd.com> (raw) In-Reply-To: <20200805204557.slkhfawjexrqzawu@outlook.office365.com> On 2020-08-05 4:45 p.m., Rodrigo Siqueira wrote: > On 07/30, Nicholas Kazlauskas wrote: >> [Why] >> MEDIUM or FULL updates can require global validation or affect >> bandwidth. By treating these all simply as surface updates we aren't >> actually passing this through DC global validation. >> >> [How] >> There's currently no way to pass surface updates through DC global >> validation, nor do I think it's a good idea to change the interface >> to accept these. >> >> DC global validation itself is currently stateless, and we can move >> our update type checking to be stateless as well by duplicating DC >> surface checks in DM based on DRM properties. >> >> We wanted to rely on DC automatically determining this since DC knows >> best, but DM is ultimately what fills in everything into DC plane >> state so it does need to know as well. >> >> There are basically only three paths that we exercise in DM today: >> >> 1) Cursor (async update) >> 2) Pageflip (fast update) >> 3) Full pipe programming (medium/full updates) >> >> Which means that anything that's more than a pageflip really needs to >> go down path #3. >> >> So this change duplicates all the surface update checks based on DRM >> state instead inside of should_reset_plane(). >> >> Next step is dropping dm_determine_update_type_for_commit and we no >> longer require the old DC state at all for global validation. >> >> Optimization can come later so we don't reset DC planes at all for >> MEDIUM udpates and avoid validation, but we might require some extra >> checks in DM to achieve this. > > How about adding this optimization description in our TODO list > under-display folder? > > Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Sure, I'll make another patch to clean up some of the TODO items in the text file. Regards, Nicholas Kazlauskas > >> Cc: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com> >> Cc: Hersen Wu <hersenxs.wu@amd.com> >> Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com> >> --- >> .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 25 +++++++++++++++++++ >> 1 file changed, 25 insertions(+) >> >> 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 0d5f45742bb5..2cbb29199e61 100644 >> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c >> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c >> @@ -8336,6 +8336,31 @@ static bool should_reset_plane(struct drm_atomic_state *state, >> if (old_other_state->crtc != new_other_state->crtc) >> return true; >> >> + /* Src/dst size and scaling updates. */ >> + if (old_other_state->src_w != new_other_state->src_w || >> + old_other_state->src_h != new_other_state->src_h || >> + old_other_state->crtc_w != new_other_state->crtc_w || >> + old_other_state->crtc_h != new_other_state->crtc_h) >> + return true; >> + >> + /* Rotation / mirroring updates. */ >> + if (old_other_state->rotation != new_other_state->rotation) >> + return true; >> + >> + /* Blending updates. */ >> + if (old_other_state->pixel_blend_mode != >> + new_other_state->pixel_blend_mode) >> + return true; >> + >> + /* Alpha updates. */ >> + if (old_other_state->alpha != new_other_state->alpha) >> + return true; >> + >> + /* Colorspace changes. */ >> + if (old_other_state->color_range != new_other_state->color_range || >> + old_other_state->color_encoding != new_other_state->color_encoding) >> + return true; >> + >> /* Framebuffer checks fall at the end. */ >> if (!old_other_state->fb || !new_other_state->fb) >> continue; >> -- >> 2.25.1 >> >> _______________________________________________ >> amd-gfx mailing list >> amd-gfx@lists.freedesktop.org >> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&data=02%7C01%7CRodrigo.Siqueira%40amd.com%7Ccc095e7ce6164f529e2708d834c86d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637317382766607890&sdata=omLC%2BizXVEjjGe6IylBpniZzyUGlzTATrgRoWEo6dHc%3D&reserved=0 > _______________________________________________ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx
next prev parent reply other threads:[~2020-08-06 18:27 UTC|newest] Thread overview: 76+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-07-30 20:36 [PATCH 0/7] drm/amd/display: Drop DRM private objects from amdgpu_dm Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-07-30 20:36 ` [PATCH 1/7] drm/amd/display: Store tiling_flags and tmz_surface on dm_plane_state Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-08-05 21:04 ` Rodrigo Siqueira 2020-08-05 21:04 ` Rodrigo Siqueira 2020-08-07 8:24 ` daniel 2020-08-07 8:24 ` daniel 2020-07-30 20:36 ` [PATCH 2/7] drm/amd/display: Reset plane when tiling flags change Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-07-30 20:50 ` Wu, Hersen 2020-07-30 20:50 ` Wu, Hersen 2020-08-05 21:11 ` Rodrigo Siqueira 2020-08-05 21:11 ` Rodrigo Siqueira 2020-08-06 18:18 ` Kazlauskas, Nicholas 2020-08-06 18:18 ` Kazlauskas, Nicholas 2020-07-30 20:36 ` [PATCH 3/7] drm/amd/display: Avoid using unvalidated tiling_flags and tmz_surface in prepare_planes Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-08-05 21:12 ` Rodrigo Siqueira 2020-08-05 21:12 ` Rodrigo Siqueira 2020-08-07 8:30 ` daniel 2020-08-07 8:30 ` daniel 2020-08-07 14:29 ` Kazlauskas, Nicholas 2020-08-07 14:29 ` Kazlauskas, Nicholas 2020-08-10 12:25 ` Daniel Vetter 2020-08-10 12:25 ` Daniel Vetter 2020-08-10 12:30 ` Christian König 2020-08-10 12:30 ` Christian König 2020-08-10 12:32 ` Daniel Vetter 2020-08-10 12:32 ` Daniel Vetter 2020-08-11 13:42 ` Marek Olšák 2020-08-11 13:42 ` Marek Olšák 2020-08-12 13:54 ` Daniel Vetter 2020-08-12 13:54 ` Daniel Vetter 2020-08-17 6:23 ` Marek Olšák 2020-08-17 6:23 ` Marek Olšák 2020-09-01 7:20 ` Daniel Vetter 2020-09-01 7:20 ` Daniel Vetter 2020-07-30 20:36 ` [PATCH 4/7] drm/amd/display: Use validated tiling_flags and tmz_surface in commit_tail Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-08-05 21:15 ` Rodrigo Siqueira 2020-08-05 21:15 ` Rodrigo Siqueira 2020-07-30 20:36 ` [PATCH 5/7] drm/amd/display: Reset plane for anything that's not a FAST update Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-07-30 20:51 ` Wu, Hersen 2020-07-30 20:51 ` Wu, Hersen 2020-08-05 20:45 ` Rodrigo Siqueira 2020-08-05 20:45 ` Rodrigo Siqueira 2020-08-06 18:27 ` Kazlauskas, Nicholas [this message] 2020-08-06 18:27 ` Kazlauskas, Nicholas 2020-08-07 8:34 ` daniel 2020-08-07 8:34 ` daniel 2020-08-07 14:26 ` Kazlauskas, Nicholas 2020-08-07 14:26 ` Kazlauskas, Nicholas 2020-08-10 12:30 ` Daniel Vetter 2020-08-10 12:30 ` Daniel Vetter 2020-07-30 20:36 ` [PATCH 6/7] drm/amd/display: Drop dm_determine_update_type_for_commit Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-08-05 20:48 ` Rodrigo Siqueira 2020-08-05 20:48 ` Rodrigo Siqueira 2020-07-30 20:36 ` [PATCH 7/7] drm/amd/display: Replace DRM private objects with subclassed DRM atomic state Nicholas Kazlauskas 2020-07-30 20:36 ` Nicholas Kazlauskas 2020-08-05 20:37 ` Rodrigo Siqueira 2020-08-05 20:37 ` Rodrigo Siqueira 2020-08-06 14:25 ` Kazlauskas, Nicholas 2020-08-06 14:25 ` Kazlauskas, Nicholas 2020-08-07 8:40 ` daniel 2020-08-07 8:40 ` daniel 2020-08-07 8:52 ` daniel 2020-08-07 8:52 ` daniel 2020-08-07 14:32 ` Kazlauskas, Nicholas 2020-08-07 14:32 ` Kazlauskas, Nicholas 2020-08-10 12:34 ` Daniel Vetter 2020-08-10 12:34 ` Daniel Vetter 2020-08-07 8:29 ` [PATCH 0/7] drm/amd/display: Drop DRM private objects from amdgpu_dm daniel 2020-08-07 8:29 ` daniel
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=fbd81eb9-0fec-6b5f-190e-49c3d4b40600@amd.com \ --to=nicholas.kazlauskas@amd.com \ --cc=Bhawanpreet.Lakha@amd.com \ --cc=Rodrigo.Siqueira@amd.com \ --cc=amd-gfx@lists.freedesktop.org \ --cc=dri-devel@lists.freedesktop.org \ --cc=hersenxs.wu@amd.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.