From: Hamza Mahfooz <hamza.mahfooz@amd.com>
To: "Arnd Bergmann" <arnd@kernel.org>,
"Harry Wentland" <harry.wentland@amd.com>,
"Leo Li" <sunpeng.li@amd.com>,
"Rodrigo Siqueira" <Rodrigo.Siqueira@amd.com>,
"Alex Deucher" <alexander.deucher@amd.com>,
"Christian König" <christian.koenig@amd.com>,
"Pan, Xinhui" <Xinhui.Pan@amd.com>
Cc: Arnd Bergmann <arnd@arndb.de>, David Airlie <airlied@gmail.com>,
Daniel Vetter <daniel@ffwll.ch>, Lyude Paul <lyude@redhat.com>,
Wayne Lin <Wayne.Lin@amd.com>, hersen wu <hersenxs.wu@amd.com>,
Fangzhi Zuo <Jerry.Zuo@amd.com>,
Aurabindo Pillai <Aurabindo.Pillai@amd.com>,
Alan Liu <HaoPing.Liu@amd.com>, Wenjing Liu <wenjing.liu@amd.com>,
Jun Lei <Jun.Lei@amd.com>, Alex Hung <alex.hung@amd.com>,
Mario Kleiner <mario.kleiner.de@gmail.com>,
Aric Cyr <Aric.Cyr@amd.com>,
Qingqing Zhuo <qingqing.zhuo@amd.com>,
Alvin Lee <Alvin.Lee2@amd.com>,
Jasdeep Dhillon <jdhillon@amd.com>, Roman Li <roman.li@amd.com>,
amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] [v2] drm/amd/display: fix is_timing_changed() prototype
Date: Tue, 18 Apr 2023 10:17:22 -0400 [thread overview]
Message-ID: <9f3e7030-c439-b8fe-7d30-80b11f4d06bb@amd.com> (raw)
In-Reply-To: <20230417220827.3481168-1-arnd@kernel.org>
On 4/17/23 18:07, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> Three functions in the amdgpu display driver cause -Wmissing-prototype
> warnings:
>
> drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc_resource.c:1858:6: error: no previous prototype for 'is_timing_changed' [-Werror=missing-prototypes]
>
> is_timing_changed() is actually meant to be a global symbol, but needs
> a proper name and prototype.
>
> Fixes: 17ce8a6907f7 ("drm/amd/display: Add dsc pre-validation in atomic check")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Applied, thanks!
> ---
> drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c | 5 ++---
> drivers/gpu/drm/amd/display/dc/core/dc_resource.c | 6 +++---
> drivers/gpu/drm/amd/display/dc/dc.h | 3 +++
> 3 files changed, 8 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
> index 994ba426ca66..442511061178 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
> @@ -45,8 +45,7 @@
> #endif
>
> #include "dc/dcn20/dcn20_resource.h"
> -bool is_timing_changed(struct dc_stream_state *cur_stream,
> - struct dc_stream_state *new_stream);
> +
> #define PEAK_FACTOR_X1000 1006
>
> static ssize_t dm_dp_aux_transfer(struct drm_dp_aux *aux,
> @@ -1417,7 +1416,7 @@ int pre_validate_dsc(struct drm_atomic_state *state,
> struct dc_stream_state *stream = dm_state->context->streams[i];
>
> if (local_dc_state->streams[i] &&
> - is_timing_changed(stream, local_dc_state->streams[i])) {
> + dc_is_timing_changed(stream, local_dc_state->streams[i])) {
> DRM_INFO_ONCE("crtc[%d] needs mode_changed\n", i);
> } else {
> int ind = find_crtc_index_in_state_by_stream(state, stream);
> diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
> index 85d54bfb595c..344533623cb9 100644
> --- a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
> +++ b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
> @@ -1855,7 +1855,7 @@ bool dc_add_all_planes_for_stream(
> return add_all_planes_for_stream(dc, stream, &set, 1, context);
> }
>
> -bool is_timing_changed(struct dc_stream_state *cur_stream,
> +bool dc_is_timing_changed(struct dc_stream_state *cur_stream,
> struct dc_stream_state *new_stream)
> {
> if (cur_stream == NULL)
> @@ -1880,7 +1880,7 @@ static bool are_stream_backends_same(
> if (stream_a == NULL || stream_b == NULL)
> return false;
>
> - if (is_timing_changed(stream_a, stream_b))
> + if (dc_is_timing_changed(stream_a, stream_b))
> return false;
>
> if (stream_a->signal != stream_b->signal)
> @@ -3505,7 +3505,7 @@ bool pipe_need_reprogram(
> if (pipe_ctx_old->stream_res.stream_enc != pipe_ctx->stream_res.stream_enc)
> return true;
>
> - if (is_timing_changed(pipe_ctx_old->stream, pipe_ctx->stream))
> + if (dc_is_timing_changed(pipe_ctx_old->stream, pipe_ctx->stream))
> return true;
>
> if (pipe_ctx_old->stream->dpms_off != pipe_ctx->stream->dpms_off)
> diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h
> index 23ee63b98dcd..e7ab6cb3769b 100644
> --- a/drivers/gpu/drm/amd/display/dc/dc.h
> +++ b/drivers/gpu/drm/amd/display/dc/dc.h
> @@ -2225,4 +2225,7 @@ void dc_process_dmub_dpia_hpd_int_enable(const struct dc *dc,
> /* Disable acc mode Interfaces */
> void dc_disable_accelerated_mode(struct dc *dc);
>
> +bool dc_is_timing_changed(struct dc_stream_state *cur_stream,
> + struct dc_stream_state *new_stream);
> +
> #endif /* DC_INTERFACE_H_ */
--
Hamza
prev parent reply other threads:[~2023-04-18 14:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-17 22:07 Arnd Bergmann
2023-04-18 13:23 ` Aurabindo Pillai
2023-04-18 14:17 ` Hamza Mahfooz [this message]
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=9f3e7030-c439-b8fe-7d30-80b11f4d06bb@amd.com \
--to=hamza.mahfooz@amd.com \
--cc=Alvin.Lee2@amd.com \
--cc=Aric.Cyr@amd.com \
--cc=Aurabindo.Pillai@amd.com \
--cc=HaoPing.Liu@amd.com \
--cc=Jerry.Zuo@amd.com \
--cc=Jun.Lei@amd.com \
--cc=Rodrigo.Siqueira@amd.com \
--cc=Wayne.Lin@amd.com \
--cc=Xinhui.Pan@amd.com \
--cc=airlied@gmail.com \
--cc=alex.hung@amd.com \
--cc=alexander.deucher@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=arnd@arndb.de \
--cc=arnd@kernel.org \
--cc=christian.koenig@amd.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=harry.wentland@amd.com \
--cc=hersenxs.wu@amd.com \
--cc=jdhillon@amd.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lyude@redhat.com \
--cc=mario.kleiner.de@gmail.com \
--cc=qingqing.zhuo@amd.com \
--cc=roman.li@amd.com \
--cc=sunpeng.li@amd.com \
--cc=wenjing.liu@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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®