mirror of
https://github.com/torvalds/linux.git
synced 2026-04-25 18:12:26 -04:00
Some upcoming KLVs are sized based on the engine counts, so we need those defines to be moved to a separate file to include them from guc_klv_abi.h (which is already included by guc_fwif.h). Instead of moving just the engine-related defines, it is cleaner to move all scheduler-related defines (i.e., everything engine or context related). Note that the legacy GuC defines have not been moved and have instead been dropped because Xe doesn't support any GuC old enough to still use them. While at it, struct guc_ctxt_registration_info has been moved to guc_submit.c since it doesn't come from the GuC specs (we added it to make things simpler in our code). Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Cc: Michal Wajdeczko <michal.wajdeczko@intel.com> Reviewed-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Link: https://patch.msgid.link/20251218223846.1146344-16-daniele.ceraolospurio@intel.com
62 lines
2.1 KiB
C
62 lines
2.1 KiB
C
/* SPDX-License-Identifier: MIT */
|
|
/*
|
|
* Copyright © 2021-2024 Intel Corporation
|
|
*/
|
|
|
|
#ifndef _XE_GUC_CAPTURE_H
|
|
#define _XE_GUC_CAPTURE_H
|
|
|
|
#include <linux/types.h>
|
|
#include "abi/guc_capture_abi.h"
|
|
#include "abi/guc_scheduler_abi.h"
|
|
#include "xe_guc.h"
|
|
|
|
struct xe_exec_queue;
|
|
struct xe_guc;
|
|
struct xe_hw_engine;
|
|
struct xe_hw_engine_snapshot;
|
|
|
|
static inline enum guc_capture_list_class_type xe_guc_class_to_capture_class(u16 class)
|
|
{
|
|
switch (class) {
|
|
case GUC_RENDER_CLASS:
|
|
case GUC_COMPUTE_CLASS:
|
|
return GUC_CAPTURE_LIST_CLASS_RENDER_COMPUTE;
|
|
case GUC_GSC_OTHER_CLASS:
|
|
return GUC_CAPTURE_LIST_CLASS_GSC_OTHER;
|
|
case GUC_VIDEO_CLASS:
|
|
case GUC_VIDEOENHANCE_CLASS:
|
|
case GUC_BLITTER_CLASS:
|
|
return class;
|
|
default:
|
|
XE_WARN_ON(class);
|
|
return GUC_CAPTURE_LIST_CLASS_MAX;
|
|
}
|
|
}
|
|
|
|
static inline enum guc_capture_list_class_type
|
|
xe_engine_class_to_guc_capture_class(enum xe_engine_class class)
|
|
{
|
|
return xe_guc_class_to_capture_class(xe_engine_class_to_guc_class(class));
|
|
}
|
|
|
|
void xe_guc_capture_process(struct xe_guc *guc);
|
|
int xe_guc_capture_getlist(struct xe_guc *guc, u32 owner, u32 type,
|
|
enum guc_capture_list_class_type capture_class, void **outptr);
|
|
int xe_guc_capture_getlistsize(struct xe_guc *guc, u32 owner, u32 type,
|
|
enum guc_capture_list_class_type capture_class, size_t *size);
|
|
int xe_guc_capture_getnullheader(struct xe_guc *guc, void **outptr, size_t *size);
|
|
size_t xe_guc_capture_ads_input_worst_size(struct xe_guc *guc);
|
|
const struct __guc_mmio_reg_descr_group *
|
|
xe_guc_capture_get_reg_desc_list(struct xe_gt *gt, u32 owner, u32 type,
|
|
enum guc_capture_list_class_type capture_class, bool is_ext);
|
|
struct __guc_capture_parsed_output *xe_guc_capture_get_matching_and_lock(struct xe_exec_queue *q);
|
|
void xe_engine_manual_capture(struct xe_hw_engine *hwe, struct xe_hw_engine_snapshot *snapshot);
|
|
void xe_engine_snapshot_print(struct xe_hw_engine_snapshot *snapshot, struct drm_printer *p);
|
|
void xe_engine_snapshot_capture_for_queue(struct xe_exec_queue *q);
|
|
void xe_guc_capture_steered_list_init(struct xe_guc *guc);
|
|
void xe_guc_capture_put_matched_nodes(struct xe_guc *guc);
|
|
int xe_guc_capture_init(struct xe_guc *guc);
|
|
|
|
#endif
|