From: Dan Carpenter <dan.carpenter@oracle.com>
To: Alvin.Lee2@amd.com
Cc: amd-gfx@lists.freedesktop.org
Subject: [bug report] drm/amd/display: Add SubVP required code
Date: Mon, 1 Aug 2022 17:54:28 +0300 [thread overview]
Message-ID: <YufpJKgAqUWP655T@kili> (raw)
Hello Alvin Lee,
The patch 85f4bc0c333c: "drm/amd/display: Add SubVP required code"
from May 2, 2022, leads to the following Smatch static checker
warning:
drivers/gpu/drm/amd/amdgpu/../display/dc/clk_mgr/dcn32/dcn32_clk_mgr_smu_msg.c:103 dcn32_smu_send_cab_for_uclk_message()
warn: was shift intended here '(num_ways > 0)'
drivers/gpu/drm/amd/amdgpu/../display/dc/clk_mgr/dcn32/dcn32_clk_mgr_smu_msg.c
101 void dcn32_smu_send_cab_for_uclk_message(struct clk_mgr_internal *clk_mgr, unsigned int num_ways)
102 {
--> 103 uint32_t param = (num_ways << 1) | (num_ways > 0);
What is happening here? It might be more readable as?
uint32_t param = (num_ways << 1) | (num_ways != 0);
Still confusing actually...
104
105 dcn32_smu_send_msg_with_param(clk_mgr, DALSMC_MSG_SetCabForUclkPstate, param, NULL);
106 smu_print("Numways for SubVP : %d\n", num_ways);
107 }
regards,
dan carpenter
reply other threads:[~2022-08-01 14:54 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=YufpJKgAqUWP655T@kili \
--to=dan.carpenter@oracle.com \
--cc=Alvin.Lee2@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
/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