<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/staging/android, branch v4.0</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.0</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.0'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2015-02-15T19:30:39Z</updated>
<entry>
<title>Merge tag 'staging-3.20-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging</title>
<updated>2015-02-15T19:30:39Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-02-15T19:30:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=46f7b635569731ff81a3b72d1bcd4415b293b637'/>
<id>urn:sha1:46f7b635569731ff81a3b72d1bcd4415b293b637</id>
<content type='text'>
Pull staging drivers patches from Greg KH:
 "Here's the big staging driver tree update for 3.20-rc1.

  Lots of little things in here, adding up to lots of overall cleanups.
  The IIO driver updates are also in here as they cross the staging tree
  boundry a lot.  I2O has moved into staging as well, as a plan to drop
  it from the tree eventually as that's a dead subsystem.

  All of this has been in linux-next with no reported issues for a
  while"

* tag 'staging-3.20-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (740 commits)
  staging: lustre: lustre: libcfs: define symbols as static
  staging: rtl8712: Do coding style cleanup
  staging: lustre: make obd_updatemax_lock static
  staging: rtl8188eu: core: switch with redundant cases
  staging: rtl8188eu: odm: conditional setting with no effect
  staging: rtl8188eu: odm: condition with no effect
  staging: ft1000: fix braces warning
  staging: sm7xxfb: fix remaining CamelCase
  staging: sm7xxfb: fix CamelCase
  staging: rtl8723au: multiple condition with no effect - if identical to else
  staging: sm7xxfb: make smtc_scr_info static
  staging/lustre/mdc: Initialize req in mdc_enqueue for !it case
  staging/lustre/clio: Do not allow group locks with gid 0
  staging/lustre/llite: don't add to page cache upon failure
  staging/lustre/llite: Add exception entry check after radix_tree
  staging/lustre/libcfs: protect kkuc_groups from write access
  staging/lustre/fld: refer to MDT0 for fld lookup in some cases
  staging/lustre/llite: Solve a race to access lli_has_smd in read case
  staging/lustre/ptlrpc: hold rq_lock when modify rq_flags
  staging/lustre/lnet: portal spreading rotor should be unsigned
  ...
</content>
</entry>
<entry>
<title>oom: add helpers for setting and clearing TIF_MEMDIE</title>
<updated>2015-02-12T01:06:03Z</updated>
<author>
<name>Michal Hocko</name>
<email>mhocko@suse.cz</email>
</author>
<published>2015-02-11T23:26:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=49550b605587924b3336386caae53200c68969d3'/>
<id>urn:sha1:49550b605587924b3336386caae53200c68969d3</id>
<content type='text'>
This patchset addresses a race which was described in the changelog for
5695be142e20 ("OOM, PM: OOM killed task shouldn't escape PM suspend"):

: PM freezer relies on having all tasks frozen by the time devices are
: getting frozen so that no task will touch them while they are getting
: frozen.  But OOM killer is allowed to kill an already frozen task in order
: to handle OOM situtation.  In order to protect from late wake ups OOM
: killer is disabled after all tasks are frozen.  This, however, still keeps
: a window open when a killed task didn't manage to die by the time
: freeze_processes finishes.

The original patch hasn't closed the race window completely because that
would require a more complex solution as it can be seen by this patchset.

The primary motivation was to close the race condition between OOM killer
and PM freezer _completely_.  As Tejun pointed out, even though the race
condition is unlikely the harder it would be to debug weird bugs deep in
the PM freezer when the debugging options are reduced considerably.  I can
only speculate what might happen when a task is still runnable
unexpectedly.

On a plus side and as a side effect the oom enable/disable has a better
(full barrier) semantic without polluting hot paths.

I have tested the series in KVM with 100M RAM:
- many small tasks (20M anon mmap) which are triggering OOM continually
- s2ram which resumes automatically is triggered in a loop
	echo processors &gt; /sys/power/pm_test
	while true
	do
		echo mem &gt; /sys/power/state
		sleep 1s
	done
- simple module which allocates and frees 20M in 8K chunks. If it sees
  freezing(current) then it tries another round of allocation before calling
  try_to_freeze
- debugging messages of PM stages and OOM killer enable/disable/fail added
  and unmark_oom_victim is delayed by 1s after it clears TIF_MEMDIE and before
  it wakes up waiters.
- rebased on top of the current mmotm which means some necessary updates
  in mm/oom_kill.c. mark_tsk_oom_victim is now called under task_lock but
  I think this should be OK because __thaw_task shouldn't interfere with any
  locking down wake_up_process. Oleg?

As expected there are no OOM killed tasks after oom is disabled and
allocations requested by the kernel thread are failing after all the tasks
are frozen and OOM disabled.  I wasn't able to catch a race where
oom_killer_disable would really have to wait but I kinda expected the race
is really unlikely.

[  242.609330] Killed process 2992 (mem_eater) total-vm:24412kB, anon-rss:2164kB, file-rss:4kB
[  243.628071] Unmarking 2992 OOM victim. oom_victims: 1
[  243.636072] (elapsed 2.837 seconds) done.
[  243.641985] Trying to disable OOM killer
[  243.643032] Waiting for concurent OOM victims
[  243.644342] OOM killer disabled
[  243.645447] Freezing remaining freezable tasks ... (elapsed 0.005 seconds) done.
[  243.652983] Suspending console(s) (use no_console_suspend to debug)
[  243.903299] kmem_eater: page allocation failure: order:1, mode:0x204010
[...]
[  243.992600] PM: suspend of devices complete after 336.667 msecs
[  243.993264] PM: late suspend of devices complete after 0.660 msecs
[  243.994713] PM: noirq suspend of devices complete after 1.446 msecs
[  243.994717] ACPI: Preparing to enter system sleep state S3
[  243.994795] PM: Saving platform NVS memory
[  243.994796] Disabling non-boot CPUs ...

The first 2 patches are simple cleanups for OOM.  They should go in
regardless the rest IMO.

Patches 3 and 4 are trivial printk -&gt; pr_info conversion and they should
go in ditto.

The main patch is the last one and I would appreciate acks from Tejun and
Rafael.  I think the OOM part should be OK (except for __thaw_task vs.
task_lock where a look from Oleg would appreciated) but I am not so sure I
haven't screwed anything in the freezer code.  I have found several
surprises there.

This patch (of 5):

This patch is just a preparatory and it doesn't introduce any functional
change.

Note:
I am utterly unhappy about lowmemory killer abusing TIF_MEMDIE just to
wait for the oom victim and to prevent from new killing. This is
just a side effect of the flag. The primary meaning is to give the oom
victim access to the memory reserves and that shouldn't be necessary
here.

Signed-off-by: Michal Hocko &lt;mhocko@suse.cz&gt;
Cc: Tejun Heo &lt;tj@kernel.org&gt;
Cc: David Rientjes &lt;rientjes@google.com&gt;
Cc: Johannes Weiner &lt;hannes@cmpxchg.org&gt;
Cc: Oleg Nesterov &lt;oleg@redhat.com&gt;
Cc: Cong Wang &lt;xiyou.wangcong@gmail.com&gt;
Cc: "Rafael J. Wysocki" &lt;rjw@rjwysocki.net&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>staging: Remove logger and alarm-dev from android Makefile</title>
<updated>2015-01-28T19:32:39Z</updated>
<author>
<name>John Stultz</name>
<email>john.stultz@linaro.org</email>
</author>
<published>2015-01-27T15:22:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=71e365ed0ca893cae8d72cbd4b476a9589003098'/>
<id>urn:sha1:71e365ed0ca893cae8d72cbd4b476a9589003098</id>
<content type='text'>
My previous patches deleting logger and alarm-dev from staging
missed the android Makefile.

This patch cleans up the Makefile to remove the now non-existent
files.

Cc: Rom Lemarchand &lt;romlem@google.com&gt;,
Cc: Mark Salyzyn &lt;salyzyn@google.com&gt;,
Cc: Kees Cook &lt;keescook@chromium.org&gt;,
Cc: Android Kernel Team &lt;kernel-team@android.com&gt;,
Cc: Valentin Rothberg &lt;valentinrothberg@gmail.com&gt;,
Cc: Greg Hackmann &lt;ghackmann@google.com&gt;,
Cc: Elliott Hughes &lt;enh@google.com&gt;,
Cc: Todd Poynor &lt;toddpoynor@google.com&gt;,
Reported-by: Paul Bolle &lt;pebolle@tiscali.nl&gt;
Signed-off-by: John Stultz &lt;john.stultz@linaro.org&gt;
Acked-by: Kees Cook &lt;keescook@chromium.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: Remove the Android logger driver</title>
<updated>2015-01-28T19:31:26Z</updated>
<author>
<name>John Stultz</name>
<email>john.stultz@linaro.org</email>
</author>
<published>2015-01-26T20:07:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a0a23bbce7818c90c3d3370af966fefce07a8c9b'/>
<id>urn:sha1:a0a23bbce7818c90c3d3370af966fefce07a8c9b</id>
<content type='text'>
With the relase of Lollipop, Android no longer
requires the logger driver.

There are three patches which the android dev's
still need before they drop logger on all their
devices:

[PATCH v4 1/5] pstores: use scnprintf
[PATCH v2 2/5] pstore: remove superfluous memory size check
[PATCH 3/5] pstore: handle zero-sized prz in series
[PATCH v4 4/5] pstore: add pmsg
[PATCH 5/5] pstore: selinux: add security in-core xattr support for pstore and debugfs

But these seem to have been acked and are hopefully
queued for upstream.

So this patch removes the logger driver from staging.

Cc: Rom Lemarchand &lt;romlem@google.com&gt;,
Cc: Mark Salyzyn &lt;salyzyn@google.com&gt;
Cc: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Android Kernel Team &lt;kernel-team@android.com&gt;
Signed-off-by: John Stultz &lt;john.stultz@linaro.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: Remove the Android alarm-dev driver</title>
<updated>2015-01-25T12:10:10Z</updated>
<author>
<name>John Stultz</name>
<email>john.stultz@linaro.org</email>
</author>
<published>2015-01-20T21:42:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=5da41e925656649fd970f0c205eee5fda887dc24'/>
<id>urn:sha1:5da41e925656649fd970f0c205eee5fda887dc24</id>
<content type='text'>
The functionality provided by the Android alarm-dev driver
should now be present in the timerfd interface (thanks to
Greg Hackmann and Todd Poynor).

As of Lollipop, AOSP can make use of the timerfd if
alarm-dev is not present (though a fixup for setting the
rtc time if rtc0 isn't the backing for _ALARM clockids has
been applied post-Lollipop).

Thus, we should be able to remove alarm-dev from staging.

Cc: Greg Hackmann &lt;ghackmann@google.com&gt;
Cc: Elliott Hughes &lt;enh@google.com&gt;
Cc: Todd Poynor &lt;toddpoynor@google.com&gt;
Cc: Android Kernel Team &lt;kernel-team@android.com&gt;
Signed-off-by: John Stultz &lt;john.stultz@linaro.org&gt;
Acked-by: Mark Salyzyn &lt;salyzyn@google.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: android: remove space after casts</title>
<updated>2015-01-18T00:20:20Z</updated>
<author>
<name>Fabian Holler</name>
<email>fabian.holler@profitbricks.com</email>
</author>
<published>2015-01-07T09:39:54Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=1703ca9039e3a8362f5d8c4dbb9a68318e734da6'/>
<id>urn:sha1:1703ca9039e3a8362f5d8c4dbb9a68318e734da6</id>
<content type='text'>
This patch fixes the following checkpatch.pl warnings:
	ashmem.c:753: CHECK:SPACING: No space is necessary after a cast
	ashmem.c:756: CHECK:SPACING: No space is necessary after a cast
	ashmem.c:777: CHECK:SPACING: No space is necessary after a cast

Signed-off-by: Fabian Holler &lt;fabian.holler@profitbricks.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: android: remove blank lines after open braces</title>
<updated>2015-01-18T00:20:20Z</updated>
<author>
<name>Fabian Holler</name>
<email>fabian.holler@profitbricks.com</email>
</author>
<published>2015-01-07T09:39:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e46945ceacc286f7526382bfe8f9e5292a4a2ee1'/>
<id>urn:sha1:e46945ceacc286f7526382bfe8f9e5292a4a2ee1</id>
<content type='text'>
This patch fixes the following checkpatch.pl warnings:
	ashmem.c:552: CHECK:BRACES: Blank lines aren't necessary after an open brace '{'
	ashmem.c:801: CHECK:BRACES: Blank lines aren't necessary after an open brace

Signed-off-by: Fabian Holler &lt;fabian.holler@profitbricks.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: android: fix indentation to match open parenthesis</title>
<updated>2015-01-18T00:19:21Z</updated>
<author>
<name>Fabian Holler</name>
<email>fabian.holler@profitbricks.com</email>
</author>
<published>2015-01-07T09:39:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=002397c4c72d5082a10a4a81946966b5bb3a200f'/>
<id>urn:sha1:002397c4c72d5082a10a4a81946966b5bb3a200f</id>
<content type='text'>
This patches fixes the following checkpatch.pl warning:
	ashmem.c:450: CHECK:PARENTHESIS_ALIGNMENT: Alignment should match open parenthesis

Signed-off-by: Fabian Holler &lt;fabian.holler@profitbricks.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>staging: android: Correct coding style in logger.c</title>
<updated>2015-01-18T00:18:53Z</updated>
<author>
<name>Guillaume Vercoutere</name>
<email>gvercoutere@gmail.com</email>
</author>
<published>2015-01-05T14:24:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ddc00b98254e51f33668a08e38f85db9636418c4'/>
<id>urn:sha1:ddc00b98254e51f33668a08e38f85db9636418c4</id>
<content type='text'>
Correct intent and missing space

Signed-off-by: Guillaume Vercoutere &lt;gvercoutere@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>Staging: android: fix line length coding style issue in sync_debug.c</title>
<updated>2015-01-18T00:17:11Z</updated>
<author>
<name>Steve Pennington</name>
<email>sgpenn@gmail.com</email>
</author>
<published>2014-12-24T15:33:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0541cdf585a8f0049d81abc88a6d735ed2a010d8'/>
<id>urn:sha1:0541cdf585a8f0049d81abc88a6d735ed2a010d8</id>
<content type='text'>
This is a patch to sync_debug.c that fixes an over 80 character warning found by the checkpatch.pl tool
Signed-off-by: Steve Pennington &lt;sgpenn@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
</feed>
