<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/kernel/futex.c, branch v3.5</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=v3.5</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.5'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2012-03-29T09:37:17Z</updated>
<entry>
<title>futex: Mark get_robust_list as deprecated</title>
<updated>2012-03-29T09:37:17Z</updated>
<author>
<name>Kees Cook</name>
<email>keescook@chromium.org</email>
</author>
<published>2012-03-23T19:08:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ec0c4274e33c0373e476b73e01995c53128f1257'/>
<id>urn:sha1:ec0c4274e33c0373e476b73e01995c53128f1257</id>
<content type='text'>
Notify get_robust_list users that the syscall is going away.

Suggested-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Randy Dunlap &lt;rdunlap@xenotime.net&gt;
Cc: Darren Hart &lt;dvhart@linux.intel.com&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Jiri Kosina &lt;jkosina@suse.cz&gt;
Cc: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
Cc: David Howells &lt;dhowells@redhat.com&gt;
Cc: Serge E. Hallyn &lt;serge.hallyn@canonical.com&gt;
Cc: kernel-hardening@lists.openwall.com
Cc: spender@grsecurity.net
Link: http://lkml.kernel.org/r/20120323190855.GA27213@www.outflux.net
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>futex: Do not leak robust list to unprivileged process</title>
<updated>2012-03-29T09:37:17Z</updated>
<author>
<name>Kees Cook</name>
<email>keescook@chromium.org</email>
</author>
<published>2012-03-19T23:12:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bdbb776f882f5ad431aa1e694c69c1c3d6a4a5b8'/>
<id>urn:sha1:bdbb776f882f5ad431aa1e694c69c1c3d6a4a5b8</id>
<content type='text'>
It was possible to extract the robust list head address from a setuid
process if it had used set_robust_list(), allowing an ASLR info leak. This
changes the permission checks to be the same as those used for similar
info that comes out of /proc.

Running a setuid program that uses robust futexes would have had:
  cred-&gt;euid != pcred-&gt;euid
  cred-&gt;euid == pcred-&gt;uid
so the old permissions check would allow it. I'm not aware of any setuid
programs that use robust futexes, so this is just a preventative measure.

(This patch is based on changes from grsecurity.)

Signed-off-by: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Darren Hart &lt;dvhart@linux.intel.com&gt;
Cc: Peter Zijlstra &lt;a.p.zijlstra@chello.nl&gt;
Cc: Jiri Kosina &lt;jkosina@suse.cz&gt;
Cc: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
Cc: David Howells &lt;dhowells@redhat.com&gt;
Cc: Serge E. Hallyn &lt;serge.hallyn@canonical.com&gt;
Cc: kernel-hardening@lists.openwall.com
Cc: spender@grsecurity.net
Link: http://lkml.kernel.org/r/20120319231253.GA20893@www.outflux.net
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>Merge branch 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip</title>
<updated>2012-03-20T00:11:15Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2012-03-20T00:11:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=5ed59af85077d28875a3a137b21933aaf1b4cd50'/>
<id>urn:sha1:5ed59af85077d28875a3a137b21933aaf1b4cd50</id>
<content type='text'>
Pull core/locking changes for v3.4 from Ingo Molnar

* 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  futex: Simplify return logic
  futex: Cover all PI opcodes with cmpxchg enabled check
</content>
</entry>
<entry>
<title>futex: Simplify return logic</title>
<updated>2012-02-15T11:19:13Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2012-02-15T11:17:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=81b40539e748b108d143a5e38526ab00a6a784b6'/>
<id>urn:sha1:81b40539e748b108d143a5e38526ab00a6a784b6</id>
<content type='text'>
No need to assign ret in each case and break. Simply return the result
of the handler function directly.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Darren Hart &lt;dvhart@linux.intel.com&gt;

</content>
</entry>
<entry>
<title>futex: Cover all PI opcodes with cmpxchg enabled check</title>
<updated>2012-02-15T11:19:13Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2012-02-15T11:08:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=59263b513c11398cd66a52d4c5b2b118ce1e0359'/>
<id>urn:sha1:59263b513c11398cd66a52d4c5b2b118ce1e0359</id>
<content type='text'>
Some of the newer futex PI opcodes do not check the cmpxchg enabled
variable and call unconditionally into the handling functions. Cover
all PI opcodes in a separate check.

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: stable@vger.kernel.org
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Darren Hart &lt;dvhart@linux.intel.com&gt;
</content>
</entry>
<entry>
<title>futex: Fix uninterruptible loop due to gate_area</title>
<updated>2011-12-31T19:48:28Z</updated>
<author>
<name>Hugh Dickins</name>
<email>hughd@google.com</email>
</author>
<published>2011-12-31T19:44:01Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e6780f7243eddb133cc20ec37fa69317c218b709'/>
<id>urn:sha1:e6780f7243eddb133cc20ec37fa69317c218b709</id>
<content type='text'>
It was found (by Sasha) that if you use a futex located in the gate
area we get stuck in an uninterruptible infinite loop, much like the
ZERO_PAGE issue.

While looking at this problem, PeterZ realized you'll get into similar
trouble when hitting any install_special_pages() mapping.  And are there
still drivers setting up their own special mmaps without page-&gt;mapping,
and without special VM or pte flags to make get_user_pages fail?

In most cases, if page-&gt;mapping is NULL, we do not need to retry at all:
Linus points out that even /proc/sys/vm/drop_caches poses no problem,
because it ends up using remove_mapping(), which takes care not to
interfere when the page reference count is raised.

But there is still one case which does need a retry: if memory pressure
called shmem_writepage in between get_user_pages_fast dropping page
table lock and our acquiring page lock, then the page gets switched from
filecache to swapcache (and -&gt;mapping set to NULL) whatever the refcount.
Fault it back in to get the page-&gt;mapping needed for key-&gt;shared.inode.

Reported-by: Sasha Levin &lt;levinsasha928@gmail.com&gt;
Signed-off-by: Hugh Dickins &lt;hughd@google.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>kernel: Map most files to use export.h instead of module.h</title>
<updated>2011-10-31T13:20:12Z</updated>
<author>
<name>Paul Gortmaker</name>
<email>paul.gortmaker@windriver.com</email>
</author>
<published>2011-05-23T18:51:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9984de1a5a8a96275fcab818f7419af5a3c86e71'/>
<id>urn:sha1:9984de1a5a8a96275fcab818f7419af5a3c86e71</id>
<content type='text'>
The changed files were only including linux/module.h for the
EXPORT_SYMBOL infrastructure, and nothing else.  Revector them
onto the isolated export header for faster compile times.

Nothing to see here but a whole lot of instances of:

  -#include &lt;linux/module.h&gt;
  +#include &lt;linux/export.h&gt;

This commit is only changing the kernel dir; next targets
will probably be mm, fs, the arch dirs, etc.

Signed-off-by: Paul Gortmaker &lt;paul.gortmaker@windriver.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'master' into for-next</title>
<updated>2011-09-15T13:08:18Z</updated>
<author>
<name>Jiri Kosina</name>
<email>jkosina@suse.cz</email>
</author>
<published>2011-09-15T13:08:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e060c38434b2caa78efe7cedaff4191040b65a15'/>
<id>urn:sha1:e060c38434b2caa78efe7cedaff4191040b65a15</id>
<content type='text'>
Fast-forward merge with Linus to be able to merge patches
based on more recent version of the tree.
</content>
</entry>
<entry>
<title>futex: Fix spelling in a source code comment</title>
<updated>2011-09-15T12:37:17Z</updated>
<author>
<name>Bart Van Assche</name>
<email>bvanassche@acm.org</email>
</author>
<published>2011-07-17T07:01:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ca4a04cf3dd0cecb5e7188ed7796cc55fc13aeb1'/>
<id>urn:sha1:ca4a04cf3dd0cecb5e7188ed7796cc55fc13aeb1</id>
<content type='text'>
Change a single occurrence of "unlcoked" into "unlocked".

Signed-off-by: Bart Van Assche &lt;bvanassche@acm.org&gt;
Cc: Darren Hart &lt;dvhltc@us.ibm.com&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>futex: uninitialized warning corrections</title>
<updated>2011-09-15T12:23:07Z</updated>
<author>
<name>Vitaliy Ivanov</name>
<email>vitalivanov@gmail.com</email>
</author>
<published>2011-07-07T12:10:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7cfdaf38d4975b0266fbdef971e5ce37da7214fd'/>
<id>urn:sha1:7cfdaf38d4975b0266fbdef971e5ce37da7214fd</id>
<content type='text'>
The variables here are really not used uninitialized.

kernel/futex.c: In function 'fixup_pi_state_owner.clone.17':
kernel/futex.c:1582:6: warning: 'curval' may be used uninitialized in this function
kernel/futex.c: In function 'handle_futex_death':
kernel/futex.c:2486:6: warning: 'nval' may be used uninitialized in this function
kernel/futex.c: In function 'do_futex':
kernel/futex.c:863:11: warning: 'curval' may be used uninitialized in this function
kernel/futex.c:828:6: note: 'curval' was declared here
kernel/futex.c:898:5: warning: 'oldval' may be used uninitialized in this function
kernel/futex.c:890:6: note: 'oldval' was declared here

Signed-off-by: Vitaliy Ivanov &lt;vitalivanov@gmail.com&gt;
Acked-by: Darren Hart &lt;dvhart@linux.intel.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
</feed>
