[Nouveau] [PATCH 01/15] tegra: fetch gpu_speedo_id
Alexandre Courbot
acourbot at nvidia.com
Wed Jun 1 08:39:15 UTC 2016
The GPU speedo ID is required to select the right clk/volt parameters on
GM20B.
Signed-off-by: Alexandre Courbot <acourbot at nvidia.com>
---
drm/nouveau/include/nvkm/core/tegra.h | 1 +
drm/nouveau/nvkm/engine/device/tegra.c | 1 +
lib/include/nvif/os.h | 1 +
3 files changed, 3 insertions(+)
diff --git a/drm/nouveau/include/nvkm/core/tegra.h b/drm/nouveau/include/nvkm/core/tegra.h
index b5370cb56e3c..e5c9b6268dcc 100644
--- a/drm/nouveau/include/nvkm/core/tegra.h
+++ b/drm/nouveau/include/nvkm/core/tegra.h
@@ -28,6 +28,7 @@ struct nvkm_device_tegra {
} iommu;
int gpu_speedo;
+ int gpu_speedo_id;
};
struct nvkm_device_tegra_func {
diff --git a/drm/nouveau/nvkm/engine/device/tegra.c b/drm/nouveau/nvkm/engine/device/tegra.c
index 8edc0a583ae2..9b638bd905ff 100644
--- a/drm/nouveau/nvkm/engine/device/tegra.c
+++ b/drm/nouveau/nvkm/engine/device/tegra.c
@@ -311,6 +311,7 @@ nvkm_device_tegra_new(const struct nvkm_device_tegra_func *func,
goto remove;
tdev->gpu_speedo = tegra_sku_info.gpu_speedo_value;
+ tdev->gpu_speedo_id = tegra_sku_info.gpu_speedo_id;
ret = nvkm_device_ctor(&nvkm_device_tegra_func, NULL, &pdev->dev,
NVKM_DEVICE_TEGRA, pdev->id, NULL,
cfg, dbg, detect, mmio, subdev_mask,
diff --git a/lib/include/nvif/os.h b/lib/include/nvif/os.h
index f0710b39c05b..ba253b0f1d37 100644
--- a/lib/include/nvif/os.h
+++ b/lib/include/nvif/os.h
@@ -1546,6 +1546,7 @@ reset_control_deassert(struct reset_control *reset)
*****************************************************************************/
struct tegra_sku_info {
int gpu_speedo_value;
+ int gpu_speedo_id;
};
extern struct tegra_sku_info tegra_sku_info;
--
2.8.3
More information about the Nouveau
mailing list