linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Hilman <khilman@baylibre.com>
To: a0230503 <a-kaur@ti.com>, Dhruva Gole <d-gole@ti.com>
Cc: Markus Schneider-Pargmann <msp@baylibre.com>,
	Nishanth Menon <nm@ti.com>, Tero Kristo <kristo@kernel.org>,
	Santosh Shilimkar <ssantosh@kernel.org>,
	Vibhore Vardhan <vibhore@ti.com>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, Dave Gerlach <d-gerlach@ti.com>,
	Georgi Vlaev <g-vlaev@ti.com>
Subject: Re: [PATCH v9 3/4] firmware: ti_sci: Introduce Power Management Ops
Date: Tue, 13 Aug 2024 15:19:51 -0700	[thread overview]
Message-ID: <7hy150njzs.fsf@baylibre.com> (raw)
In-Reply-To: <5f6093e5-cf67-4516-b5b8-929987b05a2e@ti.com>

a0230503 <a-kaur@ti.com> writes:

> On 13/08/24 09:19, Dhruva Gole wrote:
>> On Aug 12, 2024 at 14:16:45 -0700, Kevin Hilman wrote:
>> [...]
>>>>> +/**
>>>>> + * struct ti_sci_msg_resp_lpm_wake_reason - Response for TI_SCI_MSG_LPM_WAKE_REASON.
>>>>> + *
>>>>> + * @hdr:		Generic header.
>>>>> + * @wake_source:	The wake up source that woke soc from LPM.
>>>>> + * @wake_timestamp:	Timestamp at which soc woke.
>>>>> + *
>>>>> + * Response to a generic message with message type TI_SCI_MSG_LPM_WAKE_REASON,
>>>>> + * used to query the wake up source from low power mode.
>>>>> + */
>>>>> +struct ti_sci_msg_resp_lpm_wake_reason {
>>>>> +	struct ti_sci_msg_hdr hdr;
>>>>> +	u32 wake_source;
>>>>> +	u64 wake_timestamp;
>>>>> +} __packed;
>>>>> +
>>>>
>>>> It looks like we forgot to update the parameters in this API.
>>>> See [1]:
>>>>
>>>> struct tisci_msg_lpm_wake_reason_req
>>>>
>>>> We're missing here the wake_pin, mode and 2 rsvd fields as well.
>>>>
>>>> [1] https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/pm/lpm.html#tisci-msg-lpm-wake-reason
>>>>
>>>
>>> The docs mention how to interpret the pin, but not the mode.  This
>>> driver should translate this mode number to some human-readable state
>>> for better debug messages.
>>>
>>> Kevin
>> 
>> Agreed, we would all benefit from a logic that prints the human-readable
>> state. The way to interpret the mode would be just as:
>> https://software-dl.ti.com/tisci/esd/latest/2_tisci_msgs/pm/lpm.html#supported-low-power-modes
>> 
>> So for eg. 0x0 = TISCI_MSG_VALUE_SLEEP_MODE_DEEP_SLEEP
>> 
>
> Missing the call to ti_sci_msg_cmd_lpm_wake_reason in resume path.
>

Oops, OK.  Will be added for v10.

Thanks,

Kevin


  reply	other threads:[~2024-08-13 22:20 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-09 13:53 [PATCH v9 0/4] firmware: ti_sci: Introduce system suspend support Markus Schneider-Pargmann
2024-08-09 13:53 ` [PATCH v9 1/4] firmware: ti_sci: Add support for querying the firmware caps Markus Schneider-Pargmann
2024-08-09 13:53 ` [PATCH v9 2/4] firmware: ti_sci: Add system suspend and resume call Markus Schneider-Pargmann
2024-08-09 13:53 ` [PATCH v9 3/4] firmware: ti_sci: Introduce Power Management Ops Markus Schneider-Pargmann
2024-08-12  5:47   ` Dhruva Gole
2024-08-12 21:16     ` Kevin Hilman
2024-08-13  3:49       ` Dhruva Gole
2024-08-13 11:21         ` a0230503
2024-08-13 22:19           ` Kevin Hilman [this message]
2024-08-09 13:53 ` [PATCH v9 4/4] firmware: ti_sci: add CPU latency constraint management Markus Schneider-Pargmann
2024-08-12 10:11   ` Dhruva Gole
2024-08-12 20:51     ` Kevin Hilman
2024-08-12  5:43 ` [PATCH v9 0/4] firmware: ti_sci: Introduce system suspend support Dhruva Gole

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7hy150njzs.fsf@baylibre.com \
    --to=khilman@baylibre.com \
    --cc=a-kaur@ti.com \
    --cc=d-gerlach@ti.com \
    --cc=d-gole@ti.com \
    --cc=g-vlaev@ti.com \
    --cc=kristo@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=msp@baylibre.com \
    --cc=nm@ti.com \
    --cc=ssantosh@kernel.org \
    --cc=vibhore@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).