Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bad3d80f authored by Karol Herbst's avatar Karol Herbst Committed by Ben Skeggs
Browse files

drm/nouveau: Revert "bus: remove cpu_coherent flag"



This reverts commit aff51175.

The commit caused fence timeouts within nvc0_screen_destroy and most likely
other places as well.

The most obvious effect is, that userspace processes take minutes to
actually quit.

Signed-off-by: default avatarKarol Herbst <karolherbst@gmail.com>
Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
parent 666ca3d8
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -175,6 +175,7 @@ struct nvkm_device_func {
	void (*fini)(struct nvkm_device *, bool suspend);
	resource_size_t (*resource_addr)(struct nvkm_device *, unsigned bar);
	resource_size_t (*resource_size)(struct nvkm_device *, unsigned bar);
	bool cpu_coherent;
};

struct nvkm_device_quirk {
+2 −1
Original line number Diff line number Diff line
@@ -209,6 +209,7 @@ nouveau_bo_new(struct drm_device *dev, int size, int align,
	nvbo->tile_flags = tile_flags;
	nvbo->bo.bdev = &drm->ttm.bdev;

	if (!nvxx_device(&drm->device)->func->cpu_coherent)
		nvbo->force_coherent = flags & TTM_PL_FLAG_UNCACHED;

	nvbo->page_shift = 12;
+1 −0
Original line number Diff line number Diff line
@@ -1614,6 +1614,7 @@ nvkm_device_pci_func = {
	.fini = nvkm_device_pci_fini,
	.resource_addr = nvkm_device_pci_resource_addr,
	.resource_size = nvkm_device_pci_resource_size,
	.cpu_coherent = !IS_ENABLED(CONFIG_ARM),
};

int
+1 −0
Original line number Diff line number Diff line
@@ -245,6 +245,7 @@ nvkm_device_tegra_func = {
	.fini = nvkm_device_tegra_fini,
	.resource_addr = nvkm_device_tegra_resource_addr,
	.resource_size = nvkm_device_tegra_resource_size,
	.cpu_coherent = false,
};

int