From: Gabriel Krisman Bertazi <krisman@collabora.co.uk>
To: Ben Widawsky <ben@bwidawsk.net>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 2/2] drm/i915: Fail addfb ioctl if color and CCS buffers overlap
Date: Fri, 01 Sep 2017 01:35:02 -0300 [thread overview]
Message-ID: <87efrrvxxl.fsf@dilma.collabora.co.uk> (raw)
In-Reply-To: <20170831200652.GB3393@mail.bwidawsk.net> (Ben Widawsky's message of "Thu, 31 Aug 2017 13:06:53 -0700")
Ben Widawsky <ben@bwidawsk.net> writes:
> On 17-08-31 16:52:15, Gabriel Krisman Bertazi wrote:
>>With this patch the new testcase igt@kms_ccs@pipe-X-invalid-ccs-offset
>>succeeds.
>>
>>Signed-off-by: Gabriel Krisman Bertazi <krisman@collabora.co.uk>
>>---
>> drivers/gpu/drm/i915/intel_display.c | 5 +++++
>> 1 file changed, 5 insertions(+)
>>
>>diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
>>index b28f076f98bc..ff1ed67a9eff 100644
>>--- a/drivers/gpu/drm/i915/intel_display.c
>>+++ b/drivers/gpu/drm/i915/intel_display.c
>>@@ -13989,6 +13989,11 @@ static int intel_framebuffer_init(struct intel_framebuffer *intel_fb,
>> DRM_DEBUG_KMS("RC supported only with RGB8888 formats\n");
>> goto err;
>> }
>>+
>>+ if (mode_cmd->offsets[1] < mode_cmd->pitches[0]) {
>>+ DRM_DEBUG_KMS("CCS and color buffers overlap\n");
>>+ return -EINVAL;
>>+ }
>
> This check doesn't look nearly strict enough to determine overlap. All it's
> checking is that the aux buffer isn't in the first row of the main buffer.
> Second of all, while today our requirement is that the aux buffer always come
> after the main buffer, that may not be the case forever.
Right. Thanks for catching it. I'll re-spin with a more strict (and
correct) test for overlapping.
--
Gabriel Krisman Bertazi
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2017-09-01 4:35 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-31 19:52 [PATCH 1/2] drm: Fix example comment of format modifier blob Gabriel Krisman Bertazi
2017-08-31 19:52 ` [PATCH 2/2] drm/i915: Fail addfb ioctl if color and CCS buffers overlap Gabriel Krisman Bertazi
2017-08-31 20:06 ` Ben Widawsky
2017-09-01 4:35 ` Gabriel Krisman Bertazi [this message]
2017-09-04 8:21 ` Daniel Vetter
2017-09-04 16:37 ` Ville Syrjälä
2017-09-05 7:36 ` Daniel Stone
2017-09-07 12:19 ` Ville Syrjälä
2017-09-22 5:25 ` Gabriel Krisman Bertazi
2017-09-22 11:54 ` Ville Syrjälä
2017-08-31 20:00 ` [PATCH 1/2] drm: Fix example comment of format modifier blob Ben Widawsky
2017-09-04 8:24 ` Daniel Vetter
2017-08-31 20:22 ` ✓ Fi.CI.BAT: success for series starting with [1/2] " Patchwork
2017-08-31 23:37 ` ✓ 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=87efrrvxxl.fsf@dilma.collabora.co.uk \
--to=krisman@collabora.co.uk \
--cc=ben@bwidawsk.net \
--cc=intel-gfx@lists.freedesktop.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