aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau
diff options
context:
space:
mode:
authorVince Hsu <vinceh@nvidia.com>2014-12-01 23:50:34 -0500
committerBen Skeggs <bskeggs@redhat.com>2014-12-02 00:44:08 -0500
commit37025602f6abc5919c7d5a8517bc7d6ea08acc57 (patch)
tree51e998e5df0bdd42e2a263ce9bf828e8896a8466 /drivers/gpu/drm/nouveau
parent08c7f248be2a17a025e8a0dc1bc9e14231f0ff28 (diff)
drm/nouveau/platform: add GPU speedo information to nouveau platform
For GK20A we need the GPU speedo value to calculate voltage levels. Signed-off-by: Vince Hsu <vinceh@nvidia.com> Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_platform.c2
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_platform.h2
2 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_platform.c b/drivers/gpu/drm/nouveau/nouveau_platform.c
index 246a824c16ca..b307bbedd4c4 100644
--- a/drivers/gpu/drm/nouveau/nouveau_platform.c
+++ b/drivers/gpu/drm/nouveau/nouveau_platform.c
@@ -27,6 +27,7 @@
27#include <linux/of.h> 27#include <linux/of.h>
28#include <linux/reset.h> 28#include <linux/reset.h>
29#include <linux/regulator/consumer.h> 29#include <linux/regulator/consumer.h>
30#include <soc/tegra/fuse.h>
30#include <soc/tegra/pmc.h> 31#include <soc/tegra/pmc.h>
31 32
32#include "nouveau_drm.h" 33#include "nouveau_drm.h"
@@ -128,6 +129,7 @@ static int nouveau_platform_probe(struct platform_device *pdev)
128 } 129 }
129 130
130 device->gpu = gpu; 131 device->gpu = gpu;
132 device->gpu_speedo = tegra_sku_info.gpu_speedo_value;
131 133
132 err = drm_dev_register(drm, 0); 134 err = drm_dev_register(drm, 0);
133 if (err < 0) 135 if (err < 0)
diff --git a/drivers/gpu/drm/nouveau/nouveau_platform.h b/drivers/gpu/drm/nouveau/nouveau_platform.h
index 91f66504900e..58c28b5653d5 100644
--- a/drivers/gpu/drm/nouveau/nouveau_platform.h
+++ b/drivers/gpu/drm/nouveau/nouveau_platform.h
@@ -41,6 +41,8 @@ struct nouveau_platform_device {
41 struct nouveau_device device; 41 struct nouveau_device device;
42 42
43 struct nouveau_platform_gpu *gpu; 43 struct nouveau_platform_gpu *gpu;
44
45 int gpu_speedo;
44}; 46};
45 47
46#define nv_device_to_platform(d) \ 48#define nv_device_to_platform(d) \