Skip to content

video-driver: monaco: split context banks and attach to iommu - #145

Merged
vgarodia merged 1 commit into
qualcomm-linux:video.qclinux.mainfrom
gouravk-qualcomm:iommu-fix
Aug 27, 2026
Merged

video-driver: monaco: split context banks and attach to iommu#145
vgarodia merged 1 commit into
qualcomm-linux:video.qclinux.mainfrom
gouravk-qualcomm:iommu-fix

Conversation

@gouravk-qualcomm

@gouravk-qualcomm gouravk-qualcomm commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

monaco's context-bank table declared a single combined non-secure bank
and relied on the parent video-codec platform device's iommu domain
already being attached. This caused msm_vidc_probe_without_context_bank
to fail with "Failed to get iommu domain for aa00000.video-codec", which
in turn failed the component master bind and video-codec probe.

Split the non-secure bank into separate bitstream (qcom,vidc,cb-ns) and
pixel (qcom,vidc,cb-ns-pxl) entries, matching monaco.dtsi's non-pixel/
pixel context-bank subnodes. Add msm_vidc_monaco_init_cb_devs(), wired
via .init_cb_devs, to create a dedicated child device per bank and
explicitly attach each to its own iommu entry. The secure bank
(qcom,vidc,cb-sec-non-pxl) is intentionally left unmapped.

The cb-ns-pxl and cb-sec-non-pxl address ranges are carried over from
the equivalent lemans split, since monaco's original combined-row values
were identical to lemans's pre-split values.

Signed-off-by: Gourav Kumar gouravk@qti.qualcomm.com

@gouravk-qualcomm
gouravk-qualcomm force-pushed the iommu-fix branch 3 times, most recently from 745b5dd to 086b239 Compare August 27, 2026 10:15
@gouravk-qualcomm gouravk-qualcomm changed the title video-driver: monaco: attach non-secure context bank to iommu video-driver: monaco: split context banks and attach to iommu Aug 27, 2026
Comment thread driver/platform/monaco/src/monaco.c Outdated
MSM_VIDC_NON_SECURE | MSM_VIDC_NON_SECURE_BITSTREAM, 0},
{"qcom,vidc,cb-ns-pxl", 0x00100000, 0xdff00000, 0, 1,
MSM_VIDC_NON_SECURE_PIXEL, 0},
{"qcom,vidc,cb-sec-non-pxl", 0x01400000, 0x24400000, 1, 0,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

0x01400000 -> 0x01000000
0x24400000 -> 0x24800000

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks ,
cb-sec-non-pxl changed to 0x01000000 / 0x24800000.

The context-bank table declared a single combined non-secure bank and
relied on the parent video-codec device's iommu domain already being
attached, causing msm_vidc_probe_without_context_bank to fail with
"Failed to get iommu domain for aa00000.video-codec".

Split the non-secure bank into separate bitstream and pixel entries and
add msm_vidc_monaco_init_cb_devs() to create a dedicated child device for
each, explicitly attaching it to its own iommu entry. The secure bank is
intentionally left unmapped.

Signed-off-by: Gourav Kumar <gouravk@qti.qualcomm.com>
@vgarodia
vgarodia merged commit ba6d852 into qualcomm-linux:video.qclinux.main Aug 27, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants