diff options
Diffstat (limited to 'drivers/gpu/nvgpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/platform_gk20a_tegra.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/platform_gk20a_tegra.c b/drivers/gpu/nvgpu/gk20a/platform_gk20a_tegra.c index 675a85b3..db501ec2 100644 --- a/drivers/gpu/nvgpu/gk20a/platform_gk20a_tegra.c +++ b/drivers/gpu/nvgpu/gk20a/platform_gk20a_tegra.c | |||
@@ -279,7 +279,12 @@ void gk20a_tegra_calibrate_emc(struct platform_device *pdev, | |||
279 | 279 | ||
280 | static bool gk20a_tegra_is_railgated(struct platform_device *pdev) | 280 | static bool gk20a_tegra_is_railgated(struct platform_device *pdev) |
281 | { | 281 | { |
282 | return !tegra_powergate_is_powered(TEGRA_POWERGATE_GPU); | 282 | bool ret = false; |
283 | |||
284 | if (!tegra_platform_is_linsim()) | ||
285 | ret = !tegra_powergate_is_powered(TEGRA_POWERGATE_GPU); | ||
286 | |||
287 | return ret; | ||
283 | } | 288 | } |
284 | 289 | ||
285 | /* | 290 | /* |
@@ -290,7 +295,8 @@ static bool gk20a_tegra_is_railgated(struct platform_device *pdev) | |||
290 | 295 | ||
291 | static int gk20a_tegra_railgate(struct platform_device *pdev) | 296 | static int gk20a_tegra_railgate(struct platform_device *pdev) |
292 | { | 297 | { |
293 | if (tegra_powergate_is_powered(TEGRA_POWERGATE_GPU)) | 298 | if (!tegra_platform_is_linsim() && |
299 | tegra_powergate_is_powered(TEGRA_POWERGATE_GPU)) | ||
294 | tegra_powergate_partition(TEGRA_POWERGATE_GPU); | 300 | tegra_powergate_partition(TEGRA_POWERGATE_GPU); |
295 | return 0; | 301 | return 0; |
296 | } | 302 | } |
@@ -303,8 +309,9 @@ static int gk20a_tegra_railgate(struct platform_device *pdev) | |||
303 | 309 | ||
304 | static int gk20a_tegra_unrailgate(struct platform_device *pdev) | 310 | static int gk20a_tegra_unrailgate(struct platform_device *pdev) |
305 | { | 311 | { |
306 | int ret; | 312 | int ret = 0; |
307 | ret = tegra_unpowergate_partition(TEGRA_POWERGATE_GPU); | 313 | if (!tegra_platform_is_linsim()) |
314 | ret = tegra_unpowergate_partition(TEGRA_POWERGATE_GPU); | ||
308 | return ret; | 315 | return ret; |
309 | } | 316 | } |
310 | 317 | ||