kms_fbc_crc: Use I915_TILING_X to create fbs
[platform/upstream/intel-gpu-tools.git] / tools / intel_dump_decode.c
index a3cd2e5..a8dcca0 100644 (file)
@@ -158,6 +158,7 @@ int
 main (int argc, char *argv[])
 {
        uint32_t devid = 0xa011;
+       char *devid_str = NULL;
        int i, c;
        int option_index = 0;
        int binary = -1;
@@ -168,11 +169,13 @@ main (int argc, char *argv[])
                {"binary", 0, 0, 'b'}
        };
 
-       while((c = getopt_long(argc, argv, "ab",
+       devid_str = getenv("INTEL_DEVID_OVERRIDE");
+
+       while((c = getopt_long(argc, argv, "ad:b",
                               long_options, &option_index)) != -1) {
                switch(c) {
                case 'd':
-                       devid = strtoul(optarg, NULL, 0);
+                       devid_str = optarg;
                        break;
                case 'b':
                        binary = 1;
@@ -186,6 +189,9 @@ main (int argc, char *argv[])
                }
        }
 
+       if (devid_str)
+               devid = strtoul(devid_str, NULL, 0);
+
        ctx = drm_intel_decode_context_alloc(devid);
 
        if (optind == argc) {