Skip to contentSkip to conversation

drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c:1087:5-49: duplicated argument to && or ||

DISCUSSION kernel test robot 1 participant 1 message Jul 14, 2025

lore
Share & tools
lore

kernel test robot

author build bot
#0 lore raw
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   347e9f5043c89695b01e66b3ed111755afcf1911
commit: 8c62a31607f6589545ef1c0a85f2924dee39430b drm/msm/dpu: allow using two SSPP blocks for a single plane
date:   7 months ago
config: arm-randconfig-r064-20250714 (https://download.01.org/0day-ci/archive/20250715/[email protected]/config)
compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project 01c97b4953e87ae455bd4c41e3de3f0f0f29c61c)

If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

cocci warnings: (new ones prefixed by >>)

>> drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c:1087:5-49: duplicated argument to && or ||

vim +1087 drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c

1050
1051 static int dpu_plane_virtual_atomic_check(struct drm_plane *plane,
1052 struct drm_atomic_state *state)
1053 {
1054 struct drm_plane_state *plane_state =
1055 drm_atomic_get_plane_state(state, plane);
1056 struct drm_plane_state *old_plane_state =
1057 drm_atomic_get_old_plane_state(state, plane);
1058 struct dpu_plane_state *pstate = to_dpu_plane_state(plane_state);
1059 struct drm_crtc_state *crtc_state;
1060 int ret;
1061
1062 if (plane_state->crtc)
1063 crtc_state = drm_atomic_get_new_crtc_state(state,
1064 plane_state->crtc);
1065
1066 ret = dpu_plane_atomic_check_nosspp(plane, plane_state, crtc_state);
1067 if (ret)
1068 return ret;
1069
1070 if (!plane_state->visible) {
1071 /*
1072 * resources are freed by dpu_crtc_assign_plane_resources(),
1073 * but clean them here.
1074 */
1075 pstate->pipe.sspp = NULL;
1076 pstate->r_pipe.sspp = NULL;
1077
1078 return 0;
1079 }
1080
1081 /*
1082 * Force resource reallocation if the format of FB or src/dst have
1083 * changed. We might need to allocate different SSPP or SSPPs for this
1084 * plane than the one used previously.
1085 */
1086 if (!old_plane_state || !old_plane_state->fb ||

> 1087		    old_plane_state->src_w != plane_state->src_w ||
  1088		    old_plane_state->src_h != plane_state->src_h ||
  1089		    old_plane_state->src_w != plane_state->src_w ||
  1090		    old_plane_state->crtc_h != plane_state->crtc_h ||
  1091		    msm_framebuffer_format(old_plane_state->fb) !=
  1092		    msm_framebuffer_format(plane_state->fb))

1093 crtc_state->planes_changed = true;
1094
1095 return 0;
1096 }
1097

Signature · 2 lines
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki