Blame view

kernel/linux-rt-4.4.41/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/priv.h 1.06 KB
5113f6f70   김현기   kernel add
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
  #ifndef __NVKM_I2C_PRIV_H__
  #define __NVKM_I2C_PRIV_H__
  #define nvkm_i2c(p) container_of((p), struct nvkm_i2c, subdev)
  #include <subdev/i2c.h>
  
  int nvkm_i2c_new_(const struct nvkm_i2c_func *, struct nvkm_device *,
  		  int index, struct nvkm_i2c **);
  
  struct nvkm_i2c_func {
  	int (*pad_x_new)(struct nvkm_i2c *, int id, struct nvkm_i2c_pad **);
  	int (*pad_s_new)(struct nvkm_i2c *, int id, struct nvkm_i2c_pad **);
  
  	/* number of native dp aux channels present */
  	int aux;
  
  	/* read and ack pending interrupts, returning only data
  	 * for ports that have not been masked off, while still
  	 * performing the ack for anything that was pending.
  	 */
  	void (*aux_stat)(struct nvkm_i2c *, u32 *, u32 *, u32 *, u32 *);
  
  	/* mask on/off interrupt types for a given set of auxch
  	 */
  	void (*aux_mask)(struct nvkm_i2c *, u32, u32, u32);
  };
  
  void g94_aux_stat(struct nvkm_i2c *, u32 *, u32 *, u32 *, u32 *);
  void g94_aux_mask(struct nvkm_i2c *, u32, u32, u32);
  
  void gk104_aux_stat(struct nvkm_i2c *, u32 *, u32 *, u32 *, u32 *);
  void gk104_aux_mask(struct nvkm_i2c *, u32, u32, u32);
  #endif