<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/base/power/wakeup.c, branch linux-4.11.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.11.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.11.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2017-07-21T05:00:15Z</updated>
<entry>
<title>PM / wakeirq: Convert to SRCU</title>
<updated>2017-07-21T05:00:15Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2017-06-25T17:31:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4ad8c2aa7bc94e43c4692f56de86362c85ff8002'/>
<id>urn:sha1:4ad8c2aa7bc94e43c4692f56de86362c85ff8002</id>
<content type='text'>
commit ea0212f40c6bc0594c8eff79266759e3ecd4bacc upstream.

The wakeirq infrastructure uses RCU to protect the list of wakeirqs. That
breaks the irq bus locking infrastructure, which is allows sleeping
functions to be called so interrupt controllers behind slow busses,
e.g. i2c, can be handled.

The wakeirq functions hold rcu_read_lock and call into irq functions, which
in case of interrupts using the irq bus locking will trigger a
might_sleep() splat.

Convert the wakeirq infrastructure to Sleepable RCU and unbreak it.

Fixes: 4990d4fe327b (PM / Wakeirq: Add automated device wake IRQ handling)
Reported-by: Brian Norris &lt;briannorris@chromium.org&gt;
Suggested-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Paul E. McKenney &lt;paulmck@linux.vnet.ibm.com&gt;
Tested-by: Tony Lindgren &lt;tony@atomide.com&gt;
Tested-by: Brian Norris &lt;briannorris@chromium.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>sched/headers: Prepare to move signal wakeup &amp; sigpending methods from &lt;linux/sched.h&gt; into &lt;linux/sched/signal.h&gt;</title>
<updated>2017-03-02T07:42:32Z</updated>
<author>
<name>Ingo Molnar</name>
</author>
<published>2017-02-02T18:15:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=174cd4b1e5fbd0d74c68cf3a74f5bd4923485512'/>
<id>urn:sha1:174cd4b1e5fbd0d74c68cf3a74f5bd4923485512</id>
<content type='text'>
Fix up affected files that include this signal functionality via sched.h.

Acked-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Mike Galbraith &lt;efault@gmx.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
<entry>
<title>ktime: Cleanup ktime_set() usage</title>
<updated>2016-12-25T16:21:22Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2016-12-25T11:30:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8b0e195314fabd58a331c4f7b6db75a1565535d7'/>
<id>urn:sha1:8b0e195314fabd58a331c4f7b6db75a1565535d7</id>
<content type='text'>
ktime_set(S,N) was required for the timespec storage type and is still
useful for situations where a Seconds and Nanoseconds part of a time value
needs to be converted. For anything where the Seconds argument is 0, this
is pointless and can be replaced with a simple assignment.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
</content>
</entry>
<entry>
<title>ktime: Get rid of the union</title>
<updated>2016-12-25T16:21:22Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2016-12-25T10:38:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2456e855354415bfaeb7badaa14e11b3e02c8466'/>
<id>urn:sha1:2456e855354415bfaeb7badaa14e11b3e02c8466</id>
<content type='text'>
ktime is a union because the initial implementation stored the time in
scalar nanoseconds on 64 bit machine and in a endianess optimized timespec
variant for 32bit machines. The Y2038 cleanup removed the timespec variant
and switched everything to scalar nanoseconds. The union remained, but
become completely pointless.

Get rid of the union and just keep ktime_t as simple typedef of type s64.

The conversion was done with coccinelle and some manual mopping up.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
</content>
</entry>
<entry>
<title>PM / sleep: Print active wakeup sources when blocking on wakeup_count reads</title>
<updated>2016-12-08T00:26:23Z</updated>
<author>
<name>xing wei</name>
</author>
<published>2016-12-07T11:31:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9320f95c0b8f1d074f570385e6855d4554f693e4'/>
<id>urn:sha1:9320f95c0b8f1d074f570385e6855d4554f693e4</id>
<content type='text'>
If there are any wakeup events being processed, read operation
on /sys/power/wakeup_count will be blocked, so print the names
of all active wakeup sources to help to find out who is preventing
system suspend from triggering.

While at it change pr_info() in pm_print_active_wakeup_sources()
to pr_debug() to avoid excessive log noise.

Signed-off-by: xing wei &lt;xing.wei@intel.com&gt;
[ rjw: Subject &amp; changelog ]
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>PM-wakeup: Delete unnecessary checks before three function calls</title>
<updated>2016-07-28T21:51:04Z</updated>
<author>
<name>Markus Elfring</name>
</author>
<published>2016-07-23T15:04:00Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4f48ec8a1c070f00c3d675b664e8b3879e5286e5'/>
<id>urn:sha1:4f48ec8a1c070f00c3d675b664e8b3879e5286e5</id>
<content type='text'>
The following functions test whether their argument is NULL
and then return immediately.
 * dev_pm_arm_wake_irq
 * dev_pm_disarm_wake_irq
 * wakeup_source_unregister

Thus the test around the calls is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
[ rjw: Minor whitespace adjustments ]
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>PM / wakeirq: fix wakeirq setting after wakup re-configuration from sysfs</title>
<updated>2016-04-07T20:23:47Z</updated>
<author>
<name>Strashko, Grygorii</name>
</author>
<published>2016-04-06T11:45:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=16669befb0772eac6a76057b7010ba5b419c0e78'/>
<id>urn:sha1:16669befb0772eac6a76057b7010ba5b419c0e78</id>
<content type='text'>
Now wakeirq stops working for device if wakeup option for
this device will be reconfigured through sysfs, like:

echo disabled &gt; /sys/devices/platform/extcon_usb1/power/wakeup
echo enabled &gt; /sys/devices/platform/extcon_usb1/power/wakeup

Once above set of commands is executed the device's wakeup_source
opject will be recreated and dev-&gt;power.wakeup-&gt;wakeirq field will
contain NULL. As result, device_wakeup_arm_wake_irqs() will not arm
wakeirq for the affected device.

Hece, lets try to fix it in the following way:
  check for dev-&gt;wakeirq field when device_wakeup_attach() is called
  and if !NULL re-attach wakeirq to the device

Signed-off-by: Grygorii Strashko &lt;grygorii.strashko@ti.com&gt;
Acked-by: Tony Lindgren &lt;tony@atomide.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>PM / wakeup: wakeup_source_create: use kstrdup_const</title>
<updated>2015-09-25T00:30:50Z</updated>
<author>
<name>Rasmus Villemoes</name>
</author>
<published>2015-09-09T21:42:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7236214c88454d96de7633e07a8314644d529f26'/>
<id>urn:sha1:7236214c88454d96de7633e07a8314644d529f26</id>
<content type='text'>
Using kstrdup_const allows us to save a little runtime memory (and a
string copy) in the common case where name is a string literal.

Signed-off-by: Rasmus Villemoes &lt;linux@rasmusvillemoes.dk&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>PM / sleep: Report interrupt that caused system wakeup</title>
<updated>2015-09-16T12:20:41Z</updated>
<author>
<name>Alexandra Yates</name>
</author>
<published>2015-09-15T17:32:46Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a6f5f0dd4e21191ce35030dd4d6421e1cca10ee4'/>
<id>urn:sha1:a6f5f0dd4e21191ce35030dd4d6421e1cca10ee4</id>
<content type='text'>
Add a sysfs attribute, /sys/power/pm_wakeup_irq, reporting the IRQ
number of the first wakeup interrupt (that is, the first interrupt
from an IRQ line armed for system wakeup) seen by the kernel during
the most recent system suspend/resume cycle.

This feature will be useful for system wakeup diagnostics of
spurious wakeup interrupts.

Signed-off-by: Alexandra Yates &lt;alexandra.yates@linux.intel.com&gt;
[ rjw: Fixed up pm_wakeup_irq definition ]
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'pm-wakeirq'</title>
<updated>2015-07-07T20:47:43Z</updated>
<author>
<name>Rafael J. Wysocki</name>
</author>
<published>2015-07-07T20:47:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3fc7aeeb08bfde59877e7f9a4eea3c5ebcae72be'/>
<id>urn:sha1:3fc7aeeb08bfde59877e7f9a4eea3c5ebcae72be</id>
<content type='text'>
* pm-wakeirq:
  PM / wakeirq: Avoid setting power.wakeirq too hastily
</content>
</entry>
</feed>
