drm/amd/display/dc/link/protocols/link_dp_capability: Remove unused variable and...
authorLee Jones <lee@kernel.org>
Fri, 17 Mar 2023 08:17:13 +0000 (08:17 +0000)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 22 Mar 2023 04:48:00 +0000 (00:48 -0400)
commit14af917998a6126494423f8820a93982025c6963
tree31b1a38643e158602a7def94fe0a8a939f3ed26c
parent7afe3521bd405d878bc5f9b98d5db4682bcdf3a5
drm/amd/display/dc/link/protocols/link_dp_capability: Remove unused variable and mark another as __maybe_unused

‘ds_port’ is clearly not used anywhere and ‘result_write_min_hblank’ is
only utilised when debugging is enabled.  The alternative would be to
allocate the variable under the same clause as the debugging code, but
that would become very messy, very quickly.

Fixes the following W=1 kernel build warning(s):

 drivers/gpu/drm/amd/amdgpu/../display/dc/link/protocols/link_dp_capability.c: In function ‘dp_wa_power_up_0010FA’:
 drivers/gpu/drm/amd/amdgpu/../display/dc/link/protocols/link_dp_capability.c:280:42: warning: variable ‘ds_port’ set but not used [-Wunused-but-set-variable]
 drivers/gpu/drm/amd/amdgpu/../display/dc/link/protocols/link_dp_capability.c: In function ‘dpcd_set_source_specific_data’:
 drivers/gpu/drm/amd/amdgpu/../display/dc/link/protocols/link_dp_capability.c:1296:32: warning: variable ‘result_write_min_hblank’ set but not used [-Wunused-but-set-variable]

Cc: Harry Wentland <harry.wentland@amd.com>
Cc: Leo Li <sunpeng.li@amd.com>
Cc: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: "Christian König" <christian.koenig@amd.com>
Cc: "Pan, Xinhui" <Xinhui.Pan@amd.com>
Cc: David Airlie <airlied@gmail.com>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Wenjing Liu <wenjing.liu@amd.com>
Cc: amd-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Lee Jones <lee@kernel.org>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c