blob: fafacd73dcc3841249ff75a7f8fd9ffa41aadca2 [file] [log] [blame]
Matthew Brostdd08ebf2023-03-30 17:31:57 -04001/* SPDX-License-Identifier: MIT */
2/*
3 * Copyright © 2022 Intel Corporation
4 */
5
6#ifndef _XE_BB_H_
7#define _XE_BB_H_
8
9#include "xe_bb_types.h"
10
11struct dma_fence;
12
13struct xe_gt;
Francois Dugast9b9529c2023-07-31 17:30:02 +020014struct xe_exec_queue;
Matthew Brostdd08ebf2023-03-30 17:31:57 -040015struct xe_sched_job;
16
17struct xe_bb *xe_bb_new(struct xe_gt *gt, u32 size, bool usm);
Francois Dugast9b9529c2023-07-31 17:30:02 +020018struct xe_sched_job *xe_bb_create_job(struct xe_exec_queue *q,
Matthew Brostdd08ebf2023-03-30 17:31:57 -040019 struct xe_bb *bb);
Francois Dugast9b9529c2023-07-31 17:30:02 +020020struct xe_sched_job *xe_bb_create_migration_job(struct xe_exec_queue *q,
Matthew Brostdd08ebf2023-03-30 17:31:57 -040021 struct xe_bb *bb, u64 batch_ofs,
22 u32 second_idx);
Matthew Brostdd08ebf2023-03-30 17:31:57 -040023void xe_bb_free(struct xe_bb *bb, struct dma_fence *fence);
24
25#endif