1 #ifndef __NVKM_FAULT_H__
2 #define __NVKM_FAULT_H__
3 #include <core/subdev.h>
4 #include <core/notify.h>
5 
6 struct nvkm_fault {
7 	const struct nvkm_fault_func *func;
8 	struct nvkm_subdev subdev;
9 
10 	struct nvkm_fault_buffer *buffer[2];
11 	int buffer_nr;
12 
13 	struct nvkm_event event;
14 
15 	struct nvkm_notify nrpfb;
16 
17 	struct nvkm_device_oclass user;
18 };
19 
20 struct nvkm_fault_data {
21 	u64  addr;
22 	u64  inst;
23 	u64  time;
24 	u8 engine;
25 	u8  valid;
26 	u8    gpc;
27 	u8    hub;
28 	u8 access;
29 	u8 client;
30 	u8 reason;
31 };
32 
33 int gp100_fault_new(struct nvkm_device *, int, struct nvkm_fault **);
34 int gv100_fault_new(struct nvkm_device *, int, struct nvkm_fault **);
35 int tu102_fault_new(struct nvkm_device *, int, struct nvkm_fault **);
36 #endif
37