On Mon, Mar 08, 2021 at 10:32:17AM -0800, Sowjanya Komatineni wrote:No. Tegra194 CPU idle driver works with MCE firmware running in background so cpuidle kernel driver also talks to MCE firmware directly on state information.
On 3/7/21 8:37 PM, Sudeep Holla wrote:Sure, but I assume only TF-A talks to MCE and not any OSPM/Linux kernel.
On Wed, Mar 03, 2021 at 10:08:10PM -0800, Sowjanya Komatineni wrote:MCE firmware is in charge of state transition for Tegra194 carmel CPUs.
This patch adds cpu-idle-states and corresponding state nodes toI see that this platform has PSCI support. Can you care to explain why
Tegra194 CPU in dt-binding document
you need additional DT bindings and driver for PSCI based CPU suspend.
Until the reasons are convincing, consider NACK from my side for this
driver and DT bindings. You should be really using those bindings and
the driver may be with minor changes there.
For run-time state transitions, need to provide state request along with itsSounds similar to x86 mwait, perhaps we need to extend PSCI if we need
residency time to MCE firmware which is running in the background.
to make this firmware PSCI compliant or just say it is not and implement
completely independent implementation. I am not saying that is acceptable
ATM but I prefer not to mix some implementation to make it look like
PSCI compliant.
State min residency is updated into power_state value along with state idSounds like a hack/workaround. I would prefer to standardise that. IIUC
that is passed to psci_cpu_suspend_enter
the power_state is more static and derived from DT. I don't like to
overload that TBH. Need to check with authors of that binding.
Also states cross-over idle times need to be provided to MCE firmware.New requirements if this has to be PSCI compliant.
MCE firmware decides on state transition based on these inputs along withI am worried if different vendors will come up with different custom
its background work load.
So, Tegra specific CPU idle driver is required mainly to provide cross-over
thresholds from DT and run time idle state information to MCE firmware
through Tegra MCE communication APIs.
solution for this. We need to either standardise this is Linux/DT or
in PSCI.
Allowing cross-over threshold through DT allows users to vary idle timeSounds like policy and not platform specific to be in DT, but I will leave
thresholds for state transitions based on different use-cases.
that to DT maintainers.
--
Regards,
Sudeep