[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202207060929.RfKy9h57-lkp@intel.com>
Date: Wed, 6 Jul 2022 09:44:33 +0800
From: kernel test robot <lkp@...el.com>
To: Alvin Lee <Alvin.Lee2@....com>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
Alex Deucher <alexander.deucher@....com>,
Jun Lei <Jun.Lei@....com>
Subject: [agd5f:drm-next 341/388]
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_hwseq.c:428:33:
warning: variable 'old_pipe' set but not used
tree: https://gitlab.freedesktop.org/agd5f/linux.git drm-next
head: fc25fd602b1e101a45650475a8d2f00d7bb8e971
commit: 85f4bc0c333ceed24cbc9f69a2a77fab1ae3d4d1 [341/388] drm/amd/display: Add SubVP required code
config: i386-allyesconfig (https://download.01.org/0day-ci/archive/20220706/202207060929.RfKy9h57-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
git remote add agd5f https://gitlab.freedesktop.org/agd5f/linux.git
git fetch --no-tags agd5f drm-next
git checkout 85f4bc0c333ceed24cbc9f69a2a77fab1ae3d4d1
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash drivers/gpu/drm/
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@...el.com>
All warnings (new ones prefixed by >>):
drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_hwseq.c: In function 'dcn32_subvp_pipe_control_lock':
>> drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_hwseq.c:428:33: warning: variable 'old_pipe' set but not used [-Wunused-but-set-variable]
428 | struct pipe_ctx *pipe, *old_pipe;
| ^~~~~~~~
In file included from drivers/gpu/drm/amd/amdgpu/../display/dc/inc/core_types.h:32,
from drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_hwseq.c:29:
At top level:
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:137:22: warning: 'SYNAPTICS_DEVICE_ID' defined but not used [-Wunused-const-variable=]
137 | static const uint8_t SYNAPTICS_DEVICE_ID[] = "SYNA";
| ^~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:134:17: warning: 'DP_SINK_BRANCH_DEV_NAME_7580' defined but not used [-Wunused-const-variable=]
134 | static const u8 DP_SINK_BRANCH_DEV_NAME_7580[] = "7580\x80u";
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:132:22: warning: 'DP_SINK_DEVICE_STR_ID_2' defined but not used [-Wunused-const-variable=]
132 | static const uint8_t DP_SINK_DEVICE_STR_ID_2[] = {7, 1, 8, 7, 5, 0};
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:131:22: warning: 'DP_SINK_DEVICE_STR_ID_1' defined but not used [-Wunused-const-variable=]
131 | static const uint8_t DP_SINK_DEVICE_STR_ID_1[] = {7, 1, 8, 7, 3, 0};
| ^~~~~~~~~~~~~~~~~~~~~~~
--
>> drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_resource_helpers.c:47:6: warning: no previous prototype for 'dcn32_helper_populate_phantom_dlg_params' [-Wmissing-prototypes]
47 | void dcn32_helper_populate_phantom_dlg_params(struct dc *dc,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/amd/amdgpu/../display/dc/inc/core_types.h:32,
from drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_resource.h:29,
from drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_resource_helpers.c:27:
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:137:22: warning: 'SYNAPTICS_DEVICE_ID' defined but not used [-Wunused-const-variable=]
137 | static const uint8_t SYNAPTICS_DEVICE_ID[] = "SYNA";
| ^~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:134:17: warning: 'DP_SINK_BRANCH_DEV_NAME_7580' defined but not used [-Wunused-const-variable=]
134 | static const u8 DP_SINK_BRANCH_DEV_NAME_7580[] = "7580\x80u";
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:132:22: warning: 'DP_SINK_DEVICE_STR_ID_2' defined but not used [-Wunused-const-variable=]
132 | static const uint8_t DP_SINK_DEVICE_STR_ID_2[] = {7, 1, 8, 7, 5, 0};
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:131:22: warning: 'DP_SINK_DEVICE_STR_ID_1' defined but not used [-Wunused-const-variable=]
131 | static const uint8_t DP_SINK_DEVICE_STR_ID_1[] = {7, 1, 8, 7, 3, 0};
| ^~~~~~~~~~~~~~~~~~~~~~~
--
>> drivers/gpu/drm/amd/amdgpu/../display/dc/dc_dmub_srv.c:549:6: warning: no previous prototype for 'dc_dmub_setup_subvp_dmub_command' [-Wmissing-prototypes]
549 | void dc_dmub_setup_subvp_dmub_command(struct dc *dc,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/amd/amdgpu/../display/dc/inc/core_types.h:32,
from drivers/gpu/drm/amd/amdgpu/../display/dc/dc_dmub_srv.c:31:
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:137:22: warning: 'SYNAPTICS_DEVICE_ID' defined but not used [-Wunused-const-variable=]
137 | static const uint8_t SYNAPTICS_DEVICE_ID[] = "SYNA";
| ^~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:134:17: warning: 'DP_SINK_BRANCH_DEV_NAME_7580' defined but not used [-Wunused-const-variable=]
134 | static const u8 DP_SINK_BRANCH_DEV_NAME_7580[] = "7580\x80u";
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:132:22: warning: 'DP_SINK_DEVICE_STR_ID_2' defined but not used [-Wunused-const-variable=]
132 | static const uint8_t DP_SINK_DEVICE_STR_ID_2[] = {7, 1, 8, 7, 5, 0};
| ^~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/include/ddc_service_types.h:131:22: warning: 'DP_SINK_DEVICE_STR_ID_1' defined but not used [-Wunused-const-variable=]
131 | static const uint8_t DP_SINK_DEVICE_STR_ID_1[] = {7, 1, 8, 7, 3, 0};
| ^~~~~~~~~~~~~~~~~~~~~~~
vim +/old_pipe +428 drivers/gpu/drm/amd/amdgpu/../display/dc/dcn32/dcn32_hwseq.c
410
411 /* Sub-Viewport DMUB lock needs to be acquired by driver whenever SubVP is active and:
412 * 1. Any full update for any SubVP main pipe
413 * 2. Any immediate flip for any SubVP pipe
414 * 3. Any flip for DRR pipe
415 * 4. If SubVP was previously in use (i.e. in old context)
416 */
417 void dcn32_subvp_pipe_control_lock(struct dc *dc,
418 struct dc_state *context,
419 bool lock,
420 bool should_lock_all_pipes,
421 struct pipe_ctx *top_pipe_to_program,
422 bool subvp_prev_use)
423 {
424 unsigned int i = 0;
425 bool subvp_immediate_flip = false;
426 bool subvp_in_use = false;
427 bool drr_pipe = false;
> 428 struct pipe_ctx *pipe, *old_pipe;
429
430 for (i = 0; i < dc->res_pool->pipe_count; i++) {
431 pipe = &context->res_ctx.pipe_ctx[i];
432 old_pipe = &dc->current_state->res_ctx.pipe_ctx[i];
433
434 if (pipe->stream && pipe->plane_state && pipe->stream->mall_stream_config.type == SUBVP_MAIN) {
435 subvp_in_use = true;
436 break;
437 }
438 }
439
440 if (top_pipe_to_program && top_pipe_to_program->stream && top_pipe_to_program->plane_state) {
441 if (top_pipe_to_program->stream->mall_stream_config.type == SUBVP_MAIN &&
442 top_pipe_to_program->plane_state->flip_immediate)
443 subvp_immediate_flip = true;
444 else if (top_pipe_to_program->stream->mall_stream_config.type == SUBVP_NONE &&
445 top_pipe_to_program->stream->ignore_msa_timing_param)
446 drr_pipe = true;
447 }
448
449 if ((subvp_in_use && (should_lock_all_pipes || subvp_immediate_flip || drr_pipe)) || (!subvp_in_use && subvp_prev_use)) {
450 union dmub_inbox0_cmd_lock_hw hw_lock_cmd = { 0 };
451
452 if (!lock) {
453 for (i = 0; i < dc->res_pool->pipe_count; i++) {
454 pipe = &context->res_ctx.pipe_ctx[i];
455 if (pipe->stream && pipe->plane_state && pipe->stream->mall_stream_config.type == SUBVP_MAIN &&
456 should_lock_all_pipes)
457 pipe->stream_res.tg->funcs->wait_for_state(pipe->stream_res.tg, CRTC_STATE_VBLANK);
458 }
459 }
460
461 hw_lock_cmd.bits.command_code = DMUB_INBOX0_CMD__HW_LOCK;
462 hw_lock_cmd.bits.hw_lock_client = HW_LOCK_CLIENT_DRIVER;
463 hw_lock_cmd.bits.lock = lock;
464 hw_lock_cmd.bits.should_release = !lock;
465 dmub_hw_lock_mgr_inbox0_cmd(dc->ctx->dmub_srv, hw_lock_cmd);
466 }
467 }
468
--
0-DAY CI Kernel Test Service
https://01.org/lkp
Powered by blists - more mailing lists