<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/fs/nfs/blocklayout/blocklayout.c, branch linux-4.5.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.5.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.5.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2015-10-21T20:55:47Z</updated>
<entry>
<title>nfs/blocklayout: Fix bad using of page offset in bl_read_pagelist</title>
<updated>2015-10-21T20:55:47Z</updated>
<author>
<name>Kinglong Mee</name>
</author>
<published>2015-10-16T09:22:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=15ae2c7bdc9a5a46999319b88a465a64d265dc40'/>
<id>urn:sha1:15ae2c7bdc9a5a46999319b88a465a64d265dc40</id>
<content type='text'>
Blocklayout uses file offset for the read-back page's offset of first writing,
it's definitely wrong, it writes data to bad address of page that cause userspace
application segment fault. It must be the page base stored in header-&gt;args.pgbase.

Also, the pg_offset has no influence with isect and extent length.

Note: The offset of the non-first page is always zero.

Ps: A test program will segment fault at read() as,
#define _GNU_SOURCE

#include &lt;stdio.h&gt;
#include &lt;stdlib.h&gt;
#include &lt;sys/types.h&gt;
#include &lt;sys/stat.h&gt;
#include &lt;unistd.h&gt;
#include &lt;fcntl.h&gt;
#include &lt;errno.h&gt;

int main(int argc, char **argv)
{
        char buf[2049];
        char *filename = NULL;
        int fd = -1;

        if (argc &lt; 2) {
                printf("Usage: %s filename\n", argv[0]);
                return 0;
        }

        filename = argv[1];
        fd = open(filename, O_RDONLY | O_DIRECT);
        if (fd &lt; 0) {
                printf("Open %s fail: %m\n", filename);
                return 1;
        }

        lseek(fd, 2048, SEEK_SET);
        if (read(fd, buf, sizeof(buf) - 1) != (sizeof(buf) - 1))
                printf("Read 4096 bityes data from %s fail: %m\n", filename);
out:
        close(fd);
        return 0;
}

Signed-off-by: Kinglong Mee &lt;kinglongmee@gmail.com&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>block: add a bi_error field to struct bio</title>
<updated>2015-07-29T14:55:15Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2015-07-20T13:29:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4246a0b63bd8f56a1469b12eafeb875b1041a451'/>
<id>urn:sha1:4246a0b63bd8f56a1469b12eafeb875b1041a451</id>
<content type='text'>
Currently we have two different ways to signal an I/O error on a BIO:

 (1) by clearing the BIO_UPTODATE flag
 (2) by returning a Linux errno value to the bi_end_io callback

The first one has the drawback of only communicating a single possible
error (-EIO), and the second one has the drawback of not beeing persistent
when bios are queued up, and are not passed along from child to parent
bio in the ever more popular chaining scenario.  Having both mechanisms
available has the additional drawback of utterly confusing driver authors
and introducing bugs where various I/O submitters only deal with one of
them, and the others have to add boilerplate code to deal with both kinds
of error returns.

So add a new bi_error field to store an errno value directly in struct
bio and remove the existing mechanisms to clean all this up.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Hannes Reinecke &lt;hare@suse.de&gt;
Reviewed-by: NeilBrown &lt;neilb@suse.com&gt;
Signed-off-by: Jens Axboe &lt;axboe@fb.com&gt;
</content>
</entry>
<entry>
<title>NFSv4.1/pnfs: Separate out metadata and data consistency for pNFS</title>
<updated>2015-03-27T16:39:38Z</updated>
<author>
<name>Trond Myklebust</name>
</author>
<published>2015-03-25T18:14:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5bb89b4702e22981445ae01af733a57d1cae2018'/>
<id>urn:sha1:5bb89b4702e22981445ae01af733a57d1cae2018</id>
<content type='text'>
The LAYOUTCOMMIT operation means different things to different layout types.
For blocks and objects, it is both a data and metadata consistency operation.
For files and flexfiles, it is only a metadata consistency operation.

This patch separates out the 2 cases, allowing the files/flexfiles layout
drivers to optimise away the data consistency calls to layoutcommit.

Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>pnfs: release lseg in pnfs_generic_pg_cleanup</title>
<updated>2015-02-03T19:06:44Z</updated>
<author>
<name>Weston Andros Adamson</name>
</author>
<published>2014-09-10T19:48:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=180bb5ec06ce3a95dccc751fbf6bf11d3003da98'/>
<id>urn:sha1:180bb5ec06ce3a95dccc751fbf6bf11d3003da98</id>
<content type='text'>
This is needed to support mirrored writes - the first write can't just
trash the lseg, we need to keep it around until all mirrors have
written.

Signed-off-by: Weston Andros Adamson &lt;dros@primarydata.com&gt;
</content>
</entry>
<entry>
<title>pnfs/blocklayout: fix end calculation in pnfs_num_cont_bytes</title>
<updated>2014-11-24T22:00:41Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2014-11-24T21:47:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6a74c0c9402b85647793da70edc9d6b097d54472'/>
<id>urn:sha1:6a74c0c9402b85647793da70edc9d6b097d54472</id>
<content type='text'>
Use the number of pages in the pagecache mapping instead of the
number of pnfs requests which is only slightly related.

Reported-by: Weston Andros Adamson &lt;dros@primarydata.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>nfs: Remove bogus assignment</title>
<updated>2014-11-12T19:22:53Z</updated>
<author>
<name>Jan Kara</name>
</author>
<published>2014-10-21T11:32:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b283f9445214d4d573906f919c70caccd27b74ea'/>
<id>urn:sha1:b283f9445214d4d573906f919c70caccd27b74ea</id>
<content type='text'>
Commit 3a6fd1f004fc (pnfs/blocklayout: remove read-modify-write handling
in bl_write_pagelist) introduced a bogus assignment pg_index = pg_index
in variable initialization. AFAICS it's just a typo so remove it.
Spotted by Coverity (id 1248711).

CC: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jan Kara &lt;jack@suse.cz&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>pNFS/blocklayout: Remove a couple of unused variables</title>
<updated>2014-09-12T17:34:54Z</updated>
<author>
<name>Trond Myklebust</name>
</author>
<published>2014-09-12T17:25:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=164ae58c3c2a56e99d7ae207499f1fbd5e6f263d'/>
<id>urn:sha1:164ae58c3c2a56e99d7ae207499f1fbd5e6f263d</id>
<content type='text'>
Cc: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>pnfs/blocklayout: in-kernel GETDEVICEINFO XDR parsing</title>
<updated>2014-09-12T17:33:50Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2014-09-11T00:37:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5c83746a0cf2831d4b59f5cf99ef5fbf138564e4'/>
<id>urn:sha1:5c83746a0cf2831d4b59f5cf99ef5fbf138564e4</id>
<content type='text'>
This patches moves parsing of the GETDEVICEINFO XDR to kernel space, as well
as the management of complex devices.  The reason for that is we might have
multiple outstanding complex devices after a NOTIFY_DEVICEID4_CHANGE, which
device mapper or md can't handle as they claim devices exclusively.

But as is turns out simple striping / concatenation is fairly trivial to
implement anyway, so we make our life simpler by reducing the reliance
on blkmapd.  For now we still use blkmapd by feeding it synthetic SIMPLE
device XDR to translate device signatures to device numbers, but in the
long runs I have plans to eliminate it entirely.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>pnfs/blocklayout: move all rpc_pipefs related code into a single file</title>
<updated>2014-09-12T17:33:50Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2014-09-11T00:37:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=871760ce97a9a544cfb1ae4589598b25b8570a25'/>
<id>urn:sha1:871760ce97a9a544cfb1ae4589598b25b8570a25</id>
<content type='text'>
Create a file to house all the rpc_pipefs boilerplate code instead of
sprinkling it over a few files.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
<entry>
<title>pnfs/blocklayout: refactor extent processing</title>
<updated>2014-09-12T17:33:49Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2014-09-11T00:37:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ca0fe1dfa5acac6ec4ef5820d2eb5460b02648d5'/>
<id>urn:sha1:ca0fe1dfa5acac6ec4ef5820d2eb5460b02648d5</id>
<content type='text'>
Factor out a helper for all per-extent work, and merge the now trivial
functions for lseg allocation and parsing.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Trond Myklebust &lt;trond.myklebust@primarydata.com&gt;
</content>
</entry>
</feed>
