From: Matthias Beyer <mail@beyermatthias.de>
To: linuxdev.baldrick@gmail.com
Cc: alexander.deucher@amd.com, christian.koenig@amd.com,
airlied@linux.ie, dri-devel@lists.freedesktop.org,
dcb314@hotmail.com, linux-kernel@vger.kernel.org,
Rex.Zhu@amd.com, JinHuiEric.Huang@amd.com,
nils.wallmenius@gmail.com, Matthias Beyer <mail@beyermatthias.de>
Subject: [PATCH] drivers: gpu: drm: amd: powerplay: hwmgr: Remove unused variable
Date: Thu, 30 Jun 2016 18:38:49 +0200 [thread overview]
Message-ID: <20160630163849.3914-2-mail@beyermatthias.de> (raw)
In-Reply-To: <20160630163849.3914-1-mail@beyermatthias.de>
In-Reply-To: <CAMzoambuSv7wFj-kzAp_7=2sBO-S+zLjnrxchMpkgprw8s_r2g@mail.gmail.com>
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
---
drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c
index 64ee78f..1dcd52d 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c
@@ -1761,7 +1761,7 @@ static int polaris10_populate_clock_stretcher_data_table(struct pp_hwmgr *hwmgr)
{
uint32_t ro, efuse, volt_without_cks, volt_with_cks, value, max, min;
struct polaris10_hwmgr *data = (struct polaris10_hwmgr *)(hwmgr->backend);
- uint8_t i, stretch_amount, stretch_amount2, volt_offset = 0;
+ uint8_t i, stretch_amount, volt_offset = 0;
struct phm_ppt_v1_information *table_info =
(struct phm_ppt_v1_information *)(hwmgr->pptable);
struct phm_ppt_v1_clock_voltage_dependency_table *sclk_table =
@@ -1806,11 +1806,8 @@ static int polaris10_populate_clock_stretcher_data_table(struct pp_hwmgr *hwmgr)
}
/* Populate CKS Lookup Table */
- if (stretch_amount == 1 || stretch_amount == 2 || stretch_amount == 5)
- stretch_amount2 = 0;
- else if (stretch_amount == 3 || stretch_amount == 4)
- stretch_amount2 = 1;
- else {
+ if (stretch_amount != 1 && stretch_amount != 2 && stretch_amount != 3 &&
+ stretch_amount != 4 && stretch_amount != 5) {
phm_cap_unset(hwmgr->platform_descriptor.platformCaps,
PHM_PlatformCaps_ClockStretcher);
PP_ASSERT_WITH_CODE(false,
--
2.9.0
next prev parent reply other threads:[~2016-06-30 16:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-27 10:00 drivers/gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.c:1812: possible pointless variable ? David Binderman
2016-06-30 16:38 ` [PATCH] Remove unused variable Matthias Beyer
2016-06-30 16:38 ` Matthias Beyer [this message]
[not found] ` <SN1PR12MB067228EF741040E0D92DB22BFB390@SN1PR12MB0672.namprd12.prod.outlook.com>
2016-07-14 17:22 ` [PATCH] drivers: gpu: drm: amd: powerplay: hwmgr: " Matthias Beyer
2016-07-15 15:46 ` 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=20160630163849.3914-2-mail@beyermatthias.de \
--to=mail@beyermatthias.de \
--cc=JinHuiEric.Huang@amd.com \
--cc=Rex.Zhu@amd.com \
--cc=airlied@linux.ie \
--cc=alexander.deucher@amd.com \
--cc=christian.koenig@amd.com \
--cc=dcb314@hotmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxdev.baldrick@gmail.com \
--cc=nils.wallmenius@gmail.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®