This is just a copy-and-paste from brw_surface_formats.c. For the supports_vertex_fetch function, we do a bit more work so that it properly handles Bay Trail.
7374d00 isl: Add per-gen format introspection
src/intel/isl/isl.h | 13 ++
src/intel/isl/isl_format.c | 386 ++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 399 insertions(+)
Upstream: cgit.freedesktop.org