From: Keerthy <a0393675@ti.com>
To: Eduardo Valentin <edubezval@gmail.com>, Keerthy <j-keerthy@ti.com>
Cc: nm@ti.com, rui.zhang@intel.com, linux-pm@vger.kernel.org,
linux-omap@vger.kernel.org
Subject: Re: [PATCH] thermal: omap-thermal: Add notify function to thermal_zone_device_ops
Date: Tue, 10 May 2016 17:32:52 +0530 [thread overview]
Message-ID: <5731CDEC.5020904@ti.com> (raw)
In-Reply-To: <20160308204812.GA6800@localhost.localdomain>
On Wednesday 09 March 2016 02:18 AM, Eduardo Valentin wrote:
> On Tue, Feb 16, 2016 at 10:35:45AM +0530, Keerthy wrote:
>> notify function is used to notify when some temperature thresholds
>> are crossed. In case we get notified for a critical trip point then
>> schedule an emergency shutdown function to backup orderly_poweroff
>> failures.
>>
>> orderly_poweroff is triggered when a graceful shutdown
>> of system is desired. This may be used in many critical states of the
>> kernel such as when subsystems detects conditions such as critical
>> temperature conditions. However, in certain conditions in system
>> boot up sequences like those in the middle of driver probes being
>> initiated, userspace will be unable to power off the system in a clean
>> manner and leaves the system in a critical state. In cases like these,
>> the /sbin/poweroff will return success (having forked off to attempt
>> powering off the system. However, the system overall will fail to
>> completely poweroff (since other modules will be probed) and the system
>> is still functional with no userspace (since that would have shut itself
>> off).
>>
>> However, there is no clean way of detecting such failure of userspace
>> powering off the system. In such scenarios, it is necessary for a backup
>> workqueue to be able to force a shutdown of the system when orderly
>> shutdown is not successful after a configurable time period.
>>
>> Signed-off-by: Keerthy <j-keerthy@ti.com>
>> ---
>>
>> The previous discussion:
>>
>> https://lkml.org/lkml/2016/1/28/989
>>
>> Making use of the notify ops to schedule a backup thermal shutdown.
>
> Yeah, this was a bit of a stretching. If we cannot fix orderly power
> off, I would say, better fixing it for all thermal drivers (previous
> version of this). This patch:
> 1. Abuse a notify function to be used as a power off functions
> 2. Fix an issue only for a single driver.
>
> I will check your initial version.
Eduardo,
Any updates on this?
Regards,
Keerthy
>
prev parent reply other threads:[~2016-05-10 12:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-16 5:05 [PATCH] thermal: omap-thermal: Add notify function to thermal_zone_device_ops Keerthy
2016-03-07 7:31 ` Keerthy
2016-03-07 7:33 ` Keerthy
2016-03-08 20:48 ` Eduardo Valentin
2016-05-10 12:02 ` Keerthy [this message]
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=5731CDEC.5020904@ti.com \
--to=a0393675@ti.com \
--cc=edubezval@gmail.com \
--cc=j-keerthy@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=nm@ti.com \
--cc=rui.zhang@intel.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).