lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YiIkFZNGUihnoVPI@bogus>
Date:   Fri, 4 Mar 2022 14:37:09 +0000
From:   Sudeep Holla <sudeep.holla@....com>
To:     Edwin Chiu 邱垂峰 <edwin.chiu@...plus.com>
Cc:     Krzysztof Kozlowski <krzk@...nel.org>,
        Sudeep Holla <sudeep.holla@....com>,
        Edwin Chiu <edwinchiu0505tw@...il.com>,
        "robh+dt@...nel.org" <robh+dt@...nel.org>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "rafael@...nel.org" <rafael@...nel.org>,
        "daniel.lezcano@...aro.org" <daniel.lezcano@...aro.org>,
        "linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>
Subject: Re: [PATCH v5] cpuidle: sunplus: Create cpuidle driver for sunplus
 sp7021

On Fri, Mar 04, 2022 at 11:24:32AM +0000, Edwin Chiu 邱垂峰 wrote:
> 
> Thanks your advice.
> Look like key point still only WFI function when cpuidle.

Indeed.

> As I explain before, only enable generic ARM cpuidle driver is not work.

Why do you think it is a must. Most arch(including arm) has default
arch_cpu_idle handler that will be called if no cpuidle driver is active.
It does execute the default WFI, so you don't need a driver to achieve
the same.

> It need enable-method code to assign cpuidle_ops functions.

Correct, but you may not need that driver to be active at all. That is the
main point of these discussions. Sorry if that was not mentioned explicitly
earlier.

> "psci" is one of enable-method, but there have problem in my side due to smc
> or secure code unsupported. > So I create cpuidle-sunplus.c code with
> "sunplus,sc-smp" to let cpuidle code complete for our source code.
> With this structure, I can add more custom low power code in the future.
>

So you want to add custom low power mode support in future, so add the driver
when that is ready. The platform must do WFI even now without the driver
you are adding. Have you checked that ?

> What does it mean for "please document the chosen "sunplus,sc-smp" as bot
> cpu idle and hotplug methods" ?

I meant if you are adding any custom SMP+Idle mentods you need to add the
compatible to [1] or [2] based on what is more appropriate.

> Does it mean "edit yaml file"? (Previously, I submit yaml file also, but Rob
> say I don't need submit when I use compatible="arm,idle-state")

Yes that covers the description of idle states but not the entry method.
There are 2 separate things. You need both "arm,idle-state" and
"sunplus,sc-smp" or "psci" whichever you decide to implement on your
platform. If there is no implementation yet, it is strongly suggested
to go for "psci" unless you have reasons not to. Please add that info
when you submit the custom support, I will check on that again when
you post. But for now you don't need anything.

-- 
Regards,
Sudeep

[1] Documentation/devicetree/bindings/arm/cpu-enable-method/
[2] Documentation/devicetree/bindings/arm/cpus.yaml

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ