diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a_scale.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a_scale.c b/drivers/gpu/nvgpu/gk20a/gk20a_scale.c index 6f4f7dc9..3e6fead6 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a_scale.c +++ b/drivers/gpu/nvgpu/gk20a/gk20a_scale.c | |||
@@ -160,19 +160,13 @@ static int gk20a_scale_target(struct device *dev, unsigned long *freq, | |||
160 | * To get cap (max) freq, we select MIN of max frequencies | 160 | * To get cap (max) freq, we select MIN of max frequencies |
161 | * | 161 | * |
162 | * In case we have conflict (min_freq > max_freq) after above | 162 | * In case we have conflict (min_freq > max_freq) after above |
163 | * steps, we ensure that devfreq->min_freq wins over | 163 | * steps, we ensure that max_freq wins over min_freq |
164 | * qos_max_freq | ||
165 | */ | 164 | */ |
166 | min_freq = max_t(u32, devfreq->min_freq, profile->qos_min_freq); | 165 | min_freq = max_t(u32, devfreq->min_freq, profile->qos_min_freq); |
167 | max_freq = min_t(u32, devfreq->max_freq, profile->qos_max_freq); | 166 | max_freq = min_t(u32, devfreq->max_freq, profile->qos_max_freq); |
168 | 167 | ||
169 | if (min_freq > max_freq) { | 168 | if (min_freq > max_freq) |
170 | if (min_freq == devfreq->min_freq && | ||
171 | max_freq != devfreq->max_freq) { | ||
172 | max_freq = min_t(u32, min_freq, devfreq->max_freq); | ||
173 | } | ||
174 | min_freq = max_freq; | 169 | min_freq = max_freq; |
175 | } | ||
176 | 170 | ||
177 | /* Clip requested frequency */ | 171 | /* Clip requested frequency */ |
178 | if (local_freq < min_freq) | 172 | if (local_freq < min_freq) |