aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_request.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2021-07-21 20:32:29 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2021-07-22 11:14:14 +0200
commit4f62a7e0d3338771261a945ceb87182e911a4f71 (patch)
treed3b2f028b67ef9b9a187e31e0ee36f9fdf31d226 /drivers/gpu/drm/i915/i915_request.c
parentdrm/i915: Make GT workaround upper bounds exclusive (diff)
downloadlinux-dev-4f62a7e0d3338771261a945ceb87182e911a4f71.tar.xz
linux-dev-4f62a7e0d3338771261a945ceb87182e911a4f71.zip
drm/i915: Ditch i915 globals shrink infrastructure
This essentially reverts commit 84a1074920523430f9dc30ff907f4801b4820072 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Jan 24 11:36:08 2018 +0000 drm/i915: Shrink the GEM kmem_caches upon idling mm/vmscan.c:do_shrink_slab() is a thing, if there's an issue with it then we need to fix that there, not hand-roll our own slab shrinking code in i915. Also when this was added there was only one other caller of kmem_cache_shrink (added 2005 to the acpi code). Now there's a 2nd one outside of i915 code in a kunit test, which seems legit since that wants to very carefully control what's in the kmem_cache. This out of a total of over 500 calls to kmem_cache_create. This alone should have been warning sign enough that we're doing something silly. Noticed while reviewing a patch set from Jason to fix up some issues in our i915_init() and i915_exit() module load/cleanup code. Now that i915_globals.c isn't any different than normal init/exit functions, we should convert them over to one unified table and remove i915_globals.[hc] entirely. v2: Improve commit message (Jason) Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Cc: David Airlie <airlied@linux.ie> Cc: Jason Ekstrand <jason@jlekstrand.net> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20210721183229.4136488-1-daniel.vetter@ffwll.ch
Diffstat (limited to 'drivers/gpu/drm/i915/i915_request.c')
-rw-r--r--drivers/gpu/drm/i915/i915_request.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/drivers/gpu/drm/i915/i915_request.c b/drivers/gpu/drm/i915/i915_request.c
index 09ebea9a0090..d3de9f60e03a 100644
--- a/drivers/gpu/drm/i915/i915_request.c
+++ b/drivers/gpu/drm/i915/i915_request.c
@@ -2077,12 +2077,6 @@ void i915_request_show(struct drm_printer *m,
#include "selftests/i915_request.c"
#endif
-static void i915_global_request_shrink(void)
-{
- kmem_cache_shrink(global.slab_execute_cbs);
- kmem_cache_shrink(global.slab_requests);
-}
-
static void i915_global_request_exit(void)
{
kmem_cache_destroy(global.slab_execute_cbs);
@@ -2090,7 +2084,6 @@ static void i915_global_request_exit(void)
}
static struct i915_global_request global = { {
- .shrink = i915_global_request_shrink,
.exit = i915_global_request_exit,
} };