<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/fs/xfs/xfs_rtalloc.c, branch linux-4.16.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.16.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.16.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2017-09-01T17:55:30Z</updated>
<entry>
<title>xfs: remove the ip argument to xfs_defer_finish</title>
<updated>2017-09-01T17:55:30Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2017-08-28T17:21:04Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8ad7c629b18695ec1ee8654fb27599864049862b'/>
<id>urn:sha1:8ad7c629b18695ec1ee8654fb27599864049862b</id>
<content type='text'>
And instead require callers to explicitly join the inode using
xfs_defer_ijoin.  Also consolidate the defer error handling in
a few places using a goto label.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
Signed-off-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
</content>
</entry>
<entry>
<title>xfs: remove double-underscore integer types</title>
<updated>2017-06-19T21:11:33Z</updated>
<author>
<name>Darrick J. Wong</name>
</author>
<published>2017-06-16T18:00:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c8ce540db5f67d254aafb14b5d76422c62a906df'/>
<id>urn:sha1:c8ce540db5f67d254aafb14b5d76422c62a906df</id>
<content type='text'>
This is a purely mechanical patch that removes the private
__{u,}int{8,16,32,64}_t typedefs in favor of using the system
{u,}int{8,16,32,64}_t typedefs.  This is the sed script used to perform
the transformation and fix the resulting whitespace and indentation
errors:

s/typedef\t__uint8_t/typedef __uint8_t\t/g
s/typedef\t__uint/typedef __uint/g
s/typedef\t__int\([0-9]*\)_t/typedef int\1_t\t/g
s/__uint8_t\t/__uint8_t\t\t/g
s/__uint/uint/g
s/__int\([0-9]*\)_t\t/__int\1_t\t\t/g
s/__int/int/g
/^typedef.*int[0-9]*_t;$/d

Signed-off-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
</entry>
<entry>
<title>xfs: simplify xfs_rtallocate_extent</title>
<updated>2017-02-18T00:52:52Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2017-02-17T16:21:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=089ec2f87578b9740f0c27bcea9cc6be59c1ddb0'/>
<id>urn:sha1:089ec2f87578b9740f0c27bcea9cc6be59c1ddb0</id>
<content type='text'>
We can deduce the allocation type from the bno argument, and do the
return without prod much simpler internally.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
[darrick: fix the macro for the non-rt build]
Signed-off-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
</content>
</entry>
<entry>
<title>xfs: rename flist/free_list to dfops</title>
<updated>2016-08-03T01:19:29Z</updated>
<author>
<name>Darrick J. Wong</name>
</author>
<published>2016-08-03T01:19:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2c3234d1ef53030ff6a79d55ba1fb291098467c2'/>
<id>urn:sha1:2c3234d1ef53030ff6a79d55ba1fb291098467c2</id>
<content type='text'>
Mechanical change of flist/free_list to dfops, since they're now
deferred ops, not just a freeing list.

Signed-off-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
Reviewed-by: Brian Foster &lt;bfoster@redhat.com&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;

</content>
</entry>
<entry>
<title>xfs: change xfs_bmap_{finish,cancel,init,free} -&gt; xfs_defer_*</title>
<updated>2016-08-03T01:18:10Z</updated>
<author>
<name>Darrick J. Wong</name>
</author>
<published>2016-08-03T01:18:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=310a75a3c6c747857ad53dd25f2ede3de13612c9'/>
<id>urn:sha1:310a75a3c6c747857ad53dd25f2ede3de13612c9</id>
<content type='text'>
Drop the compatibility shims that we were using to integrate the new
deferred operation mechanism into the existing code.  No new code.

Signed-off-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
Reviewed-by: Brian Foster &lt;bfoster@redhat.com&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;

</content>
</entry>
<entry>
<title>xfs: rework xfs_bmap_free callers to use xfs_defer_ops</title>
<updated>2016-08-03T01:15:38Z</updated>
<author>
<name>Darrick J. Wong</name>
</author>
<published>2016-08-03T01:15:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3ab78df2a59a485f479d26852a060acfd8c4ecd7'/>
<id>urn:sha1:3ab78df2a59a485f479d26852a060acfd8c4ecd7</id>
<content type='text'>
Restructure everything that used xfs_bmap_free to use xfs_defer_ops
instead.  For now we'll just remove the old symbols and play some
cpp magic to make it work; in the next patch we'll actually rename
everything.

Signed-off-by: Darrick J. Wong &lt;darrick.wong@oracle.com&gt;
Reviewed-by: Brian Foster &lt;bfoster@redhat.com&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;

</content>
</entry>
<entry>
<title>xfs: better xfs_trans_alloc interface</title>
<updated>2016-04-05T23:19:55Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2016-04-05T23:19:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=253f4911f297b83745938b7f2c5649b94730b002'/>
<id>urn:sha1:253f4911f297b83745938b7f2c5649b94730b002</id>
<content type='text'>
Merge xfs_trans_reserve and xfs_trans_alloc into a single function call
that returns a transaction with all the required log and block reservations,
and which allows passing transaction flags directly to avoid the cumbersome
_xfs_trans_alloc interface.

While we're at it we also get rid of the transaction type argument that has
been superflous since we stopped supporting the non-CIL logging mode.  The
guts of it will be removed in another patch.

[dchinner: fixed transaction leak in error path in xfs_setattr_nonsize]

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;

</content>
</entry>
<entry>
<title>xfs: remove timestamps from incore inode</title>
<updated>2016-02-09T05:54:58Z</updated>
<author>
<name>Dave Chinner</name>
</author>
<published>2016-02-09T05:54:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3987848c7c2be112e03c82d03821b044f1c0edec'/>
<id>urn:sha1:3987848c7c2be112e03c82d03821b044f1c0edec</id>
<content type='text'>
The struct xfs_inode has two copies of the current timestamps in it,
one in the vfs inode and one in the struct xfs_icdinode. Now that we
no longer log the struct xfs_icdinode directly, we don't need to
keep the timestamps in this structure. instead we can copy them
straight out of the VFS inode when formatting the inode log item or
the on-disk inode.

This reduces the struct xfs_inode in size by 24 bytes.

Signed-off-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Reviewed-by: Brian Foster &lt;bfoster@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;

</content>
</entry>
<entry>
<title>xfs: eliminate committed arg from xfs_bmap_finish</title>
<updated>2016-01-11T00:34:01Z</updated>
<author>
<name>Eric Sandeen</name>
</author>
<published>2016-01-11T00:34:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f6106efae5f4144b32f6c10de0dc3e7efc9181e3'/>
<id>urn:sha1:f6106efae5f4144b32f6c10de0dc3e7efc9181e3</id>
<content type='text'>
Calls to xfs_bmap_finish() and xfs_trans_ijoin(), and the
associated comments were replicated several times across
the attribute code, all dealing with what to do if the
transaction was or wasn't committed.

And in that replicated code, an ASSERT() test of an
uninitialized variable occurs in several locations:

	error = xfs_attr_thing(&amp;args);
	if (!error) {
		error = xfs_bmap_finish(&amp;args.trans, args.flist,
					&amp;committed);
	}
	if (error) {
		ASSERT(committed);

If the first xfs_attr_thing() failed, we'd skip the xfs_bmap_finish,
never set "committed", and then test it in the ASSERT.

Fix this up by moving the committed state internal to xfs_bmap_finish,
and add a new inode argument.  If an inode is passed in, it is passed
through to __xfs_trans_roll() and joined to the transaction there if
the transaction was committed.

xfs_qm_dqalloc() was a little unique in that it called bjoin rather
than ijoin, but as Dave points out we can detect the committed state
but checking whether (*tpp != tp).

Addresses-Coverity-Id: 102360
Addresses-Coverity-Id: 102361
Addresses-Coverity-Id: 102363
Addresses-Coverity-Id: 102364
Signed-off-by: Eric Sandeen &lt;sandeen@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;
</content>
</entry>
<entry>
<title>xfs: add missing bmap cancel calls in error paths</title>
<updated>2015-08-19T00:01:40Z</updated>
<author>
<name>Brian Foster</name>
</author>
<published>2015-08-19T00:01:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d4a97a04227d5ba91b91888a016e2300861cfbc7'/>
<id>urn:sha1:d4a97a04227d5ba91b91888a016e2300861cfbc7</id>
<content type='text'>
If a failure occurs after the bmap free list is populated and before
xfs_bmap_finish() completes successfully (which returns a partial
list on failure), the bmap free list must be cancelled. Otherwise,
the extent items on the list are never freed and a memory leak
occurs.

Several random error paths throughout the code suffer this problem.
Fix these up such that xfs_bmap_cancel() is always called on error.

Signed-off-by: Brian Foster &lt;bfoster@redhat.com&gt;
Reviewed-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Signed-off-by: Dave Chinner &lt;david@fromorbit.com&gt;
</content>
</entry>
</feed>
