[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAA8EJprNTUrh66yqaOCoReWdwLcBc9LfMm=WNDi54o9nzd8RRA@mail.gmail.com>
Date: Tue, 19 Oct 2021 18:52:51 +0300
From: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
To: Vinod Koul <vkoul@...nel.org>
Cc: Rob Clark <robdclark@...il.com>,
"open list:DRM DRIVER FOR MSM ADRENO GPU"
<linux-arm-msm@...r.kernel.org>,
Bjorn Andersson <bjorn.andersson@...aro.org>,
David Airlie <airlied@...ux.ie>,
Daniel Vetter <daniel@...ll.ch>,
Jonathan Marek <jonathan@...ek.ca>,
Abhinav Kumar <abhinavk@...eaurora.org>,
Jeffrey Hugo <jeffrey.l.hugo@...il.com>,
Sumit Semwal <sumit.semwal@...aro.org>,
open list <linux-kernel@...r.kernel.org>,
"open list:DRM DRIVER FOR MSM ADRENO GPU"
<dri-devel@...ts.freedesktop.org>,
freedreno <freedreno@...ts.freedesktop.org>
Subject: Re: [PATCH v2 04/11] drm/msm/disp/dpu1: Add DSC support in RM
On Tue, 19 Oct 2021 at 18:30, Vinod Koul <vkoul@...nel.org> wrote:
>
> On 14-10-21, 17:11, Dmitry Baryshkov wrote:
> > On 07/10/2021 10:08, Vinod Koul wrote:
>
> > > +static int _dpu_rm_reserve_dsc(struct dpu_rm *rm,
> > > + struct dpu_global_state *global_state,
> > > + struct drm_encoder *enc)
> > > +{
> > > + struct msm_drm_private *priv;
> > > +
> > > + priv = enc->dev->dev_private;
> > > +
> > > + if (!priv)
> > > + return -EIO;
> > > +
> > > + /* check if DSC is supported */
> > > + if (!priv->dsc)
> > > + return 0;
> > > +
> > > + /* check if DSC 0 & 1 and allocated or not */
> > > + if (global_state->dsc_to_enc_id[0] || global_state->dsc_to_enc_id[1]) {
> > > + DPU_ERROR("DSC 0|1 is already allocated\n");
> > > + return -EIO;
> > > + }
> > > +
> > > + global_state->dsc_to_enc_id[0] = enc->base.id;
> > > + global_state->dsc_to_enc_id[1] = enc->base.id;
> >
> > Still hardcoding DSC_0 and DSC_1.
>
> Yes!
>
> > Could you please add num_dsc to the topology and allocate the requested
> > amount of DSC blocks? Otherwise this would break for the DSI + DP case.
>
> It wont as we check for dsc and dont proceed, so it cant make an impact
> in non dsc case.
>
> Nevertheless I agree with you, so I am making it based on dsc defined in
> topology. Do we need additional field for num_dsc in topology, num_enc
> should be it, right?
I'd vote for the separate num_dsc.
--
With best wishes
Dmitry
Powered by blists - more mailing lists