summaryrefslogtreecommitdiffstats
path: root/src/drm-shim
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2019-05-13 14:03:07 -0700
committerEric Anholt <[email protected]>2019-07-25 08:56:19 -0700
commit494ecef6b42198ab6c3eaa8b3e5222643e1e44ff (patch)
treedab3af595af0fbdd6fd2fdafb0e8cc3ef5335146 /src/drm-shim
parent82bf1979d7b7d83e8e213b11ff7787e6939c8f7e (diff)
freedreno: Add support for drm-shim.
I'm using this for shader-db analysis on x86_64 systems. Reviewed-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/drm-shim')
-rw-r--r--src/drm-shim/device.c4
-rw-r--r--src/drm-shim/drm_shim.h1
2 files changed, 5 insertions, 0 deletions
diff --git a/src/drm-shim/device.c b/src/drm-shim/device.c
index fe1cbbba351..8020c2ae5cc 100644
--- a/src/drm-shim/device.c
+++ b/src/drm-shim/device.c
@@ -130,6 +130,10 @@ drm_shim_ioctl_version(int fd, unsigned long request, void *arg)
const char *date = "20190320";
const char *desc = "shim";
+ args->version_major = shim_device.version_major;
+ args->version_minor = shim_device.version_minor;
+ args->version_patchlevel = shim_device.version_patchlevel;
+
if (args->name)
strncpy(args->name, shim_device.driver_name, args->name_len);
if (args->date)
diff --git a/src/drm-shim/drm_shim.h b/src/drm-shim/drm_shim.h
index b14353a7962..2cd053f6d65 100644
--- a/src/drm-shim/drm_shim.h
+++ b/src/drm-shim/drm_shim.h
@@ -43,6 +43,7 @@ struct shim_device {
/* Returned by drmGetVersion(). */
const char *driver_name;
+ int version_major, version_minor, version_patchlevel;
};
extern struct shim_device shim_device;