All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris@chris-wilson.co.uk>
To: Alan Previn <alan.previn.teres.alexis@intel.com>,
	igt-dev@lists.freedesktop.org
Cc: Alan Previn <alan.previn.teres.alexis@intel.com>
Subject: Re: [igt-dev] [RFC i-g-t 04/11] Perform a regular 3d copy as a control checkpoint
Date: Wed, 03 Mar 2021 23:50:40 +0000	[thread overview]
Message-ID: <161481544040.25897.9787239814984432662@build.alporthouse.com> (raw)
In-Reply-To: <20210302225334.361966-5-alan.previn.teres.alexis@intel.com>

Quoting Alan Previn (2021-03-02 22:53:27)
> As a control checkpoint, allocate buffers to be used
> as texture and render target in the 3d engine for a
> regular src to dest copy blit and verify buffer pixels.
> 
> Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
> ---
>  tests/i915/i915_pxp.c | 181 ++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 181 insertions(+)
> 
> diff --git a/tests/i915/i915_pxp.c b/tests/i915/i915_pxp.c
> index 40a817b2..f12ca3d5 100644
> --- a/tests/i915/i915_pxp.c
> +++ b/tests/i915/i915_pxp.c
> @@ -28,6 +28,11 @@ IGT_TEST_DESCRIPTION("Test PXP (Protected Xe Path), which is the component "
>  #define CTX_MODIFY_PROTECTED_BOTHPARAMS_TO_INVALID 8
>  #define CTX_MODIFY_UNPROTECTED_BOTHPARAMS_TO_VALID 9
>  
> +/* test-configs for protected rendering operations */
> +#define COPY3D_BASELINE_SRC_TO_DST 1
> +#define COPY3D_PROTECTED_SRC_TO_PROTDST 2
> +#define COPY3D_PROTECTED_PROTSRC_TO_PROTDST 3
> +
>  static bool is_pxp_hw_supported(int i915)
>  {
>         uint32_t gen;
> @@ -333,10 +338,172 @@ static void test_create_protected_context(int i915, uint32_t test_cfg)
>         }
>  }
>  
> +static void fill_bo_content(int i915, uint32_t bo,
> +       uint32_t size, uint32_t initcolor)
> +{
> +       uint32_t *ptr, *ptrtmp;
> +       int loop = 0;
> +
> +       ptr = gem_mmap__cpu_coherent(i915, bo, 0,
> +                       size, PROT_WRITE);
> +       igt_assert(ptr);

Already done.

So the map here is in the WB, but the data may not be in the CPU cache
nor properly tracked as the buffer may not be cache coherent.

Same for the check.

Use gem_mmap__device_coherent() by default and cpu_coherent only when
you want to handle the cache coherency.
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  reply	other threads:[~2021-03-03 23:50 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-02 22:53 [igt-dev] [RFC i-g-t 00/11] Introduce PXP Test Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 01/11] Sync i915_drm.h UAPI for PXP Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 02/11] Add basic PXP testing of buffer and context alloc Alan Previn
2021-03-03 23:41   ` Chris Wilson
2021-03-04 17:12     ` Teres Alexis, Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 03/11] Add PXP attributes into lib batchbuffer and buffer structs Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 04/11] Perform a regular 3d copy as a control checkpoint Alan Previn
2021-03-03 23:50   ` Chris Wilson [this message]
2021-03-04 17:14     ` Teres Alexis, Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 05/11] Add MI_SET_APPID instruction definition Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 06/11] Enable protected session and protected buffers in rendercopy Alan Previn
2021-03-03 23:55   ` Chris Wilson
2021-03-18 23:34     ` Teres Alexis, Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 07/11] Add subtest to copy raw source to protected dest Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 08/11] Add test where both src and dest are protected Alan Previn
2021-03-03 23:56   ` Chris Wilson
2021-03-04 17:32     ` Teres Alexis, Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 09/11] Add test to verify session key renewed after suspend-resume cycle Alan Previn
2021-03-03 23:59   ` Chris Wilson
2021-03-04 18:27     ` Teres Alexis, Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 10/11] Verify gem_execbuf fails with stale PXP context after teardown Alan Previn
2021-03-02 22:53 ` [igt-dev] [RFC i-g-t 11/11] Verify gem_execbuf fails with stale PXP buffer " Alan Previn
2021-03-04  0:01   ` Chris Wilson
2021-03-04 19:14     ` Teres Alexis, Alan Previn
2021-03-03 16:12 ` [igt-dev] ✓ Fi.CI.BAT: success for Introduce PXP Test Patchwork
2021-03-03 19:08 ` [igt-dev] ✗ Fi.CI.IGT: failure " 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=161481544040.25897.9787239814984432662@build.alporthouse.com \
    --to=chris@chris-wilson.co.uk \
    --cc=alan.previn.teres.alexis@intel.com \
    --cc=igt-dev@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.