<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/net/sunrpc/cache.c, branch v3.4.33</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/net/sunrpc/cache.c?h=v3.4.33</id>
<link rel='self' href='https://git.amat.us/linux/atom/net/sunrpc/cache.c?h=v3.4.33'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2012-10-28T17:14:13Z</updated>
<entry>
<title>SUNRPC: Prevent kernel stack corruption on long values of flush</title>
<updated>2012-10-28T17:14:13Z</updated>
<author>
<name>Sasha Levin</name>
<email>levinsasha928@gmail.com</email>
</author>
<published>2012-07-16T22:01:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=baecc6ef799c7ab9a5fc0ba29ee560a5c264f306'/>
<id>urn:sha1:baecc6ef799c7ab9a5fc0ba29ee560a5c264f306</id>
<content type='text'>
commit 212ba90696ab4884e2025b0b13726d67aadc2cd4 upstream.

The buffer size in read_flush() is too small for the longest possible values
for it. This can lead to a kernel stack corruption:

[   43.047329] Kernel panic - not syncing: stack-protector: Kernel stack is corrupted in: ffffffff833e64b4
[   43.047329]
[   43.049030] Pid: 6015, comm: trinity-child18 Tainted: G        W    3.5.0-rc7-next-20120716-sasha #221
[   43.050038] Call Trace:
[   43.050435]  [&lt;ffffffff836c60c2&gt;] panic+0xcd/0x1f4
[   43.050931]  [&lt;ffffffff833e64b4&gt;] ? read_flush.isra.7+0xe4/0x100
[   43.051602]  [&lt;ffffffff810e94e6&gt;] __stack_chk_fail+0x16/0x20
[   43.052206]  [&lt;ffffffff833e64b4&gt;] read_flush.isra.7+0xe4/0x100
[   43.052951]  [&lt;ffffffff833e6500&gt;] ? read_flush_pipefs+0x30/0x30
[   43.053594]  [&lt;ffffffff833e652c&gt;] read_flush_procfs+0x2c/0x30
[   43.053596]  [&lt;ffffffff812b9a8c&gt;] proc_reg_read+0x9c/0xd0
[   43.053596]  [&lt;ffffffff812b99f0&gt;] ? proc_reg_write+0xd0/0xd0
[   43.053596]  [&lt;ffffffff81250d5b&gt;] do_loop_readv_writev+0x4b/0x90
[   43.053596]  [&lt;ffffffff81250fd6&gt;] do_readv_writev+0xf6/0x1d0
[   43.053596]  [&lt;ffffffff812510ee&gt;] vfs_readv+0x3e/0x60
[   43.053596]  [&lt;ffffffff812511b8&gt;] sys_readv+0x48/0xb0
[   43.053596]  [&lt;ffffffff8378167d&gt;] system_call_fastpath+0x1a/0x1f

Signed-off-by: Sasha Levin &lt;levinsasha928@gmail.com&gt;
Signed-off-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>Merge nfs containerization work from Trond's tree</title>
<updated>2012-03-26T15:48:54Z</updated>
<author>
<name>J. Bruce Fields</name>
<email>bfields@redhat.com</email>
</author>
<published>2012-03-21T20:42:14Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1df00640c9111c881633d9b219f18e66c52599ec'/>
<id>urn:sha1:1df00640c9111c881633d9b219f18e66c52599ec</id>
<content type='text'>
The nfs containerization work is a prerequisite for Jeff Layton's reboot
recovery rework.
</content>
</entry>
<entry>
<title>nfsd: don't allow zero length strings in cache_parse()</title>
<updated>2012-02-03T19:26:42Z</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@oracle.com</email>
</author>
<published>2012-01-18T09:56:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=6d8d17499810479eabd10731179c04b2ca22152f'/>
<id>urn:sha1:6d8d17499810479eabd10731179c04b2ca22152f</id>
<content type='text'>
There is no point in passing a zero length string here and quite a
few of that cache_parse() implementations will Oops if count is
zero.

Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Cc: stable@kernel.org
Signed-off-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
</content>
</entry>
<entry>
<title>SUNRPC: generic cache register routines removed</title>
<updated>2012-02-01T00:28:16Z</updated>
<author>
<name>Stanislav Kinsbursky</name>
<email>skinsbursky@parallels.com</email>
</author>
<published>2012-01-19T17:42:53Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=2c5f846747526e2b83c5f1b8e69016be0e2e87c0'/>
<id>urn:sha1:2c5f846747526e2b83c5f1b8e69016be0e2e87c0</id>
<content type='text'>
All cache users now uses network-namespace-aware routines, so generic ones
are obsolete.

Signed-off-by: Stanislav Kinsbursky &lt;skinsbursky@parallels.com&gt;
Signed-off-by: Trond Myklebust &lt;Trond.Myklebust@netapp.com&gt;
Acked-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
</content>
</entry>
<entry>
<title>SUNRPC: cache creation and destruction routines introduced</title>
<updated>2012-02-01T00:28:14Z</updated>
<author>
<name>Stanislav Kinsbursky</name>
<email>skinsbursky@parallels.com</email>
</author>
<published>2012-01-19T17:42:21Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=0a402d5a653ee2b613aaba3092a87b1e964622ce'/>
<id>urn:sha1:0a402d5a653ee2b613aaba3092a87b1e964622ce</id>
<content type='text'>
This patch prepares infrastructure for network namespace aware cache detail
allocation.
One note about adding network namespace link to cache structure. It's going to
be used later in NFS DNS cache parsing routine (nfs_dns_parse for rpc_pton()
call).

Signed-off-by: Stanislav Kinsbursky &lt;skinsbursky@parallels.com&gt;
Signed-off-by: Trond Myklebust &lt;Trond.Myklebust@netapp.com&gt;
Acked-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
</content>
</entry>
<entry>
<title>SUNRPC: split cache creation and PipeFS registration</title>
<updated>2012-01-31T23:20:26Z</updated>
<author>
<name>Stanislav Kinsbursky</name>
<email>skinsbursky@parallels.com</email>
</author>
<published>2011-11-25T14:12:40Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=820f9442e711a81749e70c40f149fc54c4ce0ca8'/>
<id>urn:sha1:820f9442e711a81749e70c40f149fc54c4ce0ca8</id>
<content type='text'>
This precursor patch splits SUNRPC cache creation and PipeFS registartion.
It's required for latter split of NFS DNS resolver cache creation per network
namespace context and PipeFS registration/unregistration on MOUNT/UMOUNT
events.

Signed-off-by: Stanislav Kinsbursky &lt;skinsbursky@parallels.com&gt;
Signed-off-by: Trond Myklebust &lt;Trond.Myklebust@netapp.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-3.3' of git://linux-nfs.org/~bfields/linux</title>
<updated>2012-01-14T20:26:41Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2012-01-14T20:26:41Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=0b48d42235caf627121f440b57d376f48a9af8b6'/>
<id>urn:sha1:0b48d42235caf627121f440b57d376f48a9af8b6</id>
<content type='text'>
* 'for-3.3' of git://linux-nfs.org/~bfields/linux: (31 commits)
  nfsd4: nfsd4_create_clid_dir return value is unused
  NFSD: Change name of extended attribute containing junction
  svcrpc: don't revert to SVC_POOL_DEFAULT on nfsd shutdown
  svcrpc: fix double-free on shutdown of nfsd after changing pool mode
  nfsd4: be forgiving in the absence of the recovery directory
  nfsd4: fix spurious 4.1 post-reboot failures
  NFSD: forget_delegations should use list_for_each_entry_safe
  NFSD: Only reinitilize the recall_lru list under the recall lock
  nfsd4: initialize special stateid's at compile time
  NFSd: use network-namespace-aware cache registering routines
  SUNRPC: create svc_xprt in proper network namespace
  svcrpc: update outdated BKL comment
  nfsd41: allow non-reclaim open-by-fh's in 4.1
  svcrpc: avoid memory-corruption on pool shutdown
  svcrpc: destroy server sockets all at once
  svcrpc: make svc_delete_xprt static
  nfsd: Fix oops when parsing a 0 length export
  nfsd4: Use kmemdup rather than duplicating its implementation
  nfsd4: add a separate (lockowner, inode) lookup
  nfsd4: fix CONFIG_NFSD_FAULT_INJECTION compile error
  ...
</content>
</entry>
<entry>
<title>sunrpc: propagate umode_t</title>
<updated>2012-01-04T03:55:04Z</updated>
<author>
<name>Al Viro</name>
<email>viro@zeniv.linux.org.uk</email>
</author>
<published>2011-07-25T04:35:13Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=64f1426f3c4f8dde9ac9bf3f3b19b88d17f2bae6'/>
<id>urn:sha1:64f1426f3c4f8dde9ac9bf3f3b19b88d17f2bae6</id>
<content type='text'>
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>NFSd: use network-namespace-aware cache registering routines</title>
<updated>2011-12-07T20:27:46Z</updated>
<author>
<name>Stanislav Kinsbursky</name>
<email>skinsbursky@parallels.com</email>
</author>
<published>2011-12-07T09:57:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f5c8593b94190aabdcf207a544f082c7816c4fe6'/>
<id>urn:sha1:f5c8593b94190aabdcf207a544f082c7816c4fe6</id>
<content type='text'>
v2: cache_register_net() and cache_unregister_net() GPL exports added

This is a cleanup patch. Hope, some day generic cache_register() and
cache_unregister() will be removed.

Signed-off-by: Stanislav Kinsbursky &lt;skinsbursky@parallels.com&gt;
Signed-off-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
</content>
</entry>
<entry>
<title>svcrpc: ensure cache_check caller sees updated entry</title>
<updated>2011-01-04T21:49:25Z</updated>
<author>
<name>J. Bruce Fields</name>
<email>bfields@redhat.com</email>
</author>
<published>2011-01-04T19:12:47Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=fdef7aa5d4020fd94ffcbf0078d6bd9e5a111e19'/>
<id>urn:sha1:fdef7aa5d4020fd94ffcbf0078d6bd9e5a111e19</id>
<content type='text'>
Supposes cache_check runs simultaneously with an update on a different
CPU:

	cache_check			task doing update
	^^^^^^^^^^^			^^^^^^^^^^^^^^^^^

	1. test for CACHE_VALID		1'. set entry-&gt;data
	   &amp; !CACHE_NEGATIVE

	2. use entry-&gt;data		2'. set CACHE_VALID

If the two memory writes performed in step 1' and 2' appear misordered
with respect to the reads in step 1 and 2, then the caller could get
stale data at step 2 even though it saw CACHE_VALID set on the cache
entry.

Add memory barriers to prevent this.

Reviewed-by: NeilBrown &lt;neilb@suse.de&gt;
Signed-off-by: J. Bruce Fields &lt;bfields@redhat.com&gt;
</content>
</entry>
</feed>
