iris: fail to create screen for older unsupported HW
authorKenneth Graunke <kenneth@whitecape.org>
Mon, 14 Jan 2019 08:25:23 +0000 (00:25 -0800)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:11 +0000 (10:26 -0800)
loader shouldn't try, but let's be paranoid

src/gallium/drivers/iris/iris_screen.c

index 64514cddbc4013c3501d5ad1964c0b0004705c70..9da3369d7c28ddcca1888b75f358adf9280615aa 100644 (file)
@@ -555,6 +555,9 @@ iris_screen_create(int fd)
    if (!gen_get_device_info(screen->pci_id, &screen->devinfo))
       return NULL;
 
+   if (screen->devinfo.gen < 8 || screen->devinfo.is_cherryview)
+      return NULL;
+
    screen->devinfo.timestamp_frequency =
       iris_getparam_integer(screen, I915_PARAM_CS_TIMESTAMP_FREQUENCY);