summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorImre Deak <imre.deak@intel.com>2021-03-25 23:47:48 +0200
committerImre Deak <imre.deak@intel.com>2021-03-29 22:54:50 +0300
commit54c2921f7e9eeb7bb17e7174fb83c833503277f5 (patch)
tree95e9c81590c46b794ba9a8bb9ba85e6642ee7743
parent8a949222ea822ed1eb3f995006a2531cbee15e4d (diff)
downloadlinux-stable-54c2921f7e9eeb7bb17e7174fb83c833503277f5.tar.gz
linux-stable-54c2921f7e9eeb7bb17e7174fb83c833503277f5.tar.bz2
linux-stable-54c2921f7e9eeb7bb17e7174fb83c833503277f5.zip
drm/i915/selftest: Make sure to init i915_ggtt_view in igt_vma_rotate_remap()
This probably doesn't cause an issue, since the code checks the view type dependent size of the views before comparing them, but let's follow the practice to bzero the whole struct when initializing it. v2: Use {} instead of { } struct intializer. (Ville) Signed-off-by: Imre Deak <imre.deak@intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20210325214808.2071517-6-imre.deak@intel.com
-rw-r--r--drivers/gpu/drm/i915/selftests/i915_vma.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/selftests/i915_vma.c b/drivers/gpu/drm/i915/selftests/i915_vma.c
index 23f6a212a391..9dd6799105e6 100644
--- a/drivers/gpu/drm/i915/selftests/i915_vma.c
+++ b/drivers/gpu/drm/i915/selftests/i915_vma.c
@@ -515,7 +515,7 @@ static int igt_vma_rotate_remap(void *arg)
for (t = types; *t; t++) {
for (a = planes; a->width; a++) {
for (b = planes + ARRAY_SIZE(planes); b-- != planes; ) {
- struct i915_ggtt_view view;
+ struct i915_ggtt_view view = {};
unsigned int n, max_offset;
max_offset = max(a->stride * a->height,