[Nouveau] [PATCH 2/3] pci/gk104: enable dl_mgr safe mode
Karol Herbst
kherbst at redhat.com
Thu Sep 12 19:00:27 UTC 2019
no idea why and what it does, taken from nvgpu
Signed-off-by: Karol Herbst <kherbst at redhat.com>
---
drm/nouveau/nvkm/subdev/pci/gk104.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drm/nouveau/nvkm/subdev/pci/gk104.c b/drm/nouveau/nvkm/subdev/pci/gk104.c
index b73922c52..6aeb07fe4 100644
--- a/drm/nouveau/nvkm/subdev/pci/gk104.c
+++ b/drm/nouveau/nvkm/subdev/pci/gk104.c
@@ -184,6 +184,7 @@ gk104_pcie_set_link(struct nvkm_pci *pci, enum nvkm_pcie_speed speed, u8 width)
struct nvkm_subdev *subdev = &pci->subdev;
enum nvkm_pcie_speed lnk_ctl_speed = gk104_pcie_lnkctl_speed(pci);
enum nvkm_pcie_speed lnk_cap_speed = gk104_pcie_cap_speed(pci);
+ u32 old_dl_mgr;
if (speed > lnk_cap_speed) {
speed = lnk_cap_speed;
@@ -197,7 +198,9 @@ gk104_pcie_set_link(struct nvkm_pci *pci, enum nvkm_pcie_speed speed, u8 width)
" lnkctl speed\n");
}
+ old_dl_mgr = nvkm_mask(subdev->device, 0x8b8c0, 0x4, 0x4);
gk104_pcie_set_link_speed(pci, speed);
+ nvkm_wr32(subdev->device, 0x8b8c0, old_dl_mgr);
return 0;
}
--
2.21.0
More information about the Nouveau
mailing list