{
VkResult result;
int fd;
- uint32_t gen10x;
fd = open(path, O_RDWR | O_CLOEXEC);
if (fd < 0)
goto fail;
}
- gen10x = 10 * device->info->gen;
- if (device->info->is_haswell)
- gen10x += 5;
-
if (device->info->gen == 7 &&
!device->info->is_haswell && !device->info->is_baytrail) {
fprintf(stderr, "WARNING: Ivy Bridge Vulkan support is incomplete\n");
device->compiler->shader_debug_log = compiler_debug_log;
device->compiler->shader_perf_log = compiler_perf_log;
- isl_device_init(&device->isl_dev, gen10x);
+ isl_device_init(&device->isl_dev, device->info);
return VK_SUCCESS;
}
void
-isl_device_init(struct isl_device *dev, uint8_t gen10x)
+isl_device_init(struct isl_device *dev,
+ const struct brw_device_info *info)
{
- assert(gen10x % 5 == 0);
- dev->gen = gen10x;
+ dev->info = info;
}
/**
extern "C" {
#endif
+struct brw_device_info;
+
/**
* WARNING: These values differ from the hardware enum values, which are
* unstable across hardware generations.
};
struct isl_device {
- /**
- * @brief Hardware generation, 10x.
- *
- * For example, gen is 70 for Ivybridge and Baytrail; gen is 75 for
- * Haswell.
- */
- uint8_t gen;
+ const struct brw_device_info *info;
};
struct isl_extent2d {
};
void
-isl_device_init(struct isl_device *dev, uint8_t gen10x);
+isl_device_init(struct isl_device *dev,
+ const struct brw_device_info *info);
void
isl_tiling_get_extent(const struct isl_device *dev,