]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/shrinker: Report "unevictable" pages
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 20 Apr 2016 11:09:51 +0000 (12:09 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 20 Apr 2016 12:47:43 +0000 (13:47 +0100)
commitf4c47115af9a8468ef95de53928915391837fd78
treec8fea4d9f8ff9552e699fcbdc0786422366f5826
parent8e9d6c2f244707b43a5cc099ce5236d0be8c6eab
drm/i915/shrinker: Report "unevictable" pages

Inside the shrinker we call can_release_pages() to indicate whether or
not we can make forward progress in freeing up memory by unbinding that
object. When adding our report to oom, we should be using the same
logic.

Whilst here, change the reporting from bytes to pages so that it looks
smaller to the user!, is consistent with the neighbouring oom report
itself which displays counts in pages, and makes the unsigned long
overflow less likely.

v2: Split oversized format string into two lines

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1461150592-27818-2-git-send-email-chris@chris-wilson.co.uk
Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
drivers/gpu/drm/i915/i915_gem_shrinker.c