aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2015-08-20 14:54:19 +1000
committerBen Skeggs <bskeggs@redhat.com>2015-08-28 12:40:40 +1000
commit2a7909c0ade08c66690e6115ae49765dc47873e6 (patch)
tree83be819a00404cb6db70257cc2f3869907272140 /drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c
parentdrm/nouveau/dma: convert user classes to new-style nvkm_object (diff)
downloadlinux-dev-2a7909c0ade08c66690e6115ae49765dc47873e6.tar.xz
linux-dev-2a7909c0ade08c66690e6115ae49765dc47873e6.zip
drm/nouveau/disp: split user classes out from engine implementations
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c')
-rw-r--r--drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c46
1 files changed, 10 insertions, 36 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c
index 8da317468bdf..bf6ede5c424e 100644
--- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c
+++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/gm204.c
@@ -22,33 +22,7 @@
* Authors: Ben Skeggs
*/
#include "nv50.h"
-#include "outpdp.h"
-
-#include <nvif/class.h>
-
-/*******************************************************************************
- * Base display object
- ******************************************************************************/
-
-static struct nvkm_oclass
-gm204_disp_sclass[] = {
- { GM204_DISP_CORE_CHANNEL_DMA, &gf110_disp_core_ofuncs.base },
- { GK110_DISP_BASE_CHANNEL_DMA, &gf110_disp_base_ofuncs.base },
- { GK104_DISP_OVERLAY_CONTROL_DMA, &gf110_disp_ovly_ofuncs.base },
- { GK104_DISP_OVERLAY, &gf110_disp_oimm_ofuncs.base },
- { GK104_DISP_CURSOR, &gf110_disp_curs_ofuncs.base },
- {}
-};
-
-static struct nvkm_oclass
-gm204_disp_main_oclass[] = {
- { GM204_DISP, &gf110_disp_main_ofuncs },
- {}
-};
-
-/*******************************************************************************
- * Display engine implementation
- ******************************************************************************/
+#include "rootnv50.h"
static int
gm204_disp_ctor(struct nvkm_object *parent, struct nvkm_object *engine,
@@ -66,14 +40,14 @@ gm204_disp_ctor(struct nvkm_object *parent, struct nvkm_object *engine,
if (ret)
return ret;
- ret = nvkm_event_init(&gf110_disp_chan_uevent, 1, 17, &disp->uevent);
+ ret = nvkm_event_init(&gf119_disp_chan_uevent, 1, 17, &disp->uevent);
if (ret)
return ret;
- nv_engine(disp)->sclass = gm204_disp_main_oclass;
+ nv_engine(disp)->sclass = gm204_disp_root_oclass;
nv_engine(disp)->cclass = &nv50_disp_cclass;
- nv_subdev(disp)->intr = gf110_disp_intr;
- INIT_WORK(&disp->supervisor, gf110_disp_intr_supervisor);
+ nv_subdev(disp)->intr = gf119_disp_intr;
+ INIT_WORK(&disp->supervisor, gf119_disp_intr_supervisor);
disp->sclass = gm204_disp_sclass;
disp->head.nr = heads;
disp->dac.nr = 3;
@@ -81,8 +55,8 @@ gm204_disp_ctor(struct nvkm_object *parent, struct nvkm_object *engine,
disp->dac.power = nv50_dac_power;
disp->dac.sense = nv50_dac_sense;
disp->sor.power = nv50_sor_power;
- disp->sor.hda_eld = gf110_hda_eld;
- disp->sor.hdmi = gf110_hdmi_ctrl;
+ disp->sor.hda_eld = gf119_hda_eld;
+ disp->sor.hdmi = gf119_hdmi_ctrl;
disp->sor.magic = gm204_sor_magic;
return 0;
}
@@ -100,10 +74,10 @@ gm204_disp_oclass = &(struct nv50_disp_impl) {
.base.outp.internal.tmds = nv50_sor_output_new,
.base.outp.internal.lvds = nv50_sor_output_new,
.base.outp.internal.dp = gm204_sor_dp_new,
- .base.vblank = &gf110_disp_vblank_func,
+ .base.vblank = &gf119_disp_vblank_func,
.mthd.core = &gk104_disp_core_mthd_chan,
- .mthd.base = &gf110_disp_base_mthd_chan,
+ .mthd.base = &gf119_disp_base_mthd_chan,
.mthd.ovly = &gk104_disp_ovly_mthd_chan,
.mthd.prev = -0x020000,
- .head.scanoutpos = gf110_disp_main_scanoutpos,
+ .head.scanoutpos = gf119_disp_root_scanoutpos,
}.base.base;