<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/fs, branch v2.6.36.4</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/fs?h=v2.6.36.4</id>
<link rel='self' href='https://git.amat.us/linux/atom/fs?h=v2.6.36.4'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2011-02-17T22:47:25Z</updated>
<entry>
<title>nilfs2: fix crash after one superblock became unavailable</title>
<updated>2011-02-17T22:47:25Z</updated>
<author>
<name>Ryusuke Konishi</name>
<email>konishi.ryusuke@lab.ntt.co.jp</email>
</author>
<published>2011-01-21T07:40:31Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=43a1ff7eb4d2e51f3852bed286376635e0628c9f'/>
<id>urn:sha1:43a1ff7eb4d2e51f3852bed286376635e0628c9f</id>
<content type='text'>
commit 0ca7a5b9ac5d301845dd6382ff25a699b6263a81 upstream.

Fixes the following kernel oops in nilfs_setup_super() which could
arise if one of two super-blocks is unavailable.

&gt; BUG: unable to handle kernel NULL pointer dereference at   (null)
&gt; Pid: 3529, comm: mount.nilfs2 Not tainted 2.6.37 #1 /
&gt; EIP: 0060:[&lt;c03196bc&gt;] EFLAGS: 00010202 CPU: 3
&gt; EIP is at memcpy+0xc/0x1b
&gt; Call Trace:
&gt;  [&lt;f953720e&gt;] ? nilfs_setup_super+0x6c/0xa5 [nilfs2]
&gt;  [&lt;f95369e9&gt;] ? nilfs_get_root_dentry+0x81/0xcb [nilfs2]
&gt;  [&lt;f9537a08&gt;] ? nilfs_mount+0x4f9/0x62c [nilfs2]
&gt;  [&lt;c02745cf&gt;] ? kstrdup+0x36/0x3f
&gt;  [&lt;f953750f&gt;] ? nilfs_mount+0x0/0x62c [nilfs2]
&gt;  [&lt;c0293940&gt;] ? vfs_kern_mount+0x4d/0x12c
&gt;  [&lt;c02a5100&gt;] ? get_fs_type+0x76/0x8f
&gt;  [&lt;c0293a68&gt;] ? do_kern_mount+0x33/0xbf
&gt;  [&lt;c02a784a&gt;] ? do_mount+0x2ed/0x714
&gt;  [&lt;c02a6171&gt;] ? copy_mount_options+0x28/0xfc
&gt;  [&lt;c02a7ce3&gt;] ? sys_mount+0x72/0xaf
&gt;  [&lt;c0473085&gt;] ? syscall_call+0x7/0xb

Reported-by: Wakko Warner &lt;wakko@animx.eu.org&gt;
Signed-off-by: Ryusuke Konishi &lt;konishi.ryusuke@lab.ntt.co.jp&gt;
Tested-by: Wakko Warner &lt;wakko@animx.eu.org&gt;
LKML-Reference: &lt;20110121024918.GA29598@animx.eu.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>fs/direct-io.c: don't try to allocate more than BIO_MAX_PAGES in a bio</title>
<updated>2011-02-17T22:47:22Z</updated>
<author>
<name>David Dillow</name>
<email>dillowda@ornl.gov</email>
</author>
<published>2011-01-20T22:44:22Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=ed8f1a28a0fbe533047de331ae97b87ee1903828'/>
<id>urn:sha1:ed8f1a28a0fbe533047de331ae97b87ee1903828</id>
<content type='text'>
commit 20d9600cb407b0b55fef6ee814b60345c6f58264 upstream.

When using devices that support max_segments &gt; BIO_MAX_PAGES (256), direct
IO tries to allocate a bio with more pages than allowed, which leads to an
oops in dio_bio_alloc().  Clamp the request to the supported maximum, and
change dio_bio_alloc() to reflect that bio_alloc() will always return a
bio when called with __GFP_WAIT and a valid number of vectors.

[akpm@linux-foundation.org: remove redundant BUG_ON()]
Signed-off-by: David Dillow &lt;dillowda@ornl.gov&gt;
Reviewed-by: Jeff Moyer &lt;jmoyer@redhat.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>ext4: fix memory leak in ext4_free_branches</title>
<updated>2011-02-17T22:47:06Z</updated>
<author>
<name>Theodore Ts'o</name>
<email>tytso@mit.edu</email>
</author>
<published>2011-01-10T17:51:28Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8cd8793363cd536a18f36f923788b2eabcdfbbcf'/>
<id>urn:sha1:8cd8793363cd536a18f36f923788b2eabcdfbbcf</id>
<content type='text'>
commit 1c5b9e9065567876c2d4a7a16d78f0fed154a5bf upstream.

Commit 40389687 moved a call to ext4_forget() out of
ext4_free_branches and let ext4_free_blocks() handle calling
bforget().  But that change unfortunately did not replace the call to
ext4_forget() with brelse(), which was needed to drop the in-use count
of the indirect block's buffer head, which lead to a memory leak when
deleting files that used indirect blocks.  Fix this.

Thanks to Hugh Dickins for pointing this out.

Signed-off-by: "Theodore Ts'o" &lt;tytso@mit.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>/proc/kcore: fix seeking</title>
<updated>2011-02-17T22:47:04Z</updated>
<author>
<name>Dave Anderson</name>
<email>anderson@redhat.com</email>
</author>
<published>2011-01-13T01:00:36Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=14a03186beb1a7156937a14d97f139979b7ee336'/>
<id>urn:sha1:14a03186beb1a7156937a14d97f139979b7ee336</id>
<content type='text'>
commit ceff1a770933e2ca2bf995b453dade4ec47a9878 upstream.

Commit 34aacb2920 ("procfs: Use generic_file_llseek in /proc/kcore") broke
seeking on /proc/kcore.  This changes it back to use default_llseek in
order to restore the original behavior.

The problem with generic_file_llseek is that it only allows seeks up to
inode-&gt;i_sb-&gt;s_maxbytes, which is 2GB-1 on procfs, where the memory file
offset values in the /proc/kcore PT_LOAD segments may exceed or start
beyond that offset value.

A similar revert was made for /proc/vmcore.

Signed-off-by: Dave Anderson &lt;anderson@redhat.com&gt;
Acked-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>NFS: Fix "kernel BUG at fs/aio.c:554!"</title>
<updated>2011-02-17T22:47:04Z</updated>
<author>
<name>Chuck Lever</name>
<email>chuck.lever@oracle.com</email>
</author>
<published>2011-01-21T15:54:57Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=734c829a870e41c1c05b3cc258de912b3893af73'/>
<id>urn:sha1:734c829a870e41c1c05b3cc258de912b3893af73</id>
<content type='text'>
commit 839f7ad6932d95f4d5ae7267b95c574714ff3d5b upstream.

Nick Piggin reports:

&gt; I'm getting use after frees in aio code in NFS
&gt;
&gt; [ 2703.396766] Call Trace:
&gt; [ 2703.396858]  [&lt;ffffffff8100b057&gt;] ? native_sched_clock+0x27/0x80
&gt; [ 2703.396959]  [&lt;ffffffff8108509e&gt;] ? put_lock_stats+0xe/0x40
&gt; [ 2703.397058]  [&lt;ffffffff81088348&gt;] ? lock_release_holdtime+0xa8/0x140
&gt; [ 2703.397159]  [&lt;ffffffff8108a2a5&gt;] lock_acquire+0x95/0x1b0
&gt; [ 2703.397260]  [&lt;ffffffff811627db&gt;] ? aio_put_req+0x2b/0x60
&gt; [ 2703.397361]  [&lt;ffffffff81039701&gt;] ? get_parent_ip+0x11/0x50
&gt; [ 2703.397464]  [&lt;ffffffff81612a31&gt;] _raw_spin_lock_irq+0x41/0x80
&gt; [ 2703.397564]  [&lt;ffffffff811627db&gt;] ? aio_put_req+0x2b/0x60
&gt; [ 2703.397662]  [&lt;ffffffff811627db&gt;] aio_put_req+0x2b/0x60
&gt; [ 2703.397761]  [&lt;ffffffff811647fe&gt;] do_io_submit+0x2be/0x7c0
&gt; [ 2703.397895]  [&lt;ffffffff81164d0b&gt;] sys_io_submit+0xb/0x10
&gt; [ 2703.397995]  [&lt;ffffffff8100307b&gt;] system_call_fastpath+0x16/0x1b
&gt;
&gt; Adding some tracing, it is due to nfs completing the request then
&gt; returning something other than -EIOCBQUEUED, so aio.c
&gt; also completes the request.

To address this, prevent the NFS direct I/O engine from completing
async iocbs when the forward path returns an error without starting
any I/O.

This fix appears to survive ^C during both "xfstest no. 208" and "fsx
-Z."

It's likely this bug has existed for a very long while, as we are seeing
very similar symptoms in OEL 5.  Copying stable.

Signed-off-by: Chuck Lever &lt;chuck.lever@oracle.com&gt;
Signed-off-by: Trond Myklebust &lt;Trond.Myklebust@netapp.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>NFS: Fix an NFS client lockdep issue</title>
<updated>2011-02-17T22:47:04Z</updated>
<author>
<name>Trond Myklebust</name>
<email>Trond.Myklebust@netapp.com</email>
</author>
<published>2011-01-27T19:55:39Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f66fd5da68a1b6da7b528fe99df0b418719956ec'/>
<id>urn:sha1:f66fd5da68a1b6da7b528fe99df0b418719956ec</id>
<content type='text'>
commit e00b8a24041f37e56b4b8415ce4eba1cbc238065 upstream.

There is no reason to be freeing the delegation cred in the rcu callback,
and doing so is resulting in a lockdep complaint that rpc_credcache_lock
is being called from both softirq and non-softirq contexts.

Reported-by: Chuck Lever &lt;chuck.lever@oracle.com&gt;
Signed-off-by: Trond Myklebust &lt;Trond.Myklebust@netapp.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>install_special_mapping skips security_file_mmap check.</title>
<updated>2011-01-07T21:58:35Z</updated>
<author>
<name>Tavis Ormandy</name>
<email>taviso@cmpxchg8b.com</email>
</author>
<published>2010-12-09T14:29:42Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c11470084f1a32748ae3b8dc010522165a2665da'/>
<id>urn:sha1:c11470084f1a32748ae3b8dc010522165a2665da</id>
<content type='text'>
commit 462e635e5b73ba9a4c03913b77138cd57ce4b050 upstream.

The install_special_mapping routine (used, for example, to setup the
vdso) skips the security check before insert_vm_struct, allowing a local
attacker to bypass the mmap_min_addr security restriction by limiting
the available pages for special mappings.

bprm_mm_init() also skips the check, and although I don't think this can
be used to bypass any restrictions, I don't see any reason not to have
the security check.

  $ uname -m
  x86_64
  $ cat /proc/sys/vm/mmap_min_addr
  65536
  $ cat install_special_mapping.s
  section .bss
      resb BSS_SIZE
  section .text
      global _start
      _start:
          mov     eax, __NR_pause
          int     0x80
  $ nasm -D__NR_pause=29 -DBSS_SIZE=0xfffed000 -f elf -o install_special_mapping.o install_special_mapping.s
  $ ld -m elf_i386 -Ttext=0x10000 -Tbss=0x11000 -o install_special_mapping install_special_mapping.o
  $ ./install_special_mapping &amp;
  [1] 14303
  $ cat /proc/14303/maps
  0000f000-00010000 r-xp 00000000 00:00 0                                  [vdso]
  00010000-00011000 r-xp 00001000 00:19 2453665                            /home/taviso/install_special_mapping
  00011000-ffffe000 rwxp 00000000 00:00 0                                  [stack]

It's worth noting that Red Hat are shipping with mmap_min_addr set to
4096.

Signed-off-by: Tavis Ormandy &lt;taviso@google.com&gt;
Acked-by: Kees Cook &lt;kees@ubuntu.com&gt;
Acked-by: Robert Swiecki &lt;swiecki@google.com&gt;
[ Changed to not drop the error code - akpm ]
Reviewed-by: James Morris &lt;jmorris@namei.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>inotify: stop kernel memory leak on file creation failure</title>
<updated>2011-01-07T21:58:32Z</updated>
<author>
<name>Eric Paris</name>
<email>eparis@redhat.com</email>
</author>
<published>2010-11-23T23:18:37Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=51b491044a371635e678255f525117751b09ffb9'/>
<id>urn:sha1:51b491044a371635e678255f525117751b09ffb9</id>
<content type='text'>
commit a2ae4cc9a16e211c8a128ba10d22a85431f093ab upstream.

If inotify_init is unable to allocate a new file for the new inotify
group we leak the new group.  This patch drops the reference on the
group on file allocation failure.

Reported-by: Vegard Nossum &lt;vegard.nossum@gmail.com&gt;
Signed-off-by: Eric Paris &lt;eparis@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>NFS: Fix fcntl F_GETLK not reporting some conflicts</title>
<updated>2011-01-07T21:58:16Z</updated>
<author>
<name>Sergey Vlasov</name>
<email>vsu@altlinux.ru</email>
</author>
<published>2010-11-28T21:04:05Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=03fae048803670d7dd25083fd7995a7b54ab9437'/>
<id>urn:sha1:03fae048803670d7dd25083fd7995a7b54ab9437</id>
<content type='text'>
commit 21ac19d484a8ffb66f64487846c8d53afef04d2b upstream.

The commit 129a84de2347002f09721cda3155ccfd19fade40 (locks: fix F_GETLK
regression (failure to find conflicts)) fixed the posix_test_lock()
function by itself, however, its usage in NFS changed by the commit
9d6a8c5c213e34c475e72b245a8eb709258e968c (locks: give posix_test_lock
same interface as -&gt;lock) remained broken - subsequent NFS-specific
locking code received F_UNLCK instead of the user-specified lock type.
To fix the problem, fl-&gt;fl_type needs to be saved before the
posix_test_lock() call and restored if no local conflicts were reported.

Reference: https://bugzilla.kernel.org/show_bug.cgi?id=23892
Tested-by: Alexander Morozov &lt;amorozov@etersoft.ru&gt;
Signed-off-by: Sergey Vlasov &lt;vsu@altlinux.ru&gt;
Signed-off-by: Trond Myklebust &lt;Trond.Myklebust@netapp.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>nfsd: Fix possible BUG_ON firing in set_change_info</title>
<updated>2011-01-07T21:58:16Z</updated>
<author>
<name>Neil Brown</name>
<email>neilb@suse.de</email>
</author>
<published>2010-12-02T00:14:30Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=972dc03c6d6ab89c45fbcf4e286a35e124cadcd4'/>
<id>urn:sha1:972dc03c6d6ab89c45fbcf4e286a35e124cadcd4</id>
<content type='text'>
commit c1ac3ffcd0bc7e9617f62be8c7043d53ab84deac upstream.

If vfs_getattr in fill_post_wcc returns an error, we don't
set fh_post_change.
For NFSv4, this can result in set_change_info triggering a BUG_ON.
i.e. fh_post_saved being zero isn't really a bug.

So:
 - instead of BUGging when fh_post_saved is zero, just clear -&gt;atomic.
 - if vfs_getattr fails in fill_post_wcc, take a copy of i_ctime anyway.
   This will be used i seg_change_info, but not overly trusted.
 - While we are there, remove the pointless 'if' statements in set_change_info.
   There is no harm setting all the values.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
Signed-off-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
</feed>
