summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/fifo_gk20a.h
diff options
context:
space:
mode:
authorSeema Khowala <seemaj@nvidia.com>2017-02-22 14:52:46 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2017-03-21 15:08:06 -0400
commit51f3f542fabb31527024eba5b8f52bf87cc30659 (patch)
tree3554d88cdd5a442cd3819aff1f041c8d3fa5a739 /drivers/gpu/nvgpu/gk20a/fifo_gk20a.h
parent65e2c567973d549ad02d09d4a83a1676485961fc (diff)
gpu: nvgpu: add is_preempt_pending fifo ops
is_preempt_pending fifo ops is added as t19x preempt done sequence is differnt than legacy chips. Change-Id: I6b46be1f5b911ae11bbe806968cb8fabb21848e0 Signed-off-by: Seema Khowala <seemaj@nvidia.com> Reviewed-on: http://git-master/r/1309678 Reviewed-by: svccoveritychecker <svccoveritychecker@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/fifo_gk20a.h')
-rw-r--r--drivers/gpu/nvgpu/gk20a/fifo_gk20a.h21
1 files changed, 17 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/fifo_gk20a.h b/drivers/gpu/nvgpu/gk20a/fifo_gk20a.h
index 2de5e2d6..9793f37b 100644
--- a/drivers/gpu/nvgpu/gk20a/fifo_gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/fifo_gk20a.h
@@ -25,11 +25,18 @@
25#include "tsg_gk20a.h" 25#include "tsg_gk20a.h"
26#include "debug_gk20a.h" 26#include "debug_gk20a.h"
27 27
28#define MAX_RUNLIST_BUFFERS 2 28#define MAX_RUNLIST_BUFFERS 2
29 29
30#define FIFO_INVAL_ENGINE_ID ((u32)~0) 30#define FIFO_INVAL_ENGINE_ID ((u32)~0)
31#define FIFO_INVAL_CHANNEL_ID ((u32)~0) 31#define FIFO_INVAL_CHANNEL_ID ((u32)~0)
32#define FIFO_INVAL_TSG_ID ((u32)~0) 32#define FIFO_INVAL_TSG_ID ((u32)~0)
33
34#define ID_TYPE_CHANNEL 0
35#define ID_TYPE_TSG 1
36#define ID_TYPE_UNKNOWN ((u32)~0)
37
38#define PREEMPT_TIMEOUT_RC 1
39#define PREEMPT_TIMEOUT_NORC 0
33 40
34/* 41/*
35 * Number of entries in the kickoff latency buffer, used to calculate 42 * Number of entries in the kickoff latency buffer, used to calculate
@@ -336,4 +343,10 @@ struct channel_gk20a *gk20a_refch_from_inst_ptr(struct gk20a *g, u64 inst_ptr);
336 343
337u32 gk20a_fifo_intr_0_error_mask(struct gk20a *g); 344u32 gk20a_fifo_intr_0_error_mask(struct gk20a *g);
338 345
346int gk20a_fifo_is_preempt_pending(struct gk20a *g, u32 id, unsigned int id_type,
347 unsigned int timeout_rc_type);
348int __locked_fifo_preempt(struct gk20a *g, u32 id, bool is_tsg);
349void __locked_fifo_preempt_timeout_rc(struct gk20a *g, u32 id,
350 unsigned int id_type);
351
339#endif /*__GR_GK20A_H__*/ 352#endif /*__GR_GK20A_H__*/