drm/amd/display: Fix Compiler warnings in dmub

[Why]
Resolve compiler warnings by marking unused parameters explicitly.

[How]
In .c and .h files, keep parameter names in signatures and add a
line with`(void)param;`  inside the function body

Preserved function signatures and avoids breaking code paths that
may reference the parameter under conditional compilation.

Reviewed-by: Aric Cyr <aric.cyr@amd.com>
Signed-off-by: Gaghik Khachatrian <gaghik.khachatrian@amd.com>
Signed-off-by: Chuanyu Tseng <chuanyu.tseng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Gaghik Khachatrian 2026-03-07 18:37:04 -05:00 committed by Alex Deucher
parent f82480fafe
commit c3f327a9a3
8 changed files with 11 additions and 0 deletions

View File

@ -194,6 +194,7 @@ void dmub_dcn20_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)region6;
union dmub_addr offset;
uint64_t fb_base, fb_offset;
@ -396,6 +397,7 @@ union dmub_fw_boot_status dmub_dcn20_get_fw_boot_status(struct dmub_srv *dmub)
void dmub_dcn20_enable_dmub_boot_options(struct dmub_srv *dmub, const struct dmub_srv_hw_params *params)
{
(void)params;
union dmub_fw_boot_options boot_options = {0};
REG_WRITE(DMCUB_SCRATCH14, boot_options.all);

View File

@ -127,6 +127,7 @@ void dmub_dcn30_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)region6;
union dmub_addr offset;
/* sienna_cichlid has hardwired virtual addressing for CW2-CW7 */

View File

@ -195,6 +195,8 @@ void dmub_dcn31_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)cw2;
(void)region6;
union dmub_addr offset;
offset = cw3->offset;

View File

@ -237,6 +237,8 @@ void dmub_dcn32_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)cw2;
(void)region6;
union dmub_addr offset;
offset = cw3->offset;

View File

@ -222,6 +222,7 @@ void dmub_dcn35_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)cw2;
union dmub_addr offset;
offset = cw3->offset;

View File

@ -213,6 +213,7 @@ void dmub_dcn401_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)cw2;
union dmub_addr offset;
offset = cw3->offset;

View File

@ -229,6 +229,7 @@ void dmub_dcn42_setup_windows(struct dmub_srv *dmub,
const struct dmub_window *cw6,
const struct dmub_window *region6)
{
(void)cw2;
union dmub_addr offset;
offset = cw3->offset;

View File

@ -45,6 +45,7 @@ static void set_reg_field_values(struct dmub_reg_value_masks *field_value_mask,
uint32_t mask1, uint32_t field_value1,
va_list ap)
{
(void)addr;
uint32_t shift, mask, field_value;
int i = 1;