mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hamza Mahfooz <hamza.mahfooz@amd.com>
To: Tom Rix <trix@redhat.com>,
	harry.wentland@amd.com, sunpeng.li@amd.com,
	Rodrigo.Siqueira@amd.com, alexander.deucher@amd.com,
	christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com,
	daniel@ffwll.ch, nathan@kernel.org, ndesaulniers@google.com,
	Jun.Lei@amd.com, wenjing.liu@amd.com, Jimmy.Kizito@amd.com,
	Cruise.Hung@amd.com
Cc: llvm@lists.linux.dev, dri-devel@lists.freedesktop.org,
	amd-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/amd/display: remove unused matching_stream_ptrs variable
Date: Mon, 10 Apr 2023 10:47:46 -0400	[thread overview]
Message-ID: <c4fbb44b-ed31-96b2-2342-b654299f72dc@amd.com> (raw)
In-Reply-To: <20230325134503.1335510-1-trix@redhat.com>

On 3/25/23 09:45, Tom Rix wrote:
> clang with W=1 reports
> drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc_link_enc_cfg.c:625:6: error:
>    variable 'matching_stream_ptrs' set but not used [-Werror,-Wunused-but-set-variable]
>          int matching_stream_ptrs = 0;
>              ^
> This variable is not used so remove it.
> 
> Signed-off-by: Tom Rix <trix@redhat.com>

Applied, thanks!

> ---
>   drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c | 5 +----
>   1 file changed, 1 insertion(+), 4 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c b/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c
> index 41198c729d90..30c0644d4418 100644
> --- a/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c
> +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link_enc_cfg.c
> @@ -622,7 +622,6 @@ bool link_enc_cfg_validate(struct dc *dc, struct dc_state *state)
>   	int i, j;
>   	uint8_t valid_count = 0;
>   	uint8_t dig_stream_count = 0;
> -	int matching_stream_ptrs = 0;
>   	int eng_ids_per_ep_id[MAX_PIPES] = {0};
>   	int ep_ids_per_eng_id[MAX_PIPES] = {0};
>   	int valid_bitmap = 0;
> @@ -645,9 +644,7 @@ bool link_enc_cfg_validate(struct dc *dc, struct dc_state *state)
>   		struct link_enc_assignment assignment = state->res_ctx.link_enc_cfg_ctx.link_enc_assignments[i];
>   
>   		if (assignment.valid) {
> -			if (assignment.stream == state->streams[i])
> -				matching_stream_ptrs++;
> -			else
> +			if (assignment.stream != state->streams[i])
>   				valid_stream_ptrs = false;
>   		}
>   	}
-- 
Hamza


      parent reply	other threads:[~2023-04-10 14:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-25 13:45 Tom Rix
2023-04-07 17:52 ` Nick Desaulniers
2023-04-07 18:29   ` Nick Desaulniers
2023-04-10 14:47 ` 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=c4fbb44b-ed31-96b2-2342-b654299f72dc@amd.com \
    --to=hamza.mahfooz@amd.com \
    --cc=Cruise.Hung@amd.com \
    --cc=Jimmy.Kizito@amd.com \
    --cc=Jun.Lei@amd.com \
    --cc=Rodrigo.Siqueira@amd.com \
    --cc=Xinhui.Pan@amd.com \
    --cc=airlied@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=christian.koenig@amd.com \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=harry.wentland@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=nathan@kernel.org \
    --cc=ndesaulniers@google.com \
    --cc=sunpeng.li@amd.com \
    --cc=trix@redhat.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®