diff options
Diffstat (limited to 'drivers/gpu/nvgpu/os/linux/module.c')
-rw-r--r-- | drivers/gpu/nvgpu/os/linux/module.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/os/linux/module.c b/drivers/gpu/nvgpu/os/linux/module.c index 4516490b..2df8ab42 100644 --- a/drivers/gpu/nvgpu/os/linux/module.c +++ b/drivers/gpu/nvgpu/os/linux/module.c | |||
@@ -458,7 +458,7 @@ int __gk20a_do_idle(struct gk20a *g, bool force_reset) | |||
458 | * If User disables rail gating, we take one more | 458 | * If User disables rail gating, we take one more |
459 | * extra refcount | 459 | * extra refcount |
460 | */ | 460 | */ |
461 | if (g->can_railgate) | 461 | if (nvgpu_is_enabled(g, NVGPU_CAN_RAILGATE)) |
462 | target_ref_cnt = 1; | 462 | target_ref_cnt = 1; |
463 | else | 463 | else |
464 | target_ref_cnt = 2; | 464 | target_ref_cnt = 2; |
@@ -485,7 +485,7 @@ int __gk20a_do_idle(struct gk20a *g, bool force_reset) | |||
485 | nvgpu_timeout_init(g, &timeout, GK20A_WAIT_FOR_IDLE_MS, | 485 | nvgpu_timeout_init(g, &timeout, GK20A_WAIT_FOR_IDLE_MS, |
486 | NVGPU_TIMER_CPU_TIMER); | 486 | NVGPU_TIMER_CPU_TIMER); |
487 | 487 | ||
488 | if (g->can_railgate && !force_reset) { | 488 | if (nvgpu_is_enabled(g, NVGPU_CAN_RAILGATE) && !force_reset) { |
489 | /* | 489 | /* |
490 | * Case 1 : GPU railgate is supported | 490 | * Case 1 : GPU railgate is supported |
491 | * | 491 | * |
@@ -1047,7 +1047,7 @@ static int gk20a_pm_init(struct device *dev) | |||
1047 | * case, set autosuspend delay to negative which | 1047 | * case, set autosuspend delay to negative which |
1048 | * will suspend runtime pm | 1048 | * will suspend runtime pm |
1049 | */ | 1049 | */ |
1050 | if (g->railgate_delay && g->can_railgate) | 1050 | if (g->railgate_delay && nvgpu_is_enabled(g, NVGPU_CAN_RAILGATE)) |
1051 | pm_runtime_set_autosuspend_delay(dev, | 1051 | pm_runtime_set_autosuspend_delay(dev, |
1052 | g->railgate_delay); | 1052 | g->railgate_delay); |
1053 | else | 1053 | else |