[PATCH 9/9] drm/msm/dpu: sync mode_config limits to the FB limits in dpu_plane.c
Abhinav Kumar
quic_abhinavk at quicinc.com
Sat Apr 20 03:58:05 UTC 2024
On 4/19/2024 8:06 PM, Dmitry Baryshkov wrote:
> On Sat, 20 Apr 2024 at 06:05, Abhinav Kumar <quic_abhinavk at quicinc.com> wrote:
>>
>>
>>
>> On 3/19/2024 6:22 AM, Dmitry Baryshkov wrote:
>>> Lift mode_config limits set by the DPU driver to the actual FB limits as
>>> handled by the dpu_plane.c.
>>>
>>> Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov at linaro.org>
>>> ---
>>> drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 9 ++-------
>>> 1 file changed, 2 insertions(+), 7 deletions(-)
>>>
>>> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
>>> index 7257ac4020d8..e7dda9eca466 100644
>>> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
>>> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c
>>> @@ -1136,13 +1136,8 @@ static int dpu_kms_hw_init(struct msm_kms *kms)
>>> dev->mode_config.min_width = 0;
>>> dev->mode_config.min_height = 0;
>>>
>>> - /*
>>> - * max crtc width is equal to the max mixer width * 2 and max height is
>>> - * is 4K
>>> - */
>>> - dev->mode_config.max_width =
>>> - dpu_kms->catalog->caps->max_mixer_width * 2;
>>> - dev->mode_config.max_height = 4096;
>>> + dev->mode_config.max_width = DPU_MAX_IMG_WIDTH;
>>> + dev->mode_config.max_height = DPU_MAX_IMG_HEIGHT;
>>>
>>
>> Can you please explain a little more about why the previous limits did
>> not work in the multi-monitor case?
>>
>> We support at the most using 2 LMs per display today. Quad pipe support
>> is not there yet. So by bounding to 2 * mixer_width should have been
>> same as rejecting the mixer width in atomic_check.
>
> This is the framebuffer limit, not a CRTC size limit.
>
As discussed on IRC, the DRM fwk uses this to limit the modes on the
connector, please check
2922 if (out_resp->count_modes == 0) {
2923 if (is_current_master)
2924 connector->funcs->fill_modes(connector,
2925 dev->mode_config.max_width,
2926 dev->mode_config.max_height);
2927 else
2928 drm_dbg_kms(dev, "User-space requested a forced probe on
[CONNECTOR:%d:%s] but is not the DRM master, demoting to read-only probe",
2929 connector->base.id, connector->name);
2930 }
So the documentation of this doesnt really align with the usage.
Unless we alter these pieces, I am hesitant to ack this.
>>
>>> dev->max_vblank_count = 0xffffffff;
>>> /* Disable vblank irqs aggressively for power-saving */
>>>
>
>
>
More information about the Freedreno
mailing list