mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-22 09:12:24 +03:00
gpu: nvgpu: Turn off scaling when not powered
This far the scaling has been disabled only when we suspend the system and therefore we unnecessarily keep gpu workers running even if the gpu itself would be railgated. This is not proper behaviour and it causes a race in suspend sequence. This patch reorders scaling disable to happen always when we turn off the GPU. Bug 200004860 Change-Id: Ief0bfd89378d5a7ced26c3ef29094dd5c378b01a Signed-off-by: Santosh Katvate <skatvate@nvidia.com> Reviewed-on: http://git-master/r/410443 (cherry picked from commit bcae65bea24be2a1e0abe42522d99ba70c94cbe2) Reviewed-on: http://git-master/r/413249 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
This commit is contained in:
committed by
Dan Willemsen
parent
8144bf6416
commit
3899f3b997
@@ -747,6 +747,8 @@ static int gk20a_pm_prepare_poweroff(struct device *dev)
|
||||
|
||||
gk20a_dbg_fn("");
|
||||
|
||||
gk20a_scale_suspend(to_platform_device(dev));
|
||||
|
||||
if (!g->power_on)
|
||||
return 0;
|
||||
|
||||
@@ -1205,8 +1207,6 @@ static int gk20a_pm_suspend(struct device *dev)
|
||||
if (atomic_read(&dev->power.usage_count) > 1)
|
||||
return -EBUSY;
|
||||
|
||||
gk20a_scale_suspend(to_platform_device(dev));
|
||||
|
||||
ret = gk20a_pm_prepare_poweroff(dev);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
Reference in New Issue
Block a user