drm/nouveau/disp/gp100: split SOR implementation from gm200
GP100 needs different HDA detection. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
This commit is contained in:
parent
e6867ffa34
commit
9f9f54e887
|
@ -39,6 +39,7 @@ nvkm-y += nvkm/engine/disp/sorgf119.o
|
|||
nvkm-y += nvkm/engine/disp/sorgk104.o
|
||||
nvkm-y += nvkm/engine/disp/sorgm107.o
|
||||
nvkm-y += nvkm/engine/disp/sorgm200.o
|
||||
nvkm-y += nvkm/engine/disp/sorgp100.o
|
||||
nvkm-y += nvkm/engine/disp/sorgv100.o
|
||||
nvkm-y += nvkm/engine/disp/sortu102.o
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ gp100_disp = {
|
|||
.super = gf119_disp_super,
|
||||
.root = &gp100_disp_root_oclass,
|
||||
.head = { .cnt = gf119_head_cnt, .new = gf119_head_new },
|
||||
.sor = { .cnt = gf119_sor_cnt, .new = gm200_sor_new },
|
||||
.sor = { .cnt = gf119_sor_cnt, .new = gp100_sor_new },
|
||||
};
|
||||
|
||||
int
|
||||
|
|
|
@ -63,7 +63,7 @@ gp102_disp = {
|
|||
.super = gf119_disp_super,
|
||||
.root = &gp102_disp_root_oclass,
|
||||
.head = { .cnt = gf119_head_cnt, .new = gf119_head_new },
|
||||
.sor = { .cnt = gf119_sor_cnt, .new = gm200_sor_new },
|
||||
.sor = { .cnt = gf119_sor_cnt, .new = gp100_sor_new },
|
||||
};
|
||||
|
||||
int
|
||||
|
|
|
@ -201,6 +201,7 @@ int gf119_sor_new(struct nvkm_disp *, int);
|
|||
int gk104_sor_new(struct nvkm_disp *, int);
|
||||
int gm107_sor_new(struct nvkm_disp *, int);
|
||||
int gm200_sor_new(struct nvkm_disp *, int);
|
||||
int gp100_sor_new(struct nvkm_disp *, int);
|
||||
|
||||
int gv100_sor_cnt(struct nvkm_disp *, unsigned long *);
|
||||
int gv100_sor_new(struct nvkm_disp *, int);
|
||||
|
|
|
@ -0,0 +1,59 @@
|
|||
/*
|
||||
* Copyright 2020 Red Hat Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and associated documentation files (the "Software"),
|
||||
* to deal in the Software without restriction, including without limitation
|
||||
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||
* and/or sell copies of the Software, and to permit persons to whom the
|
||||
* Software is furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
||||
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
||||
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
* OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
#include "ior.h"
|
||||
|
||||
static const struct nvkm_ior_func
|
||||
gp100_sor = {
|
||||
.route = {
|
||||
.get = gm200_sor_route_get,
|
||||
.set = gm200_sor_route_set,
|
||||
},
|
||||
.state = gf119_sor_state,
|
||||
.power = nv50_sor_power,
|
||||
.clock = gf119_sor_clock,
|
||||
.hdmi = {
|
||||
.ctrl = gk104_hdmi_ctrl,
|
||||
.scdc = gm200_hdmi_scdc,
|
||||
},
|
||||
.dp = {
|
||||
.lanes = { 0, 1, 2, 3 },
|
||||
.links = gf119_sor_dp_links,
|
||||
.power = g94_sor_dp_power,
|
||||
.pattern = gm107_sor_dp_pattern,
|
||||
.drive = gm200_sor_dp_drive,
|
||||
.vcpi = gf119_sor_dp_vcpi,
|
||||
.audio = gf119_sor_dp_audio,
|
||||
.audio_sym = gf119_sor_dp_audio_sym,
|
||||
.watermark = gf119_sor_dp_watermark,
|
||||
},
|
||||
.hda = {
|
||||
.hpd = gf119_hda_hpd,
|
||||
.eld = gf119_hda_eld,
|
||||
.device_entry = gf119_hda_device_entry,
|
||||
},
|
||||
};
|
||||
|
||||
int
|
||||
gp100_sor_new(struct nvkm_disp *disp, int id)
|
||||
{
|
||||
return nvkm_ior_new_(&gp100_sor, disp, SOR, id);
|
||||
}
|
Loading…
Reference in New Issue