Re: [PATCH 2/2] cpufreq: qcom-fw: Add support for QCOM cpufreq FW driver

From: Viresh Kumar
Date: Tue Jun 19 2018 - 06:34:10 EST


On 19-06-18, 15:55, Taniya Das wrote:
> Yes, Viresh, earlier code was updating the table frequency as I was marking
> the table frequency INVALID.
> if (core_count != c->max_cores)
> c->table[i].frequency = CPUFREQ_ENTRY_INVALID;
>
> And thus I had to update the table frequency.
>
> But now I have used the cur_freq instead and the table frequency is not
> touched.
> if (core_count != c->max_cores)
> cur_freq = CPUFREQ_ENTRY_INVALID;

Unless I am reading your versions incorrectly, they behave differently.

Until V2, if core_count wasn't equal to max_cores then the frequency was getting
marked as INVALID straight away in the table itself. Now if the next freq is
also same then you abort and overwrite the previous one as valid, but otherwise
it remains INVALID for ever. And this last thing doesn't happen anymore.

So if in your table there are few frequency entries which aren't repeating, but
the core_count != max_cores for some of them, they remain valid in the newer
versions.

--
viresh