[Intel-gfx] [PATCH v2 05/25] drm/i915/selftest: Make sure to init i915_ggtt_view in igt_vma_rotate_remap()
Imre Deak
imre.deak at intel.com
Thu Mar 25 21:47:48 UTC 2021
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 at intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
---
drivers/gpu/drm/i915/selftests/i915_vma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/selftests/i915_vma.c b/drivers/gpu/drm/i915/selftests/i915_vma.c
index 23f6a212a391d..9dd6799105e66 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,
--
2.25.1
More information about the Intel-gfx
mailing list