<div dir="ltr">Hi scott<div><br></div><div>yes, one CRTC bind to one primary plane. But if not all the crtcs are connected and universal planes is enable, the spare primary plane could be an overlay plane.</div><div><br></div><div>for example, plane 0 ~ 5 for 6 CRTCs, they are all primary planes. But weston only enable 3 output, then plane 3 ~ 5 could treat as overlay plane.</div><div><br></div><div>Thank you!</div><div><br></div><div>Best regards</div><div>Nancy</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Scott Anderson <<a href="mailto:scott.anderson@collabora.com">scott.anderson@collabora.com</a>> 于2019年9月17日周二 下午3:50写道:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 17/09/19 7:38 pm, zou lan wrote:<br>
> Hi Daniel & all<br>
> <br>
> I find the function drm_output_prepare_overlay_view() only use the plane <br>
> type of WDRM_PLANE_TYPE_OVERLAY. it could be a waste for some planes of <br>
> type WDRM_PLANE_TYPE_PRIMARY if the universal planes is enable.<br>
> <br>
> For example, the kernel define 6 crtcs, and each crtc will have one <br>
> primary type plane, but not all of the crtcs are used by weston_output. <br>
> Some crtcs may never used, if we reserve all the primary type planes as <br>
> scanout plane, that could waste some of them.<br>
> <br>
> Could the open source drm backend modify the logic of judge the overlay <br>
> plane? let the primary plane equal to overlay plane or judge in <br>
> drm_output_prepare_overlay_view(), if the plane is not used by outputs, <br>
> it could be used by overlay?<br>
> <br>
> Thank you!<br>
> <br>
> Best regards<br>
> Nancy<br>
Hi,<br>
<br>
As far as I'm aware, the kernel never advertises more than one primary <br>
plane per CRTC and they're never possible to be used with multiple <br>
CRTCs: <br>
<a href="https://www.kernel.org/doc/html/latest/gpu/drm-kms.html#plane-abstraction" rel="noreferrer" target="_blank">https://www.kernel.org/doc/html/latest/gpu/drm-kms.html#plane-abstraction</a><br>
<br>
>All drivers should provide one primary plane per CRTC to avoid <br>
surprising userspace too much<br>
<br>
Perhaps that restriction is not as strict as I interpret it to be, but <br>
I'm not aware of anything which does not have a one-to-one relationship <br>
between primary planes and CRTCs.<br>
<br>
Scott<br>
</blockquote></div>