Files
linux/drivers/gpu/drm/xe/xe_mert.h
Michal Wajdeczko 7970e04d17 drm/xe/mert: Move MERT initialization to xe_mert.c
Most of the MERT code is already in dedicated file, no reason to
keep internal MERT data structure initialization elsewhere.

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Lukasz Laguna <lukasz.laguna@intel.com>
Reviewed-by: Lukasz Laguna <lukasz.laguna@intel.com>
Link: https://patch.msgid.link/20260109151219.26206-6-michal.wajdeczko@intel.com
2026-01-12 14:38:44 +01:00

36 lines
856 B
C

/* SPDX-License-Identifier: MIT */
/*
* Copyright(c) 2025, Intel Corporation. All rights reserved.
*/
#ifndef _XE_MERT_H_
#define _XE_MERT_H_
#include <linux/completion.h>
#include <linux/spinlock.h>
#include <linux/types.h>
struct xe_device;
/**
* struct xe_mert - MERT related data
*/
struct xe_mert {
/** @lock: protects the TLB invalidation status */
spinlock_t lock;
/** @tlb_inv_triggered: indicates if TLB invalidation was triggered */
bool tlb_inv_triggered;
/** @tlb_inv_done: completion of TLB invalidation */
struct completion tlb_inv_done;
};
#ifdef CONFIG_PCI_IOV
void xe_mert_init_early(struct xe_device *xe);
int xe_mert_invalidate_lmtt(struct xe_device *xe);
void xe_mert_irq_handler(struct xe_device *xe, u32 master_ctl);
#else
static inline void xe_mert_irq_handler(struct xe_device *xe, u32 master_ctl) { }
#endif
#endif