mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@kernel.org>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Ian Rogers <irogers@google.com>, Jiri Olsa <jolsa@kernel.org>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	linux-perf-users@vger.kernel.org,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Jani Nikula <jani.nikula@linux.intel.com>,
	Joonas Lahtinen <joonas.lahtinen@linux.intel.com>,
	Rodrigo Vivi <rodrigo.vivi@intel.com>,
	intel-gfx@lists.freedesktop.org
Subject: [PATCH 02/10] tools/include: Sync uapi/drm/i915_drm.h with the kernel sources
Date: Tue,  6 Aug 2024 15:50:05 -0700	[thread overview]
Message-ID: <20240806225013.126130-3-namhyung@kernel.org> (raw)
In-Reply-To: <20240806225013.126130-1-namhyung@kernel.org>

To pick up changes from:

  0f1bb41bf396 drm/i915: Support replaying GPU hangs with captured context image

This should be used to beautify DRM syscall arguments and it addresses
these tools/perf build warnings:

  Warning: Kernel ABI header differences:
    diff -u tools/include/uapi/drm/i915_drm.h include/uapi/drm/i915_drm.h

Please see tools/include/uapi/README for details (it's in the first patch
of this series).

Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
---
 tools/include/uapi/drm/i915_drm.h | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/tools/include/uapi/drm/i915_drm.h b/tools/include/uapi/drm/i915_drm.h
index d4d86e566e07..535cb68fdb5c 100644
--- a/tools/include/uapi/drm/i915_drm.h
+++ b/tools/include/uapi/drm/i915_drm.h
@@ -2163,6 +2163,15 @@ struct drm_i915_gem_context_param {
  * supports this per context flag.
  */
 #define I915_CONTEXT_PARAM_LOW_LATENCY		0xe
+
+/*
+ * I915_CONTEXT_PARAM_CONTEXT_IMAGE:
+ *
+ * Allows userspace to provide own context images.
+ *
+ * Note that this is a debug API not available on production kernel builds.
+ */
+#define I915_CONTEXT_PARAM_CONTEXT_IMAGE	0xf
 /* Must be kept compact -- no holes and well documented */
 
 	/** @value: Context parameter value to be set or queried */
@@ -2564,6 +2573,24 @@ struct i915_context_param_engines {
 	struct i915_engine_class_instance engines[N__]; \
 } __attribute__((packed)) name__
 
+struct i915_gem_context_param_context_image {
+	/** @engine: Engine class & instance to be configured. */
+	struct i915_engine_class_instance engine;
+
+	/** @flags: One of the supported flags or zero. */
+	__u32 flags;
+#define I915_CONTEXT_IMAGE_FLAG_ENGINE_INDEX (1u << 0)
+
+	/** @size: Size of the image blob pointed to by @image. */
+	__u32 size;
+
+	/** @mbz: Must be zero. */
+	__u32 mbz;
+
+	/** @image: Userspace memory containing the context image. */
+	__u64 image;
+} __attribute__((packed));
+
 /**
  * struct drm_i915_gem_context_create_ext_setparam - Context parameter
  * to set or query during context creation.
-- 
2.46.0.rc2.264.g509ed76dc8-goog


  parent reply	other threads:[~2024-08-06 22:50 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-06 22:50 [PATCHSET 00/10] perf tools: Sync tools and kernel headers for v6.11 Namhyung Kim
2024-08-06 22:50 ` [PATCH 01/10] perf tools: Add tools/include/uapi/README Namhyung Kim
2024-08-06 22:50 ` Namhyung Kim [this message]
2024-08-06 22:50 ` [PATCH 03/10] tools/include: Sync uapi/linux/kvm.h with the kernel sources Namhyung Kim
2024-08-06 22:50 ` [PATCH 04/10] tools/include: Sync uapi/linux/perf.h " Namhyung Kim
2024-08-06 22:50 ` [PATCH 05/10] tools/include: Sync uapi/sound/asound.h " Namhyung Kim
2024-08-06 22:50 ` [PATCH 06/10] tools/include: Sync uapi/asm-generic/unistd.h " Namhyung Kim
2024-08-07  7:11   ` Arnd Bergmann
2024-08-07 17:56     ` Namhyung Kim
2024-08-06 22:50 ` [PATCH 07/10] tools/include: Sync network socket headers " Namhyung Kim
2024-08-06 22:50 ` [PATCH 08/10] tools/include: Sync filesystem " Namhyung Kim
2024-08-06 22:50 ` [PATCH 09/10] tools/include: Sync x86 " Namhyung Kim
2024-08-06 22:50 ` [PATCH 10/10] tools/include: Sync arm64 " Namhyung Kim
2024-08-07 18:12 ` [PATCHSET 00/10] perf tools: Sync tools and kernel headers for v6.11 Namhyung Kim
2024-08-08  1:11   ` Arnaldo Carvalho de Melo
2024-08-08  6:44   ` Athira Rajeev
2024-08-08 18:44     ` Namhyung Kim
2024-08-09 15:38       ` Athira Rajeev
2024-08-09 19:46         ` Namhyung Kim

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=20240806225013.126130-3-namhyung@kernel.org \
    --to=namhyung@kernel.org \
    --cc=acme@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=irogers@google.com \
    --cc=jani.nikula@linux.intel.com \
    --cc=jolsa@kernel.org \
    --cc=joonas.lahtinen@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=rodrigo.vivi@intel.com \
    --cc=torvalds@linux-foundation.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

all inboxes | Powered by JetHome®