From: Christian König Date: Tue, 10 Mar 2020 13:23:12 +0000 (+0100) Subject: drm/amdgpu: improve amdgpu_gem_info debugfs file X-Git-Tag: v5.15~303^2~28^2~3081 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8523f8875bee3831ea602b2229e73e2fe096a354;p=platform%2Fkernel%2Flinux-starfive.git drm/amdgpu: improve amdgpu_gem_info debugfs file Note if a buffer was imported using peer2peer. Signed-off-by: Christian König Acked-by: Daniel Vetter Acked-by: Sumit Semwal Link: https://patchwork.freedesktop.org/patch/359296 --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c index 4277125a79ee..e42608115c99 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c @@ -29,6 +29,7 @@ #include #include #include +#include #include #include @@ -854,7 +855,8 @@ static int amdgpu_debugfs_gem_bo_info(int id, void *ptr, void *data) attachment = READ_ONCE(bo->tbo.base.import_attach); if (attachment) - seq_printf(m, " imported from %p", dma_buf); + seq_printf(m, " imported from %p%s", dma_buf, + attachment->peer2peer ? " P2P" : ""); else if (dma_buf) seq_printf(m, " exported as %p", dma_buf);