Re: [PATCH v4 06/22] cpufreq: amd: introduce a new amd pstate driver to support future processors

From: Huang Rui
Date: Fri Nov 19 2021 - 06:16:41 EST


On Fri, Nov 19, 2021 at 06:46:58PM +0800, Peter Zijlstra wrote:
> On Fri, Nov 19, 2021 at 06:30:46PM +0800, Huang Rui wrote:
> > +static inline int pstate_enable(bool enable)
> > +{
> > + return wrmsrl_safe(MSR_AMD_CPPC_ENABLE, enable ? 1 : 0);
>
> Strictly speaking that ?: is superfluous, a _Bool when cast to scalar
> type will have exactly that value.

Right. Will update it to "wrmsrl_safe(MSR_AMD_CPPC_ENABLE, enable)".

Thanks,
Ray