]> www.infradead.org Git - users/hch/misc.git/commitdiff
drm/panfrost: Print RSS for tiler heap BO's in debugfs GEMS file
authorAdrián Larumbe <adrian.larumbe@collabora.com>
Fri, 8 Aug 2025 01:02:34 +0000 (02:02 +0100)
committerThomas Zimmermann <tzimmermann@suse.de>
Tue, 12 Aug 2025 06:31:47 +0000 (08:31 +0200)
Otherwise it would display the virtual allocation size, which is often
much bigger than the RSS.

Signed-off-by: Adrián Larumbe <adrian.larumbe@collabora.com>
Fixes: e48ade5e23ba ("drm/panfrost: show device-wide list of DRM GEM objects over DebugFS")
Tested-by: Christopher Healy <healych@amazon.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://lore.kernel.org/r/20250808010235.2831853-1-adrian.larumbe@collabora.com
drivers/gpu/drm/panfrost/panfrost_gem.c

index bb73f2a68a12f10d4815ac1b676055d011f8be19..85d6289a6eda45e58abaae882d458703f6992910 100644 (file)
@@ -432,7 +432,7 @@ static void panfrost_gem_debugfs_bo_print(struct panfrost_gem_object *bo,
        if (!refcount)
                return;
 
-       resident_size = bo->base.pages ? bo->base.base.size : 0;
+       resident_size = panfrost_gem_rss(&bo->base.base);
 
        snprintf(creator_info, sizeof(creator_info),
                 "%s/%d", bo->debugfs.creator.process_name, bo->debugfs.creator.tgid);