Loading drivers/gpu/msm/adreno_a5xx.c +4 −2 Original line number Diff line number Diff line /* Copyright (c) 2014-2017, The Linux Foundation. All rights reserved. /* Copyright (c) 2014-2018, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -1399,8 +1399,10 @@ static uint32_t _write_voltage_table(struct adreno_device *adreno_dev, opp = dev_pm_opp_find_freq_exact(&device->pdev->dev, pwr->pwrlevels[i].gpu_freq, true); /* _opp_get returns uV, convert to mV */ if (!IS_ERR(opp)) if (!IS_ERR(opp)) { mvolt = dev_pm_opp_get_voltage(opp) / 1000; dev_pm_opp_put(opp); } kgsl_regwrite(device, addr++, mvolt); kgsl_regwrite(device, addr++, pwr->pwrlevels[i].gpu_freq / 1000000); Loading drivers/gpu/msm/kgsl_gmu.c +1 −0 Original line number Diff line number Diff line Loading @@ -661,6 +661,7 @@ static int rpmh_arc_votes_init(struct gmu_device *gmu, /* Values from OPP framework are offset by 1 */ vlvl_tbl[i] = dev_pm_opp_get_voltage(opp) - 1; dev_pm_opp_put(opp); } ret = setup_volt_dependency_tbl(votes, Loading drivers/gpu/msm/kgsl_pwrctrl.c +1 −3 Original line number Diff line number Diff line Loading @@ -2209,16 +2209,14 @@ static void kgsl_pwrctrl_disable_unused_opp(struct kgsl_device *device) return; while (1) { rcu_read_lock(); opp = dev_pm_opp_find_freq_ceil(dev, &freq); rcu_read_unlock(); if (IS_ERR(opp)) break; if (!_gpu_freq_supported(&device->pwrctrl, freq)) dev_pm_opp_disable(dev, freq); dev_pm_opp_put(opp); freq++; } } Loading drivers/gpu/msm/kgsl_pwrscale.c +4 −4 Original line number Diff line number Diff line Loading @@ -886,19 +886,19 @@ static int opp_notify(struct notifier_block *nb, if (type != OPP_EVENT_ENABLE && type != OPP_EVENT_DISABLE) return result; rcu_read_lock(); opp = dev_pm_opp_find_freq_floor(dev, &max_freq); dev_pm_opp_put(opp); if (IS_ERR(opp)) { rcu_read_unlock(); return PTR_ERR(opp); } opp = dev_pm_opp_find_freq_ceil(dev, &min_freq); dev_pm_opp_put(opp); if (IS_ERR(opp)) min_freq = pwr->pwrlevels[pwr->min_pwrlevel].gpu_freq; rcu_read_unlock(); mutex_lock(&device->mutex); max_level = pwr->thermal_pwrlevel; Loading Loading
drivers/gpu/msm/adreno_a5xx.c +4 −2 Original line number Diff line number Diff line /* Copyright (c) 2014-2017, The Linux Foundation. All rights reserved. /* Copyright (c) 2014-2018, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -1399,8 +1399,10 @@ static uint32_t _write_voltage_table(struct adreno_device *adreno_dev, opp = dev_pm_opp_find_freq_exact(&device->pdev->dev, pwr->pwrlevels[i].gpu_freq, true); /* _opp_get returns uV, convert to mV */ if (!IS_ERR(opp)) if (!IS_ERR(opp)) { mvolt = dev_pm_opp_get_voltage(opp) / 1000; dev_pm_opp_put(opp); } kgsl_regwrite(device, addr++, mvolt); kgsl_regwrite(device, addr++, pwr->pwrlevels[i].gpu_freq / 1000000); Loading
drivers/gpu/msm/kgsl_gmu.c +1 −0 Original line number Diff line number Diff line Loading @@ -661,6 +661,7 @@ static int rpmh_arc_votes_init(struct gmu_device *gmu, /* Values from OPP framework are offset by 1 */ vlvl_tbl[i] = dev_pm_opp_get_voltage(opp) - 1; dev_pm_opp_put(opp); } ret = setup_volt_dependency_tbl(votes, Loading
drivers/gpu/msm/kgsl_pwrctrl.c +1 −3 Original line number Diff line number Diff line Loading @@ -2209,16 +2209,14 @@ static void kgsl_pwrctrl_disable_unused_opp(struct kgsl_device *device) return; while (1) { rcu_read_lock(); opp = dev_pm_opp_find_freq_ceil(dev, &freq); rcu_read_unlock(); if (IS_ERR(opp)) break; if (!_gpu_freq_supported(&device->pwrctrl, freq)) dev_pm_opp_disable(dev, freq); dev_pm_opp_put(opp); freq++; } } Loading
drivers/gpu/msm/kgsl_pwrscale.c +4 −4 Original line number Diff line number Diff line Loading @@ -886,19 +886,19 @@ static int opp_notify(struct notifier_block *nb, if (type != OPP_EVENT_ENABLE && type != OPP_EVENT_DISABLE) return result; rcu_read_lock(); opp = dev_pm_opp_find_freq_floor(dev, &max_freq); dev_pm_opp_put(opp); if (IS_ERR(opp)) { rcu_read_unlock(); return PTR_ERR(opp); } opp = dev_pm_opp_find_freq_ceil(dev, &min_freq); dev_pm_opp_put(opp); if (IS_ERR(opp)) min_freq = pwr->pwrlevels[pwr->min_pwrlevel].gpu_freq; rcu_read_unlock(); mutex_lock(&device->mutex); max_level = pwr->thermal_pwrlevel; Loading