summaryrefslogtreecommitdiffstats
path: root/src/intel/isl
diff options
context:
space:
mode:
authorLionel Landwerlin <lionel.g.landwerlin@intel.com>2016-09-22 14:58:11 +0300
committerLionel Landwerlin <lionel.g.landwerlin@intel.com>2016-09-23 10:11:59 +0300
commitbc24590f0c579a2528fd94eb8d40dd4ce12eba29 (patch)
tree0ec5dbc71ec3aa551586005282200b184251d51f /src/intel/isl
parente60928f4c4bd4484821d83f2b16a910ea9f5f9d9 (diff)
downloadexternal_mesa3d-bc24590f0c579a2528fd94eb8d40dd4ce12eba29.zip
external_mesa3d-bc24590f0c579a2528fd94eb8d40dd4ce12eba29.tar.gz
external_mesa3d-bc24590f0c579a2528fd94eb8d40dd4ce12eba29.tar.bz2
intel/i965: make gen_device_info mutable
Make gen_device_info a mutable structure so we can update the fields that can be refined by querying the kernel (like subslices and EU numbers). This patch does not make any functional change, it just makes gen_get_device_info() fill a structure rather than returning a const pointer. Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Diffstat (limited to 'src/intel/isl')
-rw-r--r--src/intel/isl/tests/isl_surf_get_image_offset_test.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/intel/isl/tests/isl_surf_get_image_offset_test.c b/src/intel/isl/tests/isl_surf_get_image_offset_test.c
index 5ce326f..1b3dc58 100644
--- a/src/intel/isl/tests/isl_surf_get_image_offset_test.c
+++ b/src/intel/isl/tests/isl_surf_get_image_offset_test.c
@@ -124,9 +124,11 @@ test_bdw_2d_r8g8b8a8_unorm_512x512_array01_samples01_noaux_tiley0(void)
{
bool ok;
+ struct gen_device_info devinfo;
+ t_assert(gen_get_device_info(BDW_GT2_DEVID, &devinfo));
+
struct isl_device dev;
- isl_device_init(&dev, gen_get_device_info(BDW_GT2_DEVID),
- /*bit6_swizzle*/ false);
+ isl_device_init(&dev, &devinfo, /*bit6_swizzle*/ false);
struct isl_surf surf;
ok = isl_surf_init(&dev, &surf,
@@ -170,9 +172,11 @@ test_bdw_2d_r8g8b8a8_unorm_1024x1024_array06_samples01_noaux_tiley0(void)
{
bool ok;
+ struct gen_device_info devinfo;
+ t_assert(gen_get_device_info(BDW_GT2_DEVID, &devinfo));
+
struct isl_device dev;
- isl_device_init(&dev, gen_get_device_info(BDW_GT2_DEVID),
- /*bit6_swizzle*/ false);
+ isl_device_init(&dev, &devinfo, /*bit6_swizzle*/ false);
struct isl_surf surf;
ok = isl_surf_init(&dev, &surf,
@@ -229,9 +233,11 @@ test_bdw_3d_r8g8b8a8_unorm_256x256x256_levels09_tiley0(void)
{
bool ok;
+ struct gen_device_info devinfo;
+ t_assert(gen_get_device_info(BDW_GT2_DEVID, &devinfo));
+
struct isl_device dev;
- isl_device_init(&dev, gen_get_device_info(BDW_GT2_DEVID),
- /*bit6_swizzle*/ false);
+ isl_device_init(&dev, &devinfo, /*bit6_swizzle*/ false);
struct isl_surf surf;
ok = isl_surf_init(&dev, &surf,