<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/git/stable/linux.git/fs/nfs, branch linux-4.13.y</title>
<subtitle>Linux kernel stable tree</subtitle>
<id>https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/atom?h=linux-4.13.y</id>
<link rel='self' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/atom?h=linux-4.13.y'/>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/'/>
<updated>2017-10-18T07:38:28+00:00</updated>
<entry>
<title>nfs/filelayout: fix oops when freeing filelayout segment</title>
<updated>2017-10-18T07:38:28+00:00</updated>
<author>
<name>Scott Mayhew</name>
<email>smayhew@redhat.com</email>
</author>
<published>2017-09-29T13:36:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=89a00185b82488836b6530c2bc7dcb2231314fc4'/>
<id>urn:sha1:89a00185b82488836b6530c2bc7dcb2231314fc4</id>
<content type='text'>
commit 0a47df11bfc31e1ceae7f91cea84d3bff500475d upstream.

Check for a NULL dsaddr in filelayout_free_lseg() before calling
nfs4_fl_put_deviceid().  This fixes the following oops:

[ 1967.645207] BUG: unable to handle kernel NULL pointer dereference at 0000000000000030
[ 1967.646010] IP: [&lt;ffffffffc06d6aea&gt;] nfs4_put_deviceid_node+0xa/0x90 [nfsv4]
[ 1967.646010] PGD c08bc067 PUD 915d3067 PMD 0
[ 1967.753036] Oops: 0000 [#1] SMP
[ 1967.753036] Modules linked in: nfs_layout_nfsv41_files ext4 mbcache jbd2 loop rpcsec_gss_krb5 nfsv4 dns_resolver nfs fscache amd64_edac_mod ipmi_ssif edac_mce_amd edac_core kvm_amd sg kvm ipmi_si ipmi_devintf irqbypass pcspkr k8temp ipmi_msghandler i2c_piix4 shpchp nfsd auth_rpcgss nfs_acl lockd grace sunrpc ip_tables xfs libcrc32c sd_mod crc_t10dif crct10dif_generic crct10dif_common amdkfd amd_iommu_v2 radeon i2c_algo_bit drm_kms_helper syscopyarea sysfillrect sysimgblt fb_sys_fops mptsas ttm scsi_transport_sas mptscsih drm mptbase serio_raw i2c_core bnx2 dm_mirror dm_region_hash dm_log dm_mod
[ 1967.790031] CPU: 2 PID: 1370 Comm: ls Not tainted 3.10.0-709.el7.test.bz1463784.x86_64 #1
[ 1967.790031] Hardware name: IBM BladeCenter LS21 -[7971AC1]-/Server Blade, BIOS -[BAE155AUS-1.10]- 06/03/2009
[ 1967.790031] task: ffff8800c42a3f40 ti: ffff8800c4064000 task.ti: ffff8800c4064000
[ 1967.790031] RIP: 0010:[&lt;ffffffffc06d6aea&gt;]  [&lt;ffffffffc06d6aea&gt;] nfs4_put_deviceid_node+0xa/0x90 [nfsv4]
[ 1967.790031] RSP: 0000:ffff8800c4067978  EFLAGS: 00010246
[ 1967.790031] RAX: ffffffffc062f000 RBX: ffff8801d468a540 RCX: dead000000000200
[ 1967.790031] RDX: ffff8800c40679f8 RSI: ffff8800c4067a0c RDI: 0000000000000000
[ 1967.790031] RBP: ffff8800c4067980 R08: ffff8801d468a540 R09: 0000000000000000
[ 1967.790031] R10: 0000000000000000 R11: ffffffffffffffff R12: ffff8801d468a540
[ 1967.790031] R13: ffff8800c40679f8 R14: ffff8801d5645300 R15: ffff880126f15ff0
[ 1967.790031] FS:  00007f11053c9800(0000) GS:ffff88012bd00000(0000) knlGS:0000000000000000
[ 1967.790031] CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
[ 1967.790031] CR2: 0000000000000030 CR3: 0000000094b55000 CR4: 00000000000007e0
[ 1967.790031] Stack:
[ 1967.790031]  ffff8801d468a540 ffff8800c4067990 ffffffffc062d2fe ffff8800c40679b0
[ 1967.790031]  ffffffffc062b5b4 ffff8800c40679f8 ffff8801d468a540 ffff8800c40679d8
[ 1967.790031]  ffffffffc06d39af ffff8800c40679f8 ffff880126f16078 0000000000000001
[ 1967.790031] Call Trace:
[ 1967.790031]  [&lt;ffffffffc062d2fe&gt;] nfs4_fl_put_deviceid+0xe/0x10 [nfs_layout_nfsv41_files]
[ 1967.790031]  [&lt;ffffffffc062b5b4&gt;] filelayout_free_lseg+0x24/0x90 [nfs_layout_nfsv41_files]
[ 1967.790031]  [&lt;ffffffffc06d39af&gt;] pnfs_free_lseg_list+0x5f/0x80 [nfsv4]
[ 1967.790031]  [&lt;ffffffffc06d5a67&gt;] _pnfs_return_layout+0x157/0x270 [nfsv4]
[ 1967.790031]  [&lt;ffffffffc06c17dd&gt;] nfs4_evict_inode+0x4d/0x70 [nfsv4]
[ 1967.790031]  [&lt;ffffffff8121de19&gt;] evict+0xa9/0x180
[ 1967.790031]  [&lt;ffffffff8121e729&gt;] iput+0xf9/0x190
[ 1967.790031]  [&lt;ffffffffc0652cea&gt;] nfs_dentry_iput+0x3a/0x50 [nfs]
[ 1967.790031]  [&lt;ffffffff8121ab4f&gt;] shrink_dentry_list+0x20f/0x490
[ 1967.790031]  [&lt;ffffffff8121b018&gt;] d_invalidate+0xd8/0x150
[ 1967.790031]  [&lt;ffffffffc065446b&gt;] nfs_readdir_page_filler+0x40b/0x600 [nfs]
[ 1967.790031]  [&lt;ffffffffc0654bbd&gt;] nfs_readdir_xdr_to_array+0x20d/0x3b0 [nfs]
[ 1967.790031]  [&lt;ffffffff811f3482&gt;] ? __mem_cgroup_commit_charge+0xe2/0x2f0
[ 1967.790031]  [&lt;ffffffff81183208&gt;] ? __add_to_page_cache_locked+0x48/0x170
[ 1967.790031]  [&lt;ffffffffc0654d60&gt;] ? nfs_readdir_xdr_to_array+0x3b0/0x3b0 [nfs]
[ 1967.790031]  [&lt;ffffffffc0654d82&gt;] nfs_readdir_filler+0x22/0x90 [nfs]
[ 1967.790031]  [&lt;ffffffff8118351f&gt;] do_read_cache_page+0x7f/0x190
[ 1967.790031]  [&lt;ffffffff81215d30&gt;] ? fillonedir+0xe0/0xe0
[ 1967.790031]  [&lt;ffffffff8118366c&gt;] read_cache_page+0x1c/0x30
[ 1967.790031]  [&lt;ffffffffc0654f9b&gt;] nfs_readdir+0x1ab/0x6b0 [nfs]
[ 1967.790031]  [&lt;ffffffffc06bd1c0&gt;] ? nfs4_xdr_dec_layoutget+0x270/0x270 [nfsv4]
[ 1967.790031]  [&lt;ffffffff81215d30&gt;] ? fillonedir+0xe0/0xe0
[ 1967.790031]  [&lt;ffffffff81215c20&gt;] vfs_readdir+0xb0/0xe0
[ 1967.790031]  [&lt;ffffffff81216045&gt;] SyS_getdents+0x95/0x120
[ 1967.790031]  [&lt;ffffffff816b9449&gt;] system_call_fastpath+0x16/0x1b
[ 1967.790031] Code: 90 31 d2 48 89 d0 5d c3 85 f6 74 f5 8d 4e 01 89 f0 f0 0f b1 0f 39 f0 74 e2 89 c6 eb eb 0f 1f 40 00 66 66 66 66 90 55 48 89 e5 53 &lt;48&gt; 8b 47 30 48 89 fb a8 04 74 3b 8b 57 60 83 fa 02 74 19 8d 4a
[ 1967.790031] RIP  [&lt;ffffffffc06d6aea&gt;] nfs4_put_deviceid_node+0xa/0x90 [nfsv4]
[ 1967.790031]  RSP &lt;ffff8800c4067978&gt;
[ 1967.790031] CR2: 0000000000000030

Signed-off-by: Scott Mayhew &lt;smayhew@redhat.com&gt;
Fixes: 1ebf98012792 ("NFS/filelayout: Fix racy setting of fl-&gt;dsaddr...")
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>NFS: Fix uninitialized rpc_wait_queue</title>
<updated>2017-10-18T07:38:28+00:00</updated>
<author>
<name>Benjamin Coddington</name>
<email>bcodding@redhat.com</email>
</author>
<published>2017-09-22T11:57:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=83bce378791ebd2ee2643097f22905f1e1896744'/>
<id>urn:sha1:83bce378791ebd2ee2643097f22905f1e1896744</id>
<content type='text'>
commit 68ebf8fe3bce8c167cf83fbd681c1eb1ed419c6c upstream.

Michael Sterrett reports a NULL pointer dereference on NFSv3 mounts when
CONFIG_NFS_V4 is not set because the NFS UOC rpc_wait_queue has not been
initialized.  Move the initialization of the queue out of the CONFIG_NFS_V4
conditional setion.

Fixes: 7d6ddf88c4db ("NFS: Add an iocounter wait function for async RPC tasks")
Signed-off-by: Benjamin Coddington &lt;bcodding@redhat.com&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>NFSv4: Fix up mirror allocation</title>
<updated>2017-09-13T21:20:54+00:00</updated>
<author>
<name>Trond Myklebust</name>
<email>trond.myklebust@primarydata.com</email>
</author>
<published>2017-08-19T14:10:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=41a5f0a2a8323077533ebc32d1d7cfeb5454457d'/>
<id>urn:sha1:41a5f0a2a8323077533ebc32d1d7cfeb5454457d</id>
<content type='text'>
commit 14abcb0bf59a30cf65a74f6c6f53974cd7224bc6 upstream.

There are a number of callers of nfs_pageio_complete() that want to
continue using the nfs_pageio_descriptor without needing to call
nfs_pageio_init() again. Examples include nfs_pageio_resend() and
nfs_pageio_cond_complete().

The problem is that nfs_pageio_complete() also calls
nfs_pageio_cleanup_mirroring(), which frees up the array of mirrors.
This can lead to writeback errors, in the next call to
nfs_pageio_setup_mirroring().

Fix by simply moving the allocation of the mirrors to
nfs_pageio_setup_mirroring().

Link: https://bugzilla.kernel.org/show_bug.cgi?id=196709
Reported-by: JianhongYin &lt;yin-jianhong@163.com&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>NFS: Sync the correct byte range during synchronous writes</title>
<updated>2017-09-13T21:20:54+00:00</updated>
<author>
<name>tarangg@amazon.com</name>
<email>tarangg@amazon.com</email>
</author>
<published>2017-09-07T13:29:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=1c8c0359f0a03864e24a5a5877a69c35bf0b2f92'/>
<id>urn:sha1:1c8c0359f0a03864e24a5a5877a69c35bf0b2f92</id>
<content type='text'>
commit e973b1a5999e57da677ab50da5f5479fdc0f0c31 upstream.

Since commit 18290650b1c8 ("NFS: Move buffered I/O locking into
nfs_file_write()") nfs_file_write() has not flushed the correct byte
range during synchronous writes.  generic_write_sync() expects that
iocb-&gt;ki_pos points to the right edge of the range rather than the
left edge.

To replicate the problem, open a file with O_DSYNC, have the client
write at increasing offsets, and then print the successful offsets.
Block port 2049 partway through that sequence, and observe that the
client application indicates successful writes in advance of what the
server received.

Fixes: 18290650b1c8 ("NFS: Move buffered I/O locking into nfs_file_write()")
Signed-off-by: Jacob Strauss &lt;jsstraus@amazon.com&gt;
Signed-off-by: Tarang Gupta &lt;tarangg@amazon.com&gt;
Tested-by: Tarang Gupta &lt;tarangg@amazon.com&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>NFS: Fix 2 use after free issues in the I/O code</title>
<updated>2017-09-13T21:20:54+00:00</updated>
<author>
<name>Trond Myklebust</name>
<email>trond.myklebust@primarydata.com</email>
</author>
<published>2017-09-09T01:28:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=65631fea43758154f0e7b7ab23a906aaa97ad780'/>
<id>urn:sha1:65631fea43758154f0e7b7ab23a906aaa97ad780</id>
<content type='text'>
commit 196639ebbe63a037fe9a80669140bd292d8bcd80 upstream.

The writeback code wants to send a commit after processing the pages,
which is why we want to delay releasing the struct path until after
that's done.

Also, the layout code expects that we do not free the inode before
we've put the layout segments in pnfs_writehdr_free() and
pnfs_readhdr_free()

Fixes: 919e3bd9a875 ("NFS: Ensure we commit after writeback is complete")
Fixes: 4714fb51fd03 ("nfs: remove pgio_header refcount, related cleanup")
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>Merge tag 'nfs-for-4.13-5' of git://git.linux-nfs.org/projects/anna/linux-nfs</title>
<updated>2017-08-11T20:54:09+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2017-08-11T20:54:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=216e4a1def29a0d04182875034efb764eb37b8ff'/>
<id>urn:sha1:216e4a1def29a0d04182875034efb764eb37b8ff</id>
<content type='text'>
Pull NFS client fixes from Anna Schumaker:
 "A few more NFS client bugfixes from me for rc5.

  Dros has a stable fix for flexfiles to prevent leaking the
  nfs4_ff_ds_version arrays when freeing a layout, Trond fixed a
  potential recovery loop situation with the TEST_STATEID operation, and
  Christoph fixed up the pNFS blocklayout Kconfig options to prevent
  unsafe use with kernels that don't have large block device support.
  Summary:

  Stable fix:
   - fix leaking nfs4_ff_ds_version array

  Other fixes:
   - improve TEST_STATEID OLD_STATEID handling to prevent recovery loop

   - require 64-bit sector_t for pNFS blocklayout to prevent 32-bit
     compile errors"

* tag 'nfs-for-4.13-5' of git://git.linux-nfs.org/projects/anna/linux-nfs:
  pnfs/blocklayout: require 64-bit sector_t
  NFSv4: Ignore NFS4ERR_OLD_STATEID in nfs41_check_open_stateid()
  nfs/flexfiles: fix leak of nfs4_ff_ds_version arrays
</content>
</entry>
<entry>
<title>pnfs/blocklayout: require 64-bit sector_t</title>
<updated>2017-08-11T18:10:13+00:00</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2017-08-05T08:59:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=8a9d6e964d318533ba3d2901ce153ba317c99a89'/>
<id>urn:sha1:8a9d6e964d318533ba3d2901ce153ba317c99a89</id>
<content type='text'>
The blocklayout code does not compile cleanly for a 32-bit sector_t,
and also has no reliable checks for devices sizes, which makes it
unsafe to use with a kernel that doesn't support large block devices.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reported-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Fixes: 5c83746a0cf2 ("pnfs/blocklayout: in-kernel GETDEVICEINFO XDR parsing")
Signed-off-by: Anna Schumaker &lt;Anna.Schumaker@Netapp.com&gt;
</content>
</entry>
<entry>
<title>NFSv4: Ignore NFS4ERR_OLD_STATEID in nfs41_check_open_stateid()</title>
<updated>2017-08-09T17:36:56+00:00</updated>
<author>
<name>Trond Myklebust</name>
<email>trond.myklebust@primarydata.com</email>
</author>
<published>2017-08-09T01:39:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=c0ca0e5934b3bd70d456b363a6a989a3b4a692f1'/>
<id>urn:sha1:c0ca0e5934b3bd70d456b363a6a989a3b4a692f1</id>
<content type='text'>
If the call to TEST_STATEID returns NFS4ERR_OLD_STATEID, then it just
means we raced with other calls to OPEN.

Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
Signed-off-by: Anna Schumaker &lt;Anna.Schumaker@Netapp.com&gt;
</content>
</entry>
<entry>
<title>nfs/flexfiles: fix leak of nfs4_ff_ds_version arrays</title>
<updated>2017-08-08T21:18:10+00:00</updated>
<author>
<name>Weston Andros Adamson</name>
<email>dros@monkey.org</email>
</author>
<published>2017-08-01T20:25:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=1feb26162bee7b2f110facfec71b5c7bdbc7d14d'/>
<id>urn:sha1:1feb26162bee7b2f110facfec71b5c7bdbc7d14d</id>
<content type='text'>
The client was freeing the nfs4_ff_layout_ds, but not the contained
nfs4_ff_ds_version array.

Signed-off-by: Weston Andros Adamson &lt;dros@primarydata.com&gt;
Cc: stable@vger.kernel.org # v4.0+
Signed-off-by: Anna Schumaker &lt;Anna.Schumaker@Netapp.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'nfs-for-4.13-4' of git://git.linux-nfs.org/projects/anna/linux-nfs</title>
<updated>2017-08-03T03:56:44+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2017-08-03T03:56:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rulkc.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=19ec50a438c2ea3e370f6d453bf2f2e6e45ef72b'/>
<id>urn:sha1:19ec50a438c2ea3e370f6d453bf2f2e6e45ef72b</id>
<content type='text'>
Pull NFS client fixes from Anna Schumaker:
 "Two fixes from Trond this time, now that he's back from his vacation.
  The first is a stable fix for the EXCHANGE_ID issue on the mailing
  list, and the other fixes a double-free situation that he found at the
  same time.

  Stable fix:
   - Fix EXCHANGE_ID corrupt verifier issue

  Other fix:
   - Fix double frees in nfs4_test_session_trunk()"

* tag 'nfs-for-4.13-4' of git://git.linux-nfs.org/projects/anna/linux-nfs:
  NFSv4: Fix double frees in nfs4_test_session_trunk()
  NFSv4: Fix EXCHANGE_ID corrupt verifier issue
</content>
</entry>
</feed>
