OSDN Git Service

drm/nouveau/imem/nv50: support eviction of BAR2 mappings
authorBen Skeggs <bskeggs@redhat.com>
Tue, 31 Oct 2017 17:56:19 +0000 (03:56 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Thu, 2 Nov 2017 03:32:19 +0000 (13:32 +1000)
commit03edf1b31a091254e95793a688abf02b96cfdd85
tree125bc14c576874d8b92db654ba3e4941d0fa93c3
parent69b136f200006ee37b039195eaeb08942c419ecc
drm/nouveau/imem/nv50: support eviction of BAR2 mappings

A good deal of the structures we map into here aren't accessed very often
at all, and Fedora 26 has exposed an issue where after creating a heap of
channels, BAR2 space would run out, and we'd need to make use of the slow
path while accessing important structures like page tables.

This implements an LRU on BAR2 space, which allows eviction of mappings
that aren't currently needed, to make space for other objects.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nvkm/subdev/instmem/nv50.c