igt-dev.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_ccs: Avoid using plane sizes which exceed hw capability
Date: Fri, 21 Sep 2018 17:35:06 +0300	[thread overview]
Message-ID: <20180921143506.GZ5565@intel.com> (raw)
In-Reply-To: <1537537081-5835-1-git-send-email-juhapekka.heikkila@gmail.com>

On Fri, Sep 21, 2018 at 04:38:01PM +0300, Juha-Pekka Heikkila wrote:
> Max sprite plane width at 2000 to avoid going over hw watermark
> limits.
> 
> bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105458
> Signed-off-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
> ---
>  tests/kms_ccs.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/kms_ccs.c b/tests/kms_ccs.c
> index e1ee588..f630029 100644
> --- a/tests/kms_ccs.c
> +++ b/tests/kms_ccs.c
> @@ -68,6 +68,8 @@ typedef struct {
>  #define CCS_UNCOMPRESSED	0x0
>  #define CCS_COMPRESSED		0x55
>  
> +#define MAX_SPRITE_PLANE_WIDTH 2000

Please include a comment explaining why we limit the plane width
like this. Avoids the next guy having to trawl git logs for the
information.

> +
>  struct local_drm_format_modifier {
>         /* Bitmask of formats in get_plane format list this info applies to. The
>  	* offset allows a sliding window of which 64 formats (bits).
> @@ -408,12 +410,12 @@ static bool try_config(data_t *data, enum test_fb_flags fb_flags,
>  	if (data->plane && fb_flags & FB_COMPRESSED) {
>  		if (!plane_has_format_with_ccs(data, data->plane, DRM_FORMAT_XRGB8888))
>  			return false;
> -		generate_fb(data, &fb, drm_mode->hdisplay,
> +		generate_fb(data, &fb, min(MAX_SPRITE_PLANE_WIDTH, drm_mode->hdisplay),
>  			    drm_mode->vdisplay,
>  			    (fb_flags & ~FB_COMPRESSED) | FB_HAS_PLANE);
>  		generate_fb(data, &fb_sprite, 256, 256, fb_flags);
>  	} else {
> -		generate_fb(data, &fb, drm_mode->hdisplay,
> +		generate_fb(data, &fb, min(MAX_SPRITE_PLANE_WIDTH, drm_mode->hdisplay),
>  			    drm_mode->vdisplay, fb_flags);
>  	}
>  
> -- 
> 2.7.4
> 
> _______________________________________________
> igt-dev mailing list
> igt-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev

-- 
Ville Syrjälä
Intel
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  parent reply	other threads:[~2018-09-21 14:35 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-21 13:38 [igt-dev] [PATCH i-g-t] tests/kms_ccs: Avoid using plane sizes which exceed hw capability Juha-Pekka Heikkila
2018-09-21 14:14 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2018-09-21 14:35 ` Ville Syrjälä [this message]
2018-09-21 15:41 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2018-09-24  8:29 ` [igt-dev] [PATCH i-g-t] " Juha-Pekka Heikkila
2018-10-12 15:23   ` Maarten Lankhorst
2018-09-24  9:12 ` [igt-dev] ✗ Fi.CI.BAT: failure for tests/kms_ccs: Avoid using plane sizes which exceed hw capability (rev2) Patchwork
2018-09-24 10:12 ` [igt-dev] ✓ Fi.CI.BAT: success " Patchwork
2018-09-24 11:01 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork

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=20180921143506.GZ5565@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=juhapekka.heikkila@gmail.com \
    /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).