From: Daniel Vetter <daniel@ffwll.ch>
To: Sean Paul <sean@poorly.run>
Cc: Sean Paul <seanpaul@chromium.org>, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm: Print erroneous hscale/vscale on failure
Date: Wed, 5 Sep 2018 23:56:47 +0200 [thread overview]
Message-ID: <20180905215647.GI4929@phenom.ffwll.local> (raw)
In-Reply-To: <20180905204610.137016-1-sean@poorly.run>
On Wed, Sep 05, 2018 at 04:46:01PM -0400, Sean Paul wrote:
> From: Sean Paul <seanpaul@chromium.org>
>
> I ran across this last week when I was trying to get this function to
> work. It's useful to have the scale values in the log upon failure.
>
> Signed-off-by: Sean Paul <seanpaul@chromium.org>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> ---
> drivers/gpu/drm/drm_atomic_helper.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/drm_atomic_helper.c b/drivers/gpu/drm/drm_atomic_helper.c
> index 2c23a48482da..1725546d5105 100644
> --- a/drivers/gpu/drm/drm_atomic_helper.c
> +++ b/drivers/gpu/drm/drm_atomic_helper.c
> @@ -758,7 +758,8 @@ int drm_atomic_helper_check_plane_state(struct drm_plane_state *plane_state,
> hscale = drm_rect_calc_hscale(src, dst, min_scale, max_scale);
> vscale = drm_rect_calc_vscale(src, dst, min_scale, max_scale);
> if (hscale < 0 || vscale < 0) {
> - DRM_DEBUG_KMS("Invalid scaling of plane\n");
> + DRM_DEBUG_KMS("Invalid scaling of plane (%d/%d)\n",
> + hscale, vscale);
> drm_rect_debug_print("src: ", &plane_state->src, true);
> drm_rect_debug_print("dst: ", &plane_state->dst, false);
> return -ERANGE;
> --
> Sean Paul, Software Engineer, Google / Chromium OS
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2018-09-05 21:56 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-05 20:46 [PATCH] drm: Print erroneous hscale/vscale on failure Sean Paul
2018-09-05 21:56 ` Daniel Vetter [this message]
2018-09-06 11:30 ` Ville Syrjälä
2018-09-06 12:10 ` Sean Paul
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=20180905215647.GI4929@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=sean@poorly.run \
--cc=seanpaul@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