<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/power, branch v2.6.35</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/kernel/power?h=v2.6.35</id>
<link rel='self' href='https://git.amat.us/linux/atom/kernel/power?h=v2.6.35'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2010-06-10T15:02:34Z</updated>
<entry>
<title>suspend: Move NVS save/restore code to generic suspend functionality</title>
<updated>2010-06-10T15:02:34Z</updated>
<author>
<name>Matthew Garrett</name>
<email>mjg@redhat.com</email>
</author>
<published>2010-05-28T20:32:14Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=dd4c4f17d722ffeb2515bf781400675a30fcead7'/>
<id>urn:sha1:dd4c4f17d722ffeb2515bf781400675a30fcead7</id>
<content type='text'>
Saving platform non-volatile state may be required for suspend to RAM as
well as hibernation. Move it to more generic code.

Signed-off-by: Matthew Garrett &lt;mjg@redhat.com&gt;
Acked-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
Tested-by: Maxim Levitsky &lt;maximlevitsky@gmail.com&gt;
Signed-off-by: Len Brown &lt;len.brown@intel.com&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: Fix block_io.c printk warning</title>
<updated>2010-05-10T21:08:18Z</updated>
<author>
<name>Randy Dunlap</name>
<email>randy.dunlap@oracle.com</email>
</author>
<published>2010-05-03T22:03:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=0fef8b1e83c4ab08cf1304dbebcfd749caf4f187'/>
<id>urn:sha1:0fef8b1e83c4ab08cf1304dbebcfd749caf4f187</id>
<content type='text'>
Fix printk format warning in block_io.c:

kernel/power/block_io.c:41: warning: format '%ld' expects type 'long int', but argument 2 has type 'sector_t'

Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: Group swap ops</title>
<updated>2010-05-10T21:08:18Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2010-05-01T21:54:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=6f612af57821c637b7eaca4374ac7b85f800d6e2'/>
<id>urn:sha1:6f612af57821c637b7eaca4374ac7b85f800d6e2</id>
<content type='text'>
Move all the swap processing into one function. It will make swap
calls from a non-swap code easier.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: Move the first_sector out of swsusp_write</title>
<updated>2010-05-10T21:08:18Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2010-05-01T21:53:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=51fb352b2c586b29c7bba38178b3b5389a7fb074'/>
<id>urn:sha1:51fb352b2c586b29c7bba38178b3b5389a7fb074</id>
<content type='text'>
The first sector knowledge is swap-only specific. Move it into the
swap handle. This will be needed for later non-swap specific code
moving into snapshot.c.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
Signed-off-by: "Rafael J. Wysocki" &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: Separate block_io</title>
<updated>2010-05-10T21:08:18Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2010-05-01T21:52:34Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8a0d613fa12e1b7f7f71ca88ed7dc2a3de95121a'/>
<id>urn:sha1:8a0d613fa12e1b7f7f71ca88ed7dc2a3de95121a</id>
<content type='text'>
Move block I/O operations to a separate file. It is because it will
be used later not only by the swap writer.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: Snapshot cleanup</title>
<updated>2010-05-10T21:08:17Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2010-05-01T21:52:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d3c1b24c50e8b2bbc840322caf26c7eada594d21'/>
<id>urn:sha1:d3c1b24c50e8b2bbc840322caf26c7eada594d21</id>
<content type='text'>
Remove support of reads with offset. This means snapshot_read/write_next
now does not accept count parameter. It allows to clean up the functions
and snapshot handle which no longer needs to care about offsets.

/dev/snapshot handler is converted to simple_{read_from,write_to}_buffer
which take care of offsets.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: user.c, fix SNAPSHOT_SET_SWAP_AREA handling</title>
<updated>2010-04-10T20:28:56Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2010-04-10T20:28:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d88d4050dcaf09e417aaa9a5024dd9449ef71b2e'/>
<id>urn:sha1:d88d4050dcaf09e417aaa9a5024dd9449ef71b2e</id>
<content type='text'>
When CONFIG_DEBUG_BLOCK_EXT_DEVT is set we decode the device
improperly by old_decode_dev and it results in an error while
hibernating with s2disk.

All users already pass the new device number, so switch to
new_decode_dev().

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Reported-and-tested-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
Signed-off-by: "Rafael J. Wysocki" &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>Merge branch 'master' into export-slabh</title>
<updated>2010-04-05T02:37:28Z</updated>
<author>
<name>Tejun Heo</name>
<email>tj@kernel.org</email>
</author>
<published>2010-04-05T02:37:28Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=336f5899d287f06d8329e208fc14ce50f7ec9698'/>
<id>urn:sha1:336f5899d287f06d8329e208fc14ce50f7ec9698</id>
<content type='text'>
</content>
</entry>
<entry>
<title>include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h</title>
<updated>2010-03-30T13:02:32Z</updated>
<author>
<name>Tejun Heo</name>
<email>tj@kernel.org</email>
</author>
<published>2010-03-24T08:04:11Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5a0e3ad6af8660be21ca98a971cd00f331318c05'/>
<id>urn:sha1:5a0e3ad6af8660be21ca98a971cd00f331318c05</id>
<content type='text'>
percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files.  percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -&gt; slab.h dependency is about to be removed.  Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability.  As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

  http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
  only the necessary includes are there.  ie. if only gfp is used,
  gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
  blocks and try to put the new include such that its order conforms
  to its surrounding.  It's put in the include block which contains
  core kernel includes, in the same order that the rest are ordered -
  alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
  doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
  because the file doesn't have fitting include block), it prints out
  an error message indicating which .h file needs to be added to the
  file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
   over 4000 files, deleting around 700 includes and adding ~480 gfp.h
   and ~3000 slab.h inclusions.  The script emitted errors for ~400
   files.

2. Each error was manually checked.  Some didn't need the inclusion,
   some needed manual addition while adding it to implementation .h or
   embedding .c file was more appropriate for others.  This step added
   inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
   from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
   e.g. lib/decompress_*.c used malloc/free() wrappers around slab
   APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
   editing them as sprinkling gfp.h and slab.h inclusions around .h
   files could easily lead to inclusion dependency hell.  Most gfp.h
   inclusion directives were ignored as stuff from gfp.h was usually
   wildly available and often used in preprocessor macros.  Each
   slab.h inclusion directive was examined and added manually as
   necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
   were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
   distributed build env didn't work with gcov compiles) and a few
   more options had to be turned off depending on archs to make things
   build (like ipr on powerpc/64 which failed due to missing writeq).

   * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
   * powerpc and powerpc64 SMP allmodconfig
   * sparc and sparc64 SMP allmodconfig
   * ia64 SMP allmodconfig
   * s390 SMP allmodconfig
   * alpha SMP allmodconfig
   * um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
   a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Guess-its-ok-by: Christoph Lameter &lt;cl@linux-foundation.org&gt;
Cc: Ingo Molnar &lt;mingo@redhat.com&gt;
Cc: Lee Schermerhorn &lt;Lee.Schermerhorn@hp.com&gt;
</content>
</entry>
<entry>
<title>Freezer: Fix buggy resume test for tasks frozen with cgroup freezer</title>
<updated>2010-03-26T22:51:44Z</updated>
<author>
<name>Matt Helsley</name>
<email>matthltc@us.ibm.com</email>
</author>
<published>2010-03-26T22:51:44Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5a7aadfe2fcb0f69e2acc1fbefe22a096e792fc9'/>
<id>urn:sha1:5a7aadfe2fcb0f69e2acc1fbefe22a096e792fc9</id>
<content type='text'>
When the cgroup freezer is used to freeze tasks we do not want to thaw
those tasks during resume. Currently we test the cgroup freezer
state of the resuming tasks to see if the cgroup is FROZEN.  If so
then we don't thaw the task. However, the FREEZING state also indicates
that the task should remain frozen.

This also avoids a problem pointed out by Oren Ladaan: the freezer state
transition from FREEZING to FROZEN is updated lazily when userspace reads
or writes the freezer.state file in the cgroup filesystem. This means that
resume will thaw tasks in cgroups which should be in the FROZEN state if
there is no read/write of the freezer.state file to trigger this
transition before suspend.

NOTE: Another "simple" solution would be to always update the cgroup
freezer state during resume. However it's a bad choice for several reasons:
Updating the cgroup freezer state is somewhat expensive because it requires
walking all the tasks in the cgroup and checking if they are each frozen.
Worse, this could easily make resume run in N^2 time where N is the number
of tasks in the cgroup. Finally, updating the freezer state from this code
path requires trickier locking because of the way locks must be ordered.

Instead of updating the freezer state we rely on the fact that lazy
updates only manage the transition from FREEZING to FROZEN. We know that
a cgroup with the FREEZING state may actually be FROZEN so test for that
state too. This makes sense in the resume path even for partially-frozen
cgroups -- those that really are FREEZING but not FROZEN.

Reported-by: Oren Ladaan &lt;orenl@cs.columbia.edu&gt;
Signed-off-by: Matt Helsley &lt;matthltc@us.ibm.com&gt;
Cc: stable@kernel.org
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
</content>
</entry>
</feed>
