diff options
author | Rob Clark <robdclark@gmail.com> | 2014-02-04 14:16:04 -0500 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2014-03-31 10:27:46 -0400 |
commit | 4e1cbaa3eb1c051d330f0586045bb719a8b9a8ae (patch) | |
tree | 386054ebbc5fc712df65698fca2d12a6b2ef6377 /drivers/gpu/drm/msm/adreno | |
parent | 37d77c3ab589bf8e3160a33b651fe6dd7439ba48 (diff) | |
download | blackbird-op-linux-4e1cbaa3eb1c051d330f0586045bb719a8b9a8ae.tar.gz blackbird-op-linux-4e1cbaa3eb1c051d330f0586045bb719a8b9a8ae.zip |
drm/msm: add chip-id param
Some of the w/a or different behavior of userspace blob driver seem to
be keyed to gpu patch revision, rather than gpu-id. So expose the full
chip-id to userspace so it can DTRT.
Signed-off-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/msm/adreno')
-rw-r--r-- | drivers/gpu/drm/msm/adreno/adreno_gpu.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpu/drm/msm/adreno/adreno_gpu.c b/drivers/gpu/drm/msm/adreno/adreno_gpu.c index 7a11563379b8..28ca8cd8b09e 100644 --- a/drivers/gpu/drm/msm/adreno/adreno_gpu.c +++ b/drivers/gpu/drm/msm/adreno/adreno_gpu.c @@ -73,6 +73,12 @@ int adreno_get_param(struct msm_gpu *gpu, uint32_t param, uint64_t *value) case MSM_PARAM_GMEM_SIZE: *value = adreno_gpu->gmem; return 0; + case MSM_PARAM_CHIP_ID: + *value = adreno_gpu->rev.patchid | + (adreno_gpu->rev.minor << 8) | + (adreno_gpu->rev.major << 16) | + (adreno_gpu->rev.core << 24); + return 0; default: DBG("%s: invalid param: %u", gpu->name, param); return -EINVAL; |