]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
drm/msm/a6xx: Replace kcalloc() with kvzalloc()
authorAkhil P Oommen <quic_akhilpo@quicinc.com>
Wed, 28 Sep 2022 07:18:59 +0000 (12:48 +0530)
committerRob Clark <robdclark@chromium.org>
Fri, 30 Sep 2022 16:01:41 +0000 (09:01 -0700)
commitec8f1813bf8d0737898f99a8c1c69df0cde0d7dd
tree53bf25727b24d3ab9d0b1d273378ecd074381d25
parent084b9e1732f71e36c21a820162c9f601577932c6
drm/msm/a6xx: Replace kcalloc() with kvzalloc()

In order to reduce chance of allocation failure while capturing a6xx
gpu state, use kvzalloc() instead of kcalloc() in state_kcalloc().

Indirectly, this patch helps to fix leaking memory allocated for
gmu_debug object.

Fixes: b859f9b009b (drm/msm/gpu: Snapshot GMU debug buffer)
Signed-off-by: Akhil P Oommen <quic_akhilpo@quicinc.com>
Patchwork: https://patchwork.freedesktop.org/patch/505074/
Link: https://lore.kernel.org/r/20220928124830.1.I8ea24a8d586b4978823b848adde000f92f74d5c2@changeid
Signed-off-by: Rob Clark <robdclark@chromium.org>
drivers/gpu/drm/msm/adreno/a6xx_gpu_state.c