drm/msm/gpu: Add GEM debug label to devcore

When trying to understand an iova fault devcore, once you figure out
which buffer we accessed beyond the end of, it is useful to see the
buffer's debug label.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Patchwork: https://patchwork.freedesktop.org/patch/491910/
Link: https://lore.kernel.org/r/20220629211919.563585-3-robdclark@gmail.com
This commit is contained in:
Rob Clark
2022-06-29 14:19:16 -07:00
parent cc66a42c94
commit 18514c3848
3 changed files with 6 additions and 0 deletions
+1
View File
@@ -824,6 +824,7 @@ void adreno_show(struct msm_gpu *gpu, struct msm_gpu_state *state,
drm_printf(p, " - iova: 0x%016llx\n",
state->bos[i].iova);
drm_printf(p, " size: %zd\n", state->bos[i].size);
drm_printf(p, " name: %-32s\n", state->bos[i].name);
adreno_show_object(p, &state->bos[i].data,
state->bos[i].size, &state->bos[i].encoded);
+4
View File
@@ -229,6 +229,10 @@ static void msm_gpu_crashstate_get_bo(struct msm_gpu_state *state,
state_bo->size = obj->base.size;
state_bo->iova = iova;
BUILD_BUG_ON(sizeof(state_bo->name) != sizeof(obj->name));
memcpy(state_bo->name, obj->name, sizeof(state_bo->name));
if (full) {
void *ptr;
+1
View File
@@ -489,6 +489,7 @@ struct msm_gpu_state_bo {
size_t size;
void *data;
bool encoded;
char name[32];
};
struct msm_gpu_state {