From: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
To: Kalyan Thota <quic_kalyant@quicinc.com>,
dri-devel@lists.freedesktop.org, linux-arm-msm@vger.kernel.org,
freedreno@lists.freedesktop.org, devicetree@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, robdclark@chromium.org,
dianders@chromium.org, swboyd@chromium.org,
quic_vpolimer@quicinc.com, quic_abhinavk@quicinc.com
Subject: Re: [PATCH 1/3] drm/msm/disp/dpu1: allow reservation even if dspps are not available.
Date: Tue, 17 Jan 2023 18:35:13 +0200 [thread overview]
Message-ID: <0a845c24-b1a5-a961-103f-0d8840a8f17d@linaro.org> (raw)
In-Reply-To: <1673972488-30140-2-git-send-email-quic_kalyant@quicinc.com>
On 17/01/2023 18:21, Kalyan Thota wrote:
> if any topology requests for dspps and catalogue doesn't have the
> allocation, avoid failing the reservation.
>
> This can pave way to build logic allowing composer fallbacks
> for all the color features that are handled in dspp.
>
> Signed-off-by: Kalyan Thota <quic_kalyant@quicinc.com>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c | 8 +++++++-
> 1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c
> index 73b3442..c8899ae 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c
> @@ -343,7 +343,13 @@ static bool _dpu_rm_check_lm_and_get_connected_blks(struct dpu_rm *rm,
> return true;
>
> idx = lm_cfg->dspp - DSPP_0;
> - if (idx < 0 || idx >= ARRAY_SIZE(rm->dspp_blks)) {
> +
> + if (idx < 0) {
The change doesn't correspond to commit message.
> + DPU_DEBUG("lm doesn't have dspp, ignoring the request %d\n", lm_cfg->dspp);
> + return true;
> + }
> +
> + if (idx >= ARRAY_SIZE(rm->dspp_blks)) {
> DPU_ERROR("failed to get dspp on lm %d\n", lm_cfg->dspp);
> return false;
> }
If you'd like to remove duplicate for the (idx >= ARRAY_SIZE) check, I'd
suggest dropping the second one
--
With best wishes
Dmitry
next prev parent reply other threads:[~2023-01-17 16:35 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-17 16:21 [PATCH 0/3] Allow composer fallbacks for color features Kalyan Thota
2023-01-17 16:21 ` [PATCH 1/3] drm/msm/disp/dpu1: allow reservation even if dspps are not available Kalyan Thota
2023-01-17 16:35 ` Dmitry Baryshkov [this message]
2023-01-17 16:40 ` Dmitry Baryshkov
2023-01-18 3:24 ` Kalyan Thota
2023-01-18 3:28 ` Dmitry Baryshkov
2023-01-17 16:21 ` [PATCH 2/3] drm/msm/disp/dpu1: allow dspp selection for all the interfaces Kalyan Thota
2023-01-17 16:56 ` Dmitry Baryshkov
2023-01-18 3:30 ` Kalyan Thota
2023-01-18 3:35 ` Dmitry Baryshkov
2023-01-19 18:24 ` Kalyan Thota
2023-01-17 16:21 ` [PATCH 3/3] drm/msm/disp/dpu1: fail atomic check if color feature is requested with no dspp Kalyan Thota
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0a845c24-b1a5-a961-103f-0d8840a8f17d@linaro.org \
--to=dmitry.baryshkov@linaro.org \
--cc=devicetree@vger.kernel.org \
--cc=dianders@chromium.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=quic_abhinavk@quicinc.com \
--cc=quic_kalyant@quicinc.com \
--cc=quic_vpolimer@quicinc.com \
--cc=robdclark@chromium.org \
--cc=swboyd@chromium.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).