From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Anshuman Gupta <anshuman.gupta@intel.com>
Cc: igt-dev@lists.freedesktop.org, chris.p.wilson@intel.com,
Chris Wilson <chris@chris-wilson.co.uk>
Subject: Re: [igt-dev] [PATCH i-g-t 1/2] i915/gem_eio: Exercise object creation while wedged
Date: Fri, 04 Mar 2022 22:30:42 -0800 [thread overview]
Message-ID: <87o82kzzal.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20220303140636.26652-2-anshuman.gupta@intel.com>
On Thu, 03 Mar 2022 06:06:35 -0800, Anshuman Gupta wrote:
>
> diff --git a/lib/i915/gem_memory_topology.h b/lib/i915/gem_memory_topology.h
> new file mode 100644
> index 000000000..8daec8b5b
> --- /dev/null
> +++ b/lib/i915/gem_memory_topology.h
> @@ -0,0 +1,45 @@
> +/*
> + * Copyright © 2021 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.
> + */
Can we please replace these headers with SPDX headers (note SPDX headers
for .c and .h files are different but we have plenty in the code).
> +
> +#ifndef GEM_MEMORY_TOPOLOGY_H
> +#define GEM_MEMORY_TOPOLOGY_H
> +
> +#include <stdint.h>
> +
> +#include "i915_drm.h"
> +
> +struct gem_memory_region {
> + struct gem_memory_region *next;
> + char *name;
> +
> + struct drm_i915_gem_memory_class_instance ci;
> + uint64_t size;
> +};
> +
> +struct gem_memory_region *__gem_get_memory_regions(int i915);
> +struct gem_memory_region *
> +__gem_next_memory_region(struct gem_memory_region *r);
> +
> +#define for_each_memory_region(r__, fd__) for (struct gem_memory_region *r__ = __gem_get_memory_regions(fd__); r__; r__ = __gem_next_memory_region(r__))
Let me ask about this too on the mailing list. We already have equivalent
functionality using get_memory_region_set()/for_each_combination(), the
macros introduced here are actually simpler. But any objection to
introducing these since we already have equivalent functionality?
next prev parent reply other threads:[~2022-03-05 6:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-03 14:06 [igt-dev] [PATCH i-g-t 0/2] Add placement to gem_exec_stress Anshuman Gupta
2022-03-03 14:06 ` [igt-dev] [PATCH i-g-t 1/2] i915/gem_eio: Exercise object creation while wedged Anshuman Gupta
2022-03-05 6:30 ` Dixit, Ashutosh [this message]
2022-03-07 8:02 ` Zbigniew Kempczyński
2022-03-08 3:18 ` Dixit, Ashutosh
2022-03-03 14:06 ` [igt-dev] [PATCH i-g-t 2/2] i915_pm_rpm: Add placement to gem_exec_stress Anshuman Gupta
2022-03-03 16:18 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2022-03-04 2:24 ` [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=87o82kzzal.wl-ashutosh.dixit@intel.com \
--to=ashutosh.dixit@intel.com \
--cc=anshuman.gupta@intel.com \
--cc=chris.p.wilson@intel.com \
--cc=chris@chris-wilson.co.uk \
--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.