diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2017-05-19 23:59:35 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2017-06-16 14:05:00 +1000 |
commit | 8d7ef84d908877708001f3334dbf44e9d48fad57 (patch) | |
tree | f6f79521bdc749bd25f6dbcc5799f4b8ea808175 /drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c | |
parent | 1f0c9eaf31bba3e1cac5534ba17602c115b76cf8 (diff) | |
download | talos-obmc-linux-8d7ef84d908877708001f3334dbf44e9d48fad57.tar.gz talos-obmc-linux-8d7ef84d908877708001f3334dbf44e9d48fad57.zip |
drm/nouveau/disp/nv50-: implement a common supervisor 2.2
This makes use of all the additional routing and state added in previous
commits, making it possible to deal with GM20x macro link routing, while
also sharing code between the NV50 and GF119 implementations.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c index 2ca600c744cd..dbb303db3178 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/sornv50.c @@ -25,6 +25,15 @@ #include <subdev/timer.h> +void +nv50_sor_clock(struct nvkm_ior *sor) +{ + struct nvkm_device *device = sor->disp->engine.subdev.device; + const int div = sor->asy.link == 3; + const u32 soff = nv50_ior_base(sor); + nvkm_mask(device, 0x614300 + soff, 0x00000707, (div << 8) | div); +} + static void nv50_sor_power_wait(struct nvkm_device *device, u32 soff) { @@ -79,6 +88,7 @@ static const struct nvkm_ior_func nv50_sor = { .state = nv50_sor_state, .power = nv50_sor_power, + .clock = nv50_sor_clock, }; int |