drm/i915: workaround sparse warning on variable length arrays
authorJani Nikula <jani.nikula@intel.com>
Tue, 4 Oct 2016 09:54:12 +0000 (12:54 +0300)
committerJani Nikula <jani.nikula@intel.com>
Fri, 28 Oct 2016 12:17:50 +0000 (15:17 +0300)
commit7a0e17bd5d5a20784431df24601bfafec9d8ec61
tree30b626ff4d8ef0cfbfde58174b22b88a41ca6b42
parent9cccc76bb49ffcc0370a37a6c01368d69cc3b65b
drm/i915: workaround sparse warning on variable length arrays

Fix sparse warning:

drivers/gpu/drm/i915/intel_device_info.c:195:31: warning: Variable
length array is used.

In truth the array does have constant length, but sparse is too dumb to
realize. This is a bit ugly, but silence the warning no matter what.

Fixes: 91bedd34abf0 ("drm/i915/bdw: Check for slice, subslice and EU count for BDW")
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1475574853-4178-1-git-send-email-jani.nikula@intel.com
(cherry picked from commit ff64aa1e630087381511c4d25de0657824f40efa)
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/intel_device_info.c