Commit 95983aea authored by Ben Skeggs's avatar Ben Skeggs Committed by Dave Airlie
Browse files

drm/nouveau/disp: add connector class



Will be used to provide more solid driver interfaces in general, but
the immediate motivation is work towards fixing issues with handling
hotplug/DP IRQ events.

Its use is currently limited to where we support non-polled hotplug
already (ie. any GPU since NV40ish era, where our DCB handling works
well enough), until that gets cleaned up someday.

v2:
- use ?: (lyude)

Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
Reviewed-by: default avatarLyude Paul <lyude@redhat.com>
Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
parent 889fcbe9
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -33,6 +33,7 @@
#define NVIF_CLASS_VMM_GP100                         /* ifc00d.h */  0x8000c00d

#define NVIF_CLASS_DISP                              /* if0010.h */  0x80000010
#define NVIF_CLASS_CONN                              /* if0011.h */  0x80000011
#define NVIF_CLASS_DISP_CHAN                         /* if0014.h */  0x80000014

/* the below match nvidia-assigned (either in hw, or sw) class numbers */
+13 −0
Original line number Diff line number Diff line
/* SPDX-License-Identifier: MIT */
#ifndef __NVIF_CONN_H__
#define __NVIF_CONN_H__
#include <nvif/object.h>
struct nvif_disp;

struct nvif_conn {
	struct nvif_object object;
};

int nvif_conn_ctor(struct nvif_disp *, const char *name, int id, struct nvif_conn *);
void nvif_conn_dtor(struct nvif_conn *);
#endif
+1 −0
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@ struct nvif_device;

struct nvif_disp {
	struct nvif_object object;
	unsigned long conn_mask;
};

int nvif_disp_ctor(struct nvif_device *, const char *name, s32 oclass,
+2 −1
Original line number Diff line number Diff line
@@ -5,7 +5,8 @@
union nvif_disp_args {
	struct nvif_disp_v0 {
		__u8 version;
		__u8 pad01[7];
		__u8 pad01[3];
		__u32 conn_mask;
	} v0;
};
#endif
+12 −0
Original line number Diff line number Diff line
/* SPDX-License-Identifier: MIT */
#ifndef __NVIF_IF0011_H__
#define __NVIF_IF0011_H__

union nvif_conn_args {
	struct nvif_conn_v0 {
		__u8 version;
		__u8 id;	/* DCB connector table index. */
		__u8 pad02[6];
	} v0;
};
#endif
Loading