summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBas Nieuwenhuizen <[email protected]>2018-06-15 00:01:43 +0200
committerBas Nieuwenhuizen <[email protected]>2018-06-16 19:03:47 +0200
commitc4714f698bf1eda6ee77304f8abe0a92be7a55e7 (patch)
treea7569c43387736553ac5bbc2dddae38cad840268 /src
parent5917761e3dddc968d5ccac9b282b7cb8d3da866f (diff)
ac: Clear meminfo to avoid valgrind warning.
Somehow valgrind misses that the value is initialized by the ioctl. Reviewed-by: Dave Airlie <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/amd/common/ac_gpu_info.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/amd/common/ac_gpu_info.c b/src/amd/common/ac_gpu_info.c
index e908cc6fa96..e885c0538e9 100644
--- a/src/amd/common/ac_gpu_info.c
+++ b/src/amd/common/ac_gpu_info.c
@@ -235,7 +235,7 @@ bool ac_query_gpu_info(int fd, amdgpu_device_handle dev,
}
if (info->drm_minor >= 9) {
- struct drm_amdgpu_memory_info meminfo;
+ struct drm_amdgpu_memory_info meminfo = {};
r = amdgpu_query_info(dev, AMDGPU_INFO_MEMORY, sizeof(meminfo), &meminfo);
if (r) {