From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: priyanka.dandamudi@intel.com
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [PATCH i-g-t 1/2] lib: Refactor common store code into helper function
Date: Tue, 30 Nov 2021 15:18:37 -0800 [thread overview]
Message-ID: <87a6hlz0z6.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20211128070823.1396652-2-priyanka.dandamudi@intel.com>
On Sat, 27 Nov 2021 23:08:22 -0800, <priyanka.dandamudi@intel.com> wrote:
>
> From: John Harrison <John.C.Harrison@Intel.com>
>
> A lot of tests use almost identical code for creating a batch buffer
> which does a single write to memory. This patch collects three such
> instances into a common helper function.
Here we are submitting just a single instance so maybe change the commit
message to something like:
"A lot of tests use almost identical code for creating a batch buffer which
does a single write to memory. Create a common helper function for doing
this. It is possible that other uses for store dword are all subtly
different enough to make it not so trivial to try to use the helper. This
patch proves the concept, if people like it enough then it can be extended".
@Zbigniew: Another issue is that igt_store_word() lacks softpin
(no-relocation) support (dGfx doesn't have relocations). Do you think we
can add the no-reloc support after we merge? (In CI, DG1 which doesn't have
relocations is only in BAT, not in shards, so the tests which use this
function will not break after we merge). Thanks.
> diff --git a/lib/igt_store.c b/lib/igt_store.c
> new file mode 100644
> index 00000000..dc4d466a
> --- /dev/null
> +++ b/lib/igt_store.c
> @@ -0,0 +1,103 @@
> +/*
> + * Copyright © 2020 Intel Corporation
> + *
> + * Permission is hereby granted, free of charge, to any person obtaining a
> + * copy of this software and associated documentation files (the "Software"),
> + * to deal in the Software without restriction, including without limitation
> + * the rights to use, copy, modify, merge, publish, distribute, sublicense,
> + * and/or sell copies of the Software, and to permit persons to whom the
> + * Software is furnished to do so, subject to the following conditions:
> + *
> + * The above copyright notice and this permission notice (including the next
> + * paragraph) shall be included in all copies or substantial portions of the
> + * Software.
> + *
> + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
> + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
> + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
> + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
> + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
> + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
> + * IN THE SOFTWARE.
> + *
> + */
Please use the SPDX header here. See e.g. intel_ctx.c.
> diff --git a/lib/igt_store.h b/lib/igt_store.h
> new file mode 100644
> index 00000000..709d87e3
> --- /dev/null
> +++ b/lib/igt_store.h
> @@ -0,0 +1,30 @@
> +/*
> + * Copyright © 2020 Intel Corporation
> + *
> + * Permission is hereby granted, free of charge, to any person obtaining a
> + * copy of this software and associated documentation files (the "Software"),
> + * to deal in the Software without restriction, including without limitation
> + * the rights to use, copy, modify, merge, publish, distribute, sublicense,
> + * and/or sell copies of the Software, and to permit persons to whom the
> + * Software is furnished to do so, subject to the following conditions:
> + *
> + * The above copyright notice and this permission notice (including the next
> + * paragraph) shall be included in all copies or substantial portions of the
> + * Software.
> + *
> + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
> + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
> + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
> + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
> + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
> + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
> + * IN THE SOFTWARE.
> + *
> + */
Here too, please use the SPDX header. See intel_ctx.h (.c and .h SPDX
header is different).
Please make these changes and resubmit. We can handle the no-reloc case
later if Zbigniew agrees. Thanks.
next prev parent reply other threads:[~2021-11-30 23:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-28 7:08 [igt-dev] [PATCH i-g-t 0/2] Helper function and engine reset test priyanka.dandamudi
2021-11-28 7:08 ` [igt-dev] [PATCH i-g-t 1/2] lib: Refactor common store code into helper function priyanka.dandamudi
2021-11-30 23:18 ` Dixit, Ashutosh [this message]
2021-11-28 7:08 ` [igt-dev] [PATCH i-g-t 2/2] tests/i915/i915_hangman: Explicitly test per engine reset vs full GPU reset priyanka.dandamudi
2021-11-30 23:27 ` Dixit, Ashutosh
2021-11-28 8:00 ` [igt-dev] ✓ Fi.CI.BAT: success for Helper function and engine reset test Patchwork
2021-11-28 9:09 ` [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=87a6hlz0z6.wl-ashutosh.dixit@intel.com \
--to=ashutosh.dixit@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=priyanka.dandamudi@intel.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