mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-03-22 07:27:12 +08:00
Since engines in the same class can be divided across multiple groups, the GuC does not allow scheduler groups to be active if there are multi-lrc contexts. This means that: 1) if a MLRC context is registered when we enable scheduler groups, the GuC will silently ignore the configuration 2) if a MLRC context is registered after scheduler groups are enabled, the GuC will disable the groups and generate an adverse event. The expectation is that the admin will ensure that all apps that use MLRC on PF have been terminated before scheduler groups are created. A check is added anyway to make sure we don't still have contexts waiting to be cleaned up laying around. A check is also added at queue creation time to block MLRC queue creation if scheduler groups have been enabled. 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-19-daniele.ceraolospurio@intel.com
52 lines
1.1 KiB
C
52 lines
1.1 KiB
C
/* SPDX-License-Identifier: MIT */
|
|
/*
|
|
* Copyright © 2023-2024 Intel Corporation
|
|
*/
|
|
|
|
#ifndef _XE_GT_SRIOV_PF_H_
|
|
#define _XE_GT_SRIOV_PF_H_
|
|
|
|
#include <linux/types.h>
|
|
|
|
struct xe_gt;
|
|
|
|
#ifdef CONFIG_PCI_IOV
|
|
int xe_gt_sriov_pf_init_early(struct xe_gt *gt);
|
|
int xe_gt_sriov_pf_init(struct xe_gt *gt);
|
|
int xe_gt_sriov_pf_wait_ready(struct xe_gt *gt);
|
|
void xe_gt_sriov_pf_init_hw(struct xe_gt *gt);
|
|
void xe_gt_sriov_pf_sanitize_hw(struct xe_gt *gt, unsigned int vfid);
|
|
void xe_gt_sriov_pf_stop_prepare(struct xe_gt *gt);
|
|
void xe_gt_sriov_pf_restart(struct xe_gt *gt);
|
|
bool xe_gt_sriov_pf_sched_groups_enabled(struct xe_gt *gt);
|
|
#else
|
|
static inline int xe_gt_sriov_pf_init_early(struct xe_gt *gt)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
static inline int xe_gt_sriov_pf_init(struct xe_gt *gt)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
static inline void xe_gt_sriov_pf_init_hw(struct xe_gt *gt)
|
|
{
|
|
}
|
|
|
|
static inline void xe_gt_sriov_pf_stop_prepare(struct xe_gt *gt)
|
|
{
|
|
}
|
|
|
|
static inline void xe_gt_sriov_pf_restart(struct xe_gt *gt)
|
|
{
|
|
}
|
|
|
|
static inline bool xe_gt_sriov_pf_sched_groups_enabled(struct xe_gt *gt)
|
|
{
|
|
return false;
|
|
}
|
|
#endif
|
|
|
|
#endif
|