On Mon, Sep 24, 2018 at 12:22:28PM -0400, Bruce Wang wrote: > Remove unneeded checks from _dpu_plane_get_aspace. The function > no longer needs to return anything so it is changed to void. > > v3: Made return value of function struct msm_gem_address_space* instead > of passing one in to reflect the purpose of the function.
Oops - it looks like this actually didn't happen? Maybe an old version of the patch got out by accident. Jordan > Signed-off-by: Bruce Wang <bzw...@chromium.org> > --- > drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c | 19 +++---------------- > 1 file changed, 3 insertions(+), 16 deletions(-) > > diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c > b/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c > index 924e321a5ac4..2ed8bc741139 100644 > --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c > +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c > @@ -431,23 +431,14 @@ static void _dpu_plane_set_qos_remap(struct drm_plane > *plane) > /** > * _dpu_plane_get_aspace: gets the address space > */ > -static int _dpu_plane_get_aspace( > +static void _dpu_plane_get_aspace( > struct dpu_plane *pdpu, > struct dpu_plane_state *pstate, > struct msm_gem_address_space **aspace) > { > - struct dpu_kms *kms; > - > - if (!pdpu || !pstate || !aspace) { > - DPU_ERROR("invalid parameters\n"); > - return -EINVAL; > - } > - > - kms = _dpu_plane_get_kms(&pdpu->base); > + struct dpu_kms *kms = _dpu_plane_get_kms(&pdpu->base); > > *aspace = kms->base.aspace; > - > - return 0; > } > > static inline void _dpu_plane_set_scanout(struct drm_plane *plane, > @@ -824,11 +815,7 @@ static int dpu_plane_prepare_fb(struct drm_plane *plane, > > DPU_DEBUG_PLANE(pdpu, "FB[%u]\n", fb->base.id); > > - ret = _dpu_plane_get_aspace(pdpu, pstate, &aspace); > - if (ret) { > - DPU_ERROR_PLANE(pdpu, "Failed to get aspace\n"); > - return ret; > - } > + _dpu_plane_get_aspace(pdpu, pstate, &aspace); > > /* cache aspace */ > pstate->aspace = aspace; > -- > 2.19.0.444.g18242da7ef-goog > -- The Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project _______________________________________________ Freedreno mailing list Freedreno@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/freedreno