[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <0f420eec-d171-4d23-8b69-93c38f8938f1@kylinos.cn>
Date: Thu, 21 Aug 2025 18:20:48 +0800
From: Zihuan Zhang <zhangzihuan@...inos.cn>
To: Viresh Kumar <viresh.kumar@...aro.org>
Cc: "rafael J . wysocki" <rafael@...nel.org>,
zhenglifeng <zhenglifeng1@...wei.com>, linux-pm@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 2/2] cpufreq: simplify setpolicy/target check in driver
verification
在 2025/8/21 17:56, Viresh Kumar 写道:
> On 21-08-25, 17:45, Zihuan Zhang wrote:
>>> I would rather do:
>>>
>>> (!!driver_data->setpolicy == (driver_data->target_index || driver_data->target))
>> The current version of the code is much better and safer.
> You can actually do this.. This first converts
> `driver_data->setpolicy` to bool and then compares both of them, and
> both can't be true or false.
Thanks. I will.
Powered by blists - more mailing lists