Thank you for your contribution! Sashiko AI review found 2 potential issues to consider: - [Medium] drm/msm/dpu: conflicting TOP0 IRQ bits for intf_6..intf_10 in nord_intf - [Medium] drm/msm/dpu: conflicting intr_wb_done IRQ bit for WB_1 in nord_wb --
commit 709b4002519e598fd50a422d47d34116fa23e078 Author: Mahadevan P <[email protected]> drm/msm/dpu: Add support for DPU 12.1 on Nord This commit adds the DPU 12.1 hardware catalog entry for the Qualcomm Nord SoC and registers the qcom,nord-dpu compatible string in dpu_kms. > diff --git a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_12_1_nord.h > b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_12_1_nord.h > new file mode 100644 > index 0000000000000..333eccb5c603a > --- /dev/null > +++ b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_12_1_nord.h [ ... ] > +static const struct dpu_wb_cfg nord_wb[] = { > + { > + .name = "wb_1", .id = WB_1, > + .base = 0x64800, .len = 0x2c8, > + .features = WB_SDM845_MASK, > + .format_list = wb2_formats_rgb_yuv, > + .num_formats = ARRAY_SIZE(wb2_formats_rgb_yuv), > + .xin_id = 7, > + .maxlinewidth = 4096, > + .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 3), > + }, { > + .name = "wb_2", .id = WB_2, > + .base = 0x65000, .len = 0x2c8, > + .features = WB_SDM845_MASK, > + .format_list = wb2_formats_rgb_yuv, > + .num_formats = ARRAY_SIZE(wb2_formats_rgb_yuv), > + .xin_id = 6, > + .maxlinewidth = 4096, > + .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 4), > + }, > +}; [Severity: Medium] Should wb_1 use MDP_SSPP_TOP0_INTR bit 1 instead of bit 3 for intr_wb_done? In drivers/gpu/drm/msm/registers/display/mdp5.xml (MDP5_IRQ), WB_1_DONE is bit 1 and WB_2_DONE is bit 4, while bit 3 is WD_TIMER_1_DONE. With bit 3 configured here, writeback completion on WB_1 will wait on the wrong IRQ status bit and time out once _dpu_kms_setup_displays() initializes writeback blocks other than WB_2. [ ... ] > +static const struct dpu_intf_cfg nord_intf[] = { [ ... ] > + }, { > + .name = "intf_6", .id = INTF_6, > + .base = 0x3a000, .len = 0x4bc, > + .type = INTF_DP, > + .controller_id = MSM_DP_CONTROLLER_0, > + .prog_fetch_lines_worst_case = 24, > + .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 22), > + .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 23), > + }, { > + .name = "intf_7", .id = INTF_7, > + .base = 0x3b000, .len = 0x4bc, > + .type = INTF_DP, > + .controller_id = MSM_DP_CONTROLLER_0, > + .prog_fetch_lines_worst_case = 24, > + .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 0), > + .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 1), > + }, { > + .name = "intf_8", .id = INTF_8, > + .base = 0x3c000, .len = 0x4bc, > + .type = INTF_DP, > + .controller_id = MSM_DP_CONTROLLER_1, > + .prog_fetch_lines_worst_case = 24, > + .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 2), > + .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 3), > + }, { > + .name = "intf_9", .id = INTF_9, > + .base = 0x3d000, .len = 0x4bc, > + .type = INTF_DP, > + .controller_id = MSM_DP_CONTROLLER_1, > + .prog_fetch_lines_worst_case = 24, > + .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 4), > + .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 5), > + }, { > + .name = "intf_10", .id = INTF_10, > + .base = 0x3e000, .len = 0x4bc, > + .type = INTF_DP, > + .controller_id = MSM_DP_CONTROLLER_1, > + .prog_fetch_lines_worst_case = 24, > + .intr_underrun = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 6), > + .intr_vsync = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR2, 7), > + }, > +}; [Severity: Medium] Are the intr_underrun and intr_vsync IRQ indices for intf_6 through intf_10 correct for Nord hardware? In sibling multi-DP catalogs like dpu_12_2_glymur.h and dpu_8_4_sa8775p.h (which also omits INTF_5), MDP_SSPP_TOP0_INTR bits 22/23 belong to INTF_5, while INTF_6, INTF_7, and INTF_8 use bits 16/17, 18/19, and 12/13. Here intf_6 is placed in INTF_5's slot and intf_7 through intf_10 use MDP_SSPP_TOP0_INTR2 bits 0 through 7, which no other DPU catalog uses for interface interrupts. If these bits do not match the Nord interrupt map, VSYNC and underrun IRQs on intf_6 through intf_10 will never fire when secondary interfaces are used (such as for DP MST), causing vblank waits and dpu_encoder_phys_vid_wait_for_tx_complete() to fail with -ETIMEDOUT. -- Sashiko AI review ยท https://sashiko.dev/#/patchset/[email protected]?part=6
