xref: /linux/drivers/gpu/drm/etnaviv/etnaviv_sched.h (revision c83b49383b595be50647f0c764a48c78b5f3c4f8)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * Copyright (C) 2017 Etnaviv Project
4  */
5 
6 #ifndef __ETNAVIV_SCHED_H__
7 #define __ETNAVIV_SCHED_H__
8 
9 #include <drm/gpu_scheduler.h>
10 
11 struct etnaviv_gpu;
12 
13 static inline
14 struct etnaviv_gem_submit *to_etnaviv_submit(struct drm_sched_job *sched_job)
15 {
16 	return container_of(sched_job, struct etnaviv_gem_submit, sched_job);
17 }
18 
19 int etnaviv_sched_init(struct etnaviv_gpu *gpu);
20 void etnaviv_sched_fini(struct etnaviv_gpu *gpu);
21 int etnaviv_sched_push_job(struct etnaviv_gem_submit *submit);
22 
23 #endif /* __ETNAVIV_SCHED_H__ */
24