From: Pu Lehui <pulehui@huawei.com>
To: <harry.wentland@amd.com>, <sunpeng.li@amd.com>,
<alexander.deucher@amd.com>, <christian.koenig@amd.com>,
<Xinhui.Pan@amd.com>, <airlied@linux.ie>, <daniel@ffwll.ch>,
<Anson.Jacob@amd.com>, <Nicholas.Kazlauskas@amd.com>,
<roman.li@amd.com>
Cc: <amd-gfx@lists.freedesktop.org>,
<dri-devel@lists.freedesktop.org>, <linux-kernel@vger.kernel.org>,
<pulehui@huawei.com>, <zhangjinhao2@huawei.com>
Subject: [PATCH -next] drm/amd/display: remove unused variable 'dc'
Date: Thu, 17 Jun 2021 09:16:32 +0800 [thread overview]
Message-ID: <20210617011632.187690-1-pulehui@huawei.com> (raw)
GCC reports the following warning with W=1:
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/amdgpu_dm_psr.c:70:13:
warning:
variable ‘dc’ set but not used [-Wunused-but-set-variable]
70 | struct dc *dc = NULL;
| ^~
This variable is not used in function, this commit remove it to
fix the warning.
Signed-off-by: Pu Lehui <pulehui@huawei.com>
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_psr.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_psr.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_psr.c
index f7c77ae0d965..70a554f1e725 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_psr.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_psr.c
@@ -67,14 +67,12 @@ bool amdgpu_dm_link_setup_psr(struct dc_stream_state *stream)
struct dc_link *link = NULL;
struct psr_config psr_config = {0};
struct psr_context psr_context = {0};
- struct dc *dc = NULL;
bool ret = false;
if (stream == NULL)
return false;
link = stream->link;
- dc = link->ctx->dc;
psr_config.psr_version = link->dpcd_caps.psr_caps.psr_version;
--
2.17.1
next reply other threads:[~2021-06-17 1:15 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-17 1:16 Pu Lehui [this message]
2021-06-17 19:04 ` Harry Wentland
2021-06-18 20:34 ` Alex Deucher
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=20210617011632.187690-1-pulehui@huawei.com \
--to=pulehui@huawei.com \
--cc=Anson.Jacob@amd.com \
--cc=Nicholas.Kazlauskas@amd.com \
--cc=Xinhui.Pan@amd.com \
--cc=airlied@linux.ie \
--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=roman.li@amd.com \
--cc=sunpeng.li@amd.com \
--cc=zhangjinhao2@huawei.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®