<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/include/linux/namespace.h, branch v2.6.16-rc4</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>[PATCH] unshare system call -v5: unshare namespace</title>
<updated>2006-02-08T00:12:34+00:00</updated>
<author>
<name>JANAK DESAI</name>
<email>janak@us.ibm.com</email>
</author>
<published>2006-02-07T20:59:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=741a295130606143edbf9fc740f633dbc1e6225f'/>
<id>741a295130606143edbf9fc740f633dbc1e6225f</id>
<content type='text'>
If the namespace structure is being shared, allocate a new one and copy
information from the current, shared, structure.

Signed-off-by: Janak Desai &lt;janak@us.ibm.com&gt;
Cc: Al Viro &lt;viro@ftp.linux.org.uk&gt;
Cc: Christoph Hellwig &lt;hch@lst.de&gt;
Cc: Michael Kerrisk &lt;mtk-manpages@gmx.net&gt;
Cc: Andi Kleen &lt;ak@muc.de&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If the namespace structure is being shared, allocate a new one and copy
information from the current, shared, structure.

Signed-off-by: Janak Desai &lt;janak@us.ibm.com&gt;
Cc: Al Viro &lt;viro@ftp.linux.org.uk&gt;
Cc: Christoph Hellwig &lt;hch@lst.de&gt;
Cc: Michael Kerrisk &lt;mtk-manpages@gmx.net&gt;
Cc: Andi Kleen &lt;ak@muc.de&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] making namespace_sem global</title>
<updated>2005-11-08T02:18:10+00:00</updated>
<author>
<name>Ram Pai</name>
<email>linuxram@us.ibm.com</email>
</author>
<published>2005-11-07T22:17:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=390c684367de37e1c2f9005cf92f7a746c69fdd3'/>
<id>390c684367de37e1c2f9005cf92f7a746c69fdd3</id>
<content type='text'>
This removes the per-namespace semaphore in favor of a global semaphore.
This can have an effect on namespace scalability.

Signed-off-by: Miklos Szeredi &lt;miklos@szeredi.hu&gt;
Signed-off-by: Ram Pai &lt;linuxram@us.ibm.com&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This removes the per-namespace semaphore in favor of a global semaphore.
This can have an effect on namespace scalability.

Signed-off-by: Miklos Szeredi &lt;miklos@szeredi.hu&gt;
Signed-off-by: Ram Pai &lt;linuxram@us.ibm.com&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] make /proc/mounts pollable</title>
<updated>2005-11-08T02:18:10+00:00</updated>
<author>
<name>Al Viro</name>
<email>viro@zeniv.linux.org.uk</email>
</author>
<published>2005-11-07T22:15:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5addc5dd8836aa061f6efc4a0d9ba6323726297a'/>
<id>5addc5dd8836aa061f6efc4a0d9ba6323726297a</id>
<content type='text'>
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] namespace.c: fix race in mark_mounts_for_expiry()</title>
<updated>2005-07-08T01:23:51+00:00</updated>
<author>
<name>Miklos Szeredi</name>
<email>miklos@szeredi.hu</email>
</author>
<published>2005-07-08T00:57:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=1ce88cf466f7b6078b14d67d186a3d7c19dd5609'/>
<id>1ce88cf466f7b6078b14d67d186a3d7c19dd5609</id>
<content type='text'>
This patch fixes a race found by Ram in mark_mounts_for_expiry() in
fs/namespace.c.

The bug can only be triggered with simultaneous exiting of a process having
a private namespace, and expiry of a mount from within that namespace.
It's practically impossible to trigger, and I haven't even tried.  But
still, a bug is a bug.

The race happens when put_namespace() is called by another task, while
mark_mounts_for_expiry() is between atomic_read() and get_namespace().  In
that case get_namespace() will be called on an already dead namespace with
unforeseeable results.

The solution was suggested by Al Viro, with his own words:

      Instead of screwing with atomic_read() in there, why don't we
      simply do the following:
      	a) atomic_dec_and_lock() in put_namespace()
      	b) __put_namespace() called without dropping lock
      	c) the first thing done by __put_namespace would be
      struct vfsmount *root = namespace-&gt;root;
      namespace-&gt;root = NULL;
      spin_unlock(...);
      ....
      umount_tree(root);
      ...
      	d) check in mark_... would be simply namespace &amp;&amp; namespace-&gt;root.

      And we are all set; no screwing around with atomic_read(), no magic
      at all.  Dying namespace gets NULL -&gt;root.
      All changes of -&gt;root happen under spinlock.
      If under a spinlock we see non-NULL -&gt;mnt_namespace, it won't be
      freed until we drop the lock (we will set -&gt;mnt_namespace to NULL
      under that lock before we get to freeing namespace).
      If under a spinlock we see non-NULL -&gt;mnt_namespace and
      -&gt;mnt_namespace-&gt;root, we can grab a reference to namespace and be
      sure that it won't go away.

Signed-off-by: Miklos Szeredi &lt;miklos@szeredi.hu&gt;
Acked-by: Al Viro &lt;viro@parcelfarce.linux.theplanet.co.uk&gt;
Acked-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch fixes a race found by Ram in mark_mounts_for_expiry() in
fs/namespace.c.

The bug can only be triggered with simultaneous exiting of a process having
a private namespace, and expiry of a mount from within that namespace.
It's practically impossible to trigger, and I haven't even tried.  But
still, a bug is a bug.

The race happens when put_namespace() is called by another task, while
mark_mounts_for_expiry() is between atomic_read() and get_namespace().  In
that case get_namespace() will be called on an already dead namespace with
unforeseeable results.

The solution was suggested by Al Viro, with his own words:

      Instead of screwing with atomic_read() in there, why don't we
      simply do the following:
      	a) atomic_dec_and_lock() in put_namespace()
      	b) __put_namespace() called without dropping lock
      	c) the first thing done by __put_namespace would be
      struct vfsmount *root = namespace-&gt;root;
      namespace-&gt;root = NULL;
      spin_unlock(...);
      ....
      umount_tree(root);
      ...
      	d) check in mark_... would be simply namespace &amp;&amp; namespace-&gt;root.

      And we are all set; no screwing around with atomic_read(), no magic
      at all.  Dying namespace gets NULL -&gt;root.
      All changes of -&gt;root happen under spinlock.
      If under a spinlock we see non-NULL -&gt;mnt_namespace, it won't be
      freed until we drop the lock (we will set -&gt;mnt_namespace to NULL
      under that lock before we get to freeing namespace).
      If under a spinlock we see non-NULL -&gt;mnt_namespace and
      -&gt;mnt_namespace-&gt;root, we can grab a reference to namespace and be
      sure that it won't go away.

Signed-off-by: Miklos Szeredi &lt;miklos@szeredi.hu&gt;
Acked-by: Al Viro &lt;viro@parcelfarce.linux.theplanet.co.uk&gt;
Acked-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[PATCH] make various thing static</title>
<updated>2005-06-24T07:06:43+00:00</updated>
<author>
<name>Adrian Bunk</name>
<email>bunk@stusta.de</email>
</author>
<published>2005-06-24T05:05:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=52c1da39534fb382c061de58b65f678ad74b59f5'/>
<id>52c1da39534fb382c061de58b65f678ad74b59f5</id>
<content type='text'>
Another rollup of patches which give various symbols static scope

Signed-off-by: Adrian Bunk &lt;bunk@stusta.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Another rollup of patches which give various symbols static scope

Signed-off-by: Adrian Bunk &lt;bunk@stusta.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Linux-2.6.12-rc2</title>
<updated>2005-04-16T22:20:36+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@ppc970.osdl.org</email>
</author>
<published>2005-04-16T22:20:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=1da177e4c3f41524e886b7f1b8a0c1fc7321cac2'/>
<id>1da177e4c3f41524e886b7f1b8a0c1fc7321cac2</id>
<content type='text'>
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.

Let it rip!
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.

Let it rip!
</pre>
</div>
</content>
</entry>
</feed>
