This patch series is aimed at providing UM with detailed memory profiling
information in debug builds. It is achieved through a device-wide list of
DRM GEM objects, and also implementing the ability to label BO's from UM
through a new IOCTL.
The new debugfs file shows a list of driver DRM GEM objects in tabular mode.
To visualise it, cat sudo cat /sys/kernel/debug/dri/*.gpu/gems.
To test this functionality from UM, please refer to this Mesa patch series:
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34224
Discussion of previous revision of this patch series can be found at:
https://lore.kernel.org/dri-devel/20250327140845.105962-1-adrian.larumbe@collabora.com/
Changelog:
v4:
- Labelled all kernel BO's, not just heap chunks.
- Refactored DebugGFs GEMs list handling functions
- Added debugfs GEMS node mask to tell different kinds of BO's
Adrián Larumbe (4):
drm/panthor: Introduce BO labeling
drm/panthor: Add driver IOCTL for setting BO labels
drm/panthor: Label all kernel BO's
drm/panthor: show device-wide list of DRM GEM objects over DebugFS
drivers/gpu/drm/panthor/panthor_device.c | 5 +
drivers/gpu/drm/panthor/panthor_device.h | 11 ++
drivers/gpu/drm/panthor/panthor_drv.c | 66 ++++++++
drivers/gpu/drm/panthor/panthor_fw.c | 8 +-
drivers/gpu/drm/panthor/panthor_gem.c | 190 ++++++++++++++++++++++-
drivers/gpu/drm/panthor/panthor_gem.h | 56 ++++++-
drivers/gpu/drm/panthor/panthor_heap.c | 6 +-
drivers/gpu/drm/panthor/panthor_sched.c | 9 +-
include/uapi/drm/panthor_drm.h | 19 +++
9 files changed, 360 insertions(+), 10 deletions(-)
--
2.48.1