Thread (10 messages) 10 messages, 5 authors, 2017-08-28
STALE3236d

[PATCH] nvme: Honor RTD3 Entry Latency for shutdowns

From: Scott Bauer <hidden>
Date: 2017-08-17 17:42:25

Possibly related (same subject, not in this thread)

On Thu, Aug 17, 2017@01:06:32PM -0400, Martin K. Petersen wrote:
Keith,
quoted
quoted
quoted
My only concern is if this value extends past the DPM_WATCHDOG
timeout value. If it does we're going to end up panic()ing the
kernel during suspends. If others agree I think we should set it to
the minimum value of DPM_WATCHDOG_TIMEOUT and shutdown_timeout.
I don't have a problem with that. Keith?
Sounds good to me as well.
Hrm, this gets pretty messy.

DPM_WATCHDOG_TIMEOUT is buried deep in the config options (hidden behind
PM_DEBUG and EXPERT). And as a result doesn't appear to be enabled in
most common kernel configs. It also isn't exported from the PM subsystem
in a generic way.

In addition, I'm not sure what we'd do in case a device demands a 10
second shutdown time but the user has the kernel configured with a 2
second DPM watchdog. Then what? The device is still going to take 10
seconds to complete the shutdown request.
ugh, I thought it would be as easy as if (IS_ENABLED(CONFIG_DPM_WATCHDOG))
but I guess since that's a runtime check GCC cant remove the scope below,
since it's not known at compilation time.

We wont be able to fix this without some gross ifdefs/ifndefs.

I guess we can do a dev_warn() or something if the shutdown time is >
than some threshold instead? That way if people are getting sporatic
panics on suspends we can see that warning and fix it from there?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help