Skip to content

Commit a98d368

Browse files
Lifeng Zhengchanwoochoi
authored andcommitted
PM / devfreq: Remove redundant devfreq_get_freq_range() calling in devfreq_add_device()
The calling of devfreq_get_freq_range() in devfreq_add_device() is redundant because min_freq and max_freq are never used. Remove it. Signed-off-by: Lifeng Zheng <zhenglifeng1@huawei.com> Link: https://lore.kernel.org/lkml/20250421030020.3108405-4-zhenglifeng1@huawei.com/ Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
1 parent 5487f25 commit a98d368

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

drivers/devfreq/devfreq.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -804,7 +804,6 @@ struct devfreq *devfreq_add_device(struct device *dev,
804804
{
805805
struct devfreq *devfreq;
806806
struct devfreq_governor *governor;
807-
unsigned long min_freq, max_freq;
808807
int err = 0;
809808

810809
if (!dev || !profile || !governor_name) {
@@ -872,8 +871,6 @@ struct devfreq *devfreq_add_device(struct device *dev,
872871
goto err_dev;
873872
}
874873

875-
devfreq_get_freq_range(devfreq, &min_freq, &max_freq);
876-
877874
devfreq->suspend_freq = dev_pm_opp_get_suspend_opp_freq(dev);
878875
devfreq->opp_table = dev_pm_opp_get_opp_table(dev);
879876
if (IS_ERR(devfreq->opp_table))

0 commit comments

Comments
 (0)